OpenTTD Source 20241224-master-gee860a5c8e
FallbackParagraphLayoutFactory Class Reference

Helper class to construct a new FallbackParagraphLayout. More...

#include <gfx_layout_fallback.h>

Public Types

typedef char32_t CharType
 Helper for GetLayouter, to get the right type.
 

Static Public Member Functions

static std::unique_ptr< ParagraphLayouterGetParagraphLayout (char32_t *buff, char32_t *buff_end, FontMap &font_mapping)
 Get the actual ParagraphLayout for the given buffer.
 
static size_t AppendToBuffer (char32_t *buff, const char32_t *buffer_last, char32_t c)
 Append a wide character to the internal buffer.
 

Static Public Attributes

static const bool SUPPORTS_RTL = false
 Helper for GetLayouter, to get whether the layouter supports RTL.
 

Detailed Description

Helper class to construct a new FallbackParagraphLayout.

Definition at line 18 of file gfx_layout_fallback.h.

Member Typedef Documentation

◆ CharType

Helper for GetLayouter, to get the right type.

Definition at line 21 of file gfx_layout_fallback.h.

Member Function Documentation

◆ AppendToBuffer()

size_t FallbackParagraphLayoutFactory::AppendToBuffer ( char32_t *  buff,
const char32_t *  buffer_last,
char32_t  c 
)
static

Append a wide character to the internal buffer.

Parameters
buffThe buffer to append to.
buffer_lastThe end of the buffer.
cThe character to add.
Returns
The number of buffer spaces that were used.

Definition at line 97 of file gfx_layout_fallback.cpp.

◆ GetParagraphLayout()

std::unique_ptr< ParagraphLayouter > FallbackParagraphLayoutFactory::GetParagraphLayout ( char32_t *  buff,
char32_t *  buff_end,
FontMap font_mapping 
)
static

Get the actual ParagraphLayout for the given buffer.

Parameters
buffThe begin of the buffer.
buff_endThe location after the last element in the buffer.
font_mappingThe mapping of the fonts.
Returns
The ParagraphLayout instance.

Definition at line 85 of file gfx_layout_fallback.cpp.

Field Documentation

◆ SUPPORTS_RTL

const bool FallbackParagraphLayoutFactory::SUPPORTS_RTL = false
static

Helper for GetLayouter, to get whether the layouter supports RTL.

Definition at line 23 of file gfx_layout_fallback.h.


The documentation for this class was generated from the following files: