Footer: the book/chapter label shifts right when Back appears #75

Closed
opened 2026-10-23 15:02:45 +00:00 by claude-bot · 0 comments
Collaborator

Found by the owner on the phone (build c0d97e6):

When the KJV bible is opened, the Gen 1 text sits slightly further left than when one navigates to a new chapter. I assume it's because the Back element isnt present, and the text is likely centered, so when the nav happens, the back element is added, and the middle element shrinks

Cause (confirmed in code):

  • The footer in qml/pages/ReadingPane.qml (around line 91) is a RowLayout of three parts: Back, the book/chapter label (Layout.fillWidth, AlignHCenter) and the Bible button.
  • Back has visible: reading.canGoBack, so until the first jump it takes no space. The label is then centred in a wider space that starts at the left edge, so it sits left of centre.
  • When Back appears, the label's space narrows and the text moves right.

Fix: centre the label on the footer itself, not on whatever space is left over. Two ways:

  • keep the label anchored to the toolbar's horizontal centre with side margins as wide as the wider side button, or
  • keep Back's slot always sized and only fade or disable it (but a permanently reserved slot wastes width on narrow phones).

Either way:

  • the label must still elide rather than run under the buttons;
  • keep the utsb: back shown/hidden e2e hook working.

Proof:

  • the label's x is the same with and without Back, in the e2e harness (log its mapped x) or in a screenshot pair;
  • at 320 px width, a long book name ("Song of Solomon 8") elides cleanly.

Blast radius: trunk (qml/pages/ReadingPane.qml).

🤖 Generated with Claude Code

Found by the owner on the phone (build c0d97e6): > When the KJV bible is opened, the Gen 1 text sits slightly further left than when one navigates to a new chapter. I assume it's because the Back element isnt present, and the text is likely centered, so when the nav happens, the back element is added, and the middle element shrinks **Cause (confirmed in code):** - The footer in `qml/pages/ReadingPane.qml` (around line 91) is a `RowLayout` of three parts: Back, the book/chapter label (`Layout.fillWidth`, `AlignHCenter`) and the Bible button. - Back has `visible: reading.canGoBack`, so until the first jump it takes no space. The label is then centred in a wider space that starts at the left edge, so it sits left of centre. - When Back appears, the label's space narrows and the text moves right. **Fix:** centre the label on the footer itself, not on whatever space is left over. Two ways: - keep the label anchored to the toolbar's horizontal centre with side margins as wide as the wider side button, or - keep Back's slot always sized and only fade or disable it (but a permanently reserved slot wastes width on narrow phones). Either way: - the label must still elide rather than run under the buttons; - keep the `utsb: back shown/hidden` e2e hook working. **Proof:** - the label's x is the same with and without Back, in the e2e harness (log its mapped x) or in a screenshot pair; - at 320 px width, a long book name ("Song of Solomon 8") elides cleanly. Blast radius: trunk (`qml/pages/ReadingPane.qml`). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
schaefera/utStudyBIble#75
No description provided.