Compare commits

...

2 Commits

Author SHA1 Message Date
Jonas Diemer
5cfc4f562d
Merge 6905dbd23a into 56ec3dfb6d 2026-01-14 09:38:19 -05:00
Jonas Diemer
6905dbd23a Reclaim space if we don't show battery Percentage 2026-01-13 12:04:03 +01:00

View File

@ -447,7 +447,8 @@ void EpubReaderActivity::renderStatusBar(const int orientedMarginRight, const in
if (showChapterTitle) {
// Centered chatper title text
// Page width minus existing content with 30px padding on each side
const int titleMarginLeft = 50 + 30 + orientedMarginLeft; // 50px for battery
const int batterySize = showBattery ? (showBatteryPercentage ? 50 : 20) : 0;
const int titleMarginLeft = batterySize + 30 + orientedMarginLeft;
const int titleMarginRight = progressTextWidth + 30 + orientedMarginRight;
const int availableTextWidth = renderer.getScreenWidth() - titleMarginLeft - titleMarginRight;
const int tocIndex = epub->getTocIndexForSpineIndex(currentSpineIndex);