Skip to content

Commit 2e83895

Browse files
author
maxdev1
committed
Keep new-lines as position entries
1 parent ae29116 commit 2e83895

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

applications/libfont/src/text_layouter.cpp

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -155,19 +155,16 @@ void g_text_layouter::layout(cairo_t* cr, const char* text, g_font* font, int si
155155
y += lineHeight;
156156
}
157157

158-
if(!invisible)
159-
{
160-
// Position
161-
positioned.line = line;
162-
positioned.position.x = x;
163-
positioned.position.y = y + lineHeight;
158+
// Position
159+
positioned.line = line;
160+
positioned.position.x = x;
161+
positioned.position.y = y + lineHeight;
164162

165-
// Add position
166-
layout->positions.push_back(positioned);
163+
// Add position
164+
layout->positions.push_back(positioned);
167165

168-
// Jump to next
169-
x += positioned.advance.x;
170-
}
166+
// Jump to next
167+
x += positioned.advance.x;
171168

172169
// increase positions
173170
glyph_pos += cluster->num_glyphs;

0 commit comments

Comments
 (0)