Skip to content

feat: add EPUB text alignment setting#710

Merged
everpcpc merged 2 commits intomainfrom
codex/epub-text-alignment
Apr 2, 2026
Merged

feat: add EPUB text alignment setting#710
everpcpc merged 2 commits intomainfrom
codex/epub-text-alignment

Conversation

@everpcpc
Copy link
Copy Markdown
Owner

@everpcpc everpcpc commented Apr 2, 2026

Problem

KMReader's EPUB reader exposed advanced typography controls such as line height and spacing, but it did not provide the common text alignment option readers expect. Users who prefer left-aligned or justified body text had no direct way to choose it.

Approach

Add a simplified text alignment preference under Advanced Layout and map it to Readium's text alignment and hyphenation overrides. The UI now offers publisher default, start alignment, and justify, while hyphenation remains an internal behavior automatically enabled for justified text. The preview was updated so the setting is visible before saving.

Scope

  • add a dedicated EPUB text alignment preference model
  • wire the preference into Readium CSS custom properties and preview rendering
  • expose the setting in the iOS and macOS EPUB preferences UI
  • add localized strings for the new labels
  • bump the build version to 390

Related

Validation

  • make format
  • make build
  • make localize
  • ./misc/translate.py list

everpcpc added 2 commits April 2, 2026 19:56
Add a simplified EPUB text alignment preference under advanced layout for iOS and macOS.
Map the setting to Readium text alignment and hyphenation overrides, and update the preview and localized strings accordingly.
@everpcpc everpcpc merged commit 5fc074a into main Apr 2, 2026
3 checks passed
@everpcpc everpcpc deleted the codex/epub-text-alignment branch April 2, 2026 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant