Compare commits

..

1 Commits

Author SHA1 Message Date
Jonas Diemer
6ba5d9dcec
Merge b45d0238f4 into c262f222de 2025-12-15 19:38:51 +01:00

View File

@ -123,11 +123,8 @@ void ParsedText::layoutAndExtractLines(const GfxRenderer& renderer, const int fo
// Calculate spacing
int spareSpace = pageWidth - lineWordWidthSum;
// width of 1em to indent first line of paragraph
const int indentWidth = 1 * renderer.getTextWidth(fontId, "m", REGULAR);
if (!extraParagraphSpacing && wordWidthIndex ==0) {
spareSpace -= indentWidth;
spareSpace -= 3*spaceWidth;
}
int spacing = spaceWidth;
const bool isLastLine = lineBreak == totalWordCount;
@ -139,7 +136,7 @@ void ParsedText::layoutAndExtractLines(const GfxRenderer& renderer, const int fo
// Calculate initial x position
uint16_t xpos = 0;
if (!extraParagraphSpacing && wordWidthIndex ==0) {
xpos = indentWidth;
xpos = 3*spaceWidth;
}
if (style == TextBlock::RIGHT_ALIGN) {
xpos = spareSpace - (lineWordCount - 1) * spaceWidth;