Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/core/StarFont.hpp
diff options
context:
space:
mode:
authorKae <80987908+Novaenia@users.noreply.github.com>2024-04-24 07:44:53 +1000
committerKae <80987908+Novaenia@users.noreply.github.com>2024-04-24 07:44:53 +1000
commitd0f8aec244a0d71f67863f94cab4c5f84d93de22 (patch)
treea8e69fa28b7841d942e7e5f994518a69916c45c8 /source/core/StarFont.hpp
parent6ac139321b2a03d71192f852ff958cf6176e1c2d (diff)
feat: unicode emoji support + other stuff
Diffstat (limited to 'source/core/StarFont.hpp')
-rw-r--r--source/core/StarFont.hpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/core/StarFont.hpp b/source/core/StarFont.hpp
index dee50f7..6686dbc 100644
--- a/source/core/StarFont.hpp
+++ b/source/core/StarFont.hpp
@@ -34,13 +34,15 @@ public:
// May return empty image on unrenderable character (Normally, this will
// render a box, but if there is an internal freetype error this may return
// an empty image).
- std::pair<Image, Vec2I> render(String::Char c);
+ tuple<Image, Vec2I, bool> render(String::Char c);
bool exists(String::Char c);
private:
FontImplPtr m_fontImpl;
ByteArrayConstPtr m_fontBuffer;
unsigned m_pixelSize;
+ unsigned m_loadedPixelSize;
+ String::Char m_loadedChar;
uint8_t m_alphaThreshold;
HashMap<pair<String::Char, unsigned>, unsigned> m_widthCache;