10#ifndef GFX_LAYOUT_FALLBACK_H
11#define GFX_LAYOUT_FALLBACK_H
26 static size_t AppendToBuffer(
char32_t *buff,
const char32_t *buffer_last,
char32_t c);
39 case U
'(':
return U
')';
40 case U
')':
return U
'(';
41 case U
'[':
return U
']';
42 case U
']':
return U
'[';
43 case U
'{':
return U
'}';
44 case U
'}':
return U
'{';
Helper class to construct a new FallbackParagraphLayout.
char32_t CharType
Helper for GetLayouter, to get the right type.
static std::unique_ptr< ParagraphLayouter > GetParagraphLayout(char32_t *buff, char32_t *buff_end, FontMap &font_mapping)
Get the actual ParagraphLayout for the given buffer.
static const bool SUPPORTS_RTL
Helper for GetLayouter, to get whether the layouter supports RTL.
static size_t AppendToBuffer(char32_t *buff, const char32_t *buffer_last, char32_t c)
Append a wide character to the internal buffer.
Functions related to laying out the texts.
std::vector< std::pair< int, Font > > FontMap
Mapping from index to font.
char32_t SwapRtlPairedCharacters(char32_t c)
Swap paired brackets for fallback RTL layouting.