10 #ifndef STRING_UNISCRIBE_H 11 #define STRING_UNISCRIBE_H 13 #if defined(WITH_UNISCRIBE) 15 #include "../../gfx_layout.h" 16 #include "../../string_base.h" 20 void UniscribeResetScriptCache(
FontSize size);
26 class UniscribeParagraphLayoutFactory {
29 typedef wchar_t CharType;
31 static const bool SUPPORTS_RTL =
true;
49 static size_t AppendToBuffer(CharType *buff,
const CharType *buffer_last,
WChar c)
53 if (buff + 1 <= buffer_last) {
54 buff[0] = (CharType)(((c - 0x010000U) >> 10) + 0xD800);
55 buff[1] = (CharType)(((c - 0x010000U) & 0x3FF) + 0xDC00);
62 *buff = (CharType)(c & 0xFFFF);
76 std::vector<CharInfo> str_info;
77 std::vector<size_t> utf16_to_utf8;
82 void SetString(
const char *s)
override;
83 size_t SetCurPosition(
size_t pos)
override;
84 size_t Next(IterType what)
override;
85 size_t Prev(IterType what)
override;
Implementation of simple mapping class.
Interface to glue fallback and normal layouter into one.
FontSize
Available font sizes.
Class for iterating over different kind of parts of a string.
uint32 WChar
Type for wide characters, i.e.