diff options
Diffstat (limited to 'src/Text.cpp')
-rw-r--r-- | src/Text.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Text.cpp b/src/Text.cpp index a00d068..44730c3 100644 --- a/src/Text.cpp +++ b/src/Text.cpp @@ -282,14 +282,15 @@ namespace QuickMedia if(!update_even_if_not_dirty && !dirty) return; + dirty = false; vertices_linear.clear(); vertices[0].clear(); vertices[1].clear(); + boundingBox = sf::FloatRect(); + float hspace = font->getGlyph(' ', characterSize, false).advance + characterSpacing; float vspace = font->getLineSpacing(characterSize); // TODO: What about japanese font??? - boundingBox = sf::FloatRect(); - sf::Vector2f glyphPos; sf::Uint32 prevCodePoint = 0; for(usize textElementIndex = 0; textElementIndex < textElements.size(); ++textElementIndex) @@ -464,7 +465,6 @@ namespace QuickMedia boundingBox.width = std::max(boundingBox.width, get_text_quad_right_side(vertex_ref)); } boundingBox.height = num_lines * line_height; - dirty = false; // TODO: Clear vertices_linear when not in edit mode, but take into consideration switching between edit/not-edit mode } |