From 93eb4851d708cd152d848ed05b8f2134b0db1a2d Mon Sep 17 00:00:00 2001 From: Jaakko Keränen Date: Fri, 2 Jul 2021 06:50:52 +0300 Subject: Text: Word wrapping; fixed glyph caching --- src/ui/text.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/ui/text.h') diff --git a/src/ui/text.h b/src/ui/text.h index fe42a308..26965f52 100644 --- a/src/ui/text.h +++ b/src/ui/text.h @@ -176,10 +176,16 @@ int drawWrapRange_Text (int fontId, iInt2 pos, int maxWidth, int color, iDeclareType(WrapText) +enum iWrapTextMode { + anyCharacter_WrapTextMode, + word_WrapTextMode, +}; + struct Impl_WrapText { /* arguments */ iRangecc text; int maxWidth; + enum iWrapTextMode mode; iBool (*wrapFunc)(iWrapText *, iRangecc wrappedText, int advance); void * context; /* output */ -- cgit v1.2.3