aboutsummaryrefslogtreecommitdiff
path: root/src/Text.cpp
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2021-05-05 15:04:32 +0200
committerdec05eba <dec05eba@protonmail.com>2021-05-05 15:04:32 +0200
commit9b6a875bb65000115451279ed17c7c51c4173fa7 (patch)
tree04323fed8063c816631e000cd382e172d50e3c7b /src/Text.cpp
parentb6b4db460ce5bfdfe7c4e46a89ef370b6cc31752 (diff)
Prepare youtube for auto fetch of api key, add author name for subscriptions item
Diffstat (limited to 'src/Text.cpp')
-rw-r--r--src/Text.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/Text.cpp b/src/Text.cpp
index cac485d..0431c4e 100644
--- a/src/Text.cpp
+++ b/src/Text.cpp
@@ -370,6 +370,7 @@ namespace QuickMedia
TextElement &textElement = textElements[textElementIndex];
const sf::Font *ff = latin_font;
int vertices_index = 0;
+ prevCodePoint = 0;
if(textElement.text_type == TextElement::TextType::CJK) {
ff = FontLoader::get_font(FontLoader::FontType::CJK);
vertices_index = 1;
@@ -513,13 +514,6 @@ namespace QuickMedia
glyphPos.x += glyph.advance + characterSpacing;
vertices_linear.push_back({vertices_index, vertexStart, 0, codePoint});
}
-
- //vertices[vertices_index][vertices[vertices_index].getVertexCount() - 4] = { sf::Vector2f(glyphPos.x, glyphPos.y - vspace), sf::Color::Transparent, sf::Vector2f() };
- //vertices[vertices_index][vertices[vertices_index].getVertexCount() - 3] = { sf::Vector2f(glyphPos.x, glyphPos.y - vspace), sf::Color::Transparent, sf::Vector2f() };
- //vertices[vertices_index][vertices[vertices_index].getVertexCount() - 2] = { sf::Vector2f(glyphPos.x, glyphPos.y - vspace), sf::Color::Transparent, sf::Vector2f() };
- //vertices[vertices_index][vertices[vertices_index].getVertexCount() - 1] = { sf::Vector2f(glyphPos.x, glyphPos.y - vspace), sf::Color::Transparent, sf::Vector2f() };
-
- prevCodePoint = 0;
}
const float line_height = floor(vspace + lineSpacing);