|
OpenTTD Source 20251213-master-g1091fa6071
|
Visual run contains data about the bit of text with the same font. More...
Public Member Functions | |
| FallbackVisualRun (const Font &font, const char32_t *chars, int glyph_count, int char_offset, int x) | |
| Create the visual run. | |
| const Font & | GetFont () const override |
| int | GetGlyphCount () const override |
| std::span< const GlyphID > | GetGlyphs () const override |
| std::span< const Position > | GetPositions () const override |
| int | GetLeading () const override |
| std::span< const int > | GetGlyphToCharMap () const override |
Private Attributes | |
| std::vector< GlyphID > | glyphs |
| The glyphs we're drawing. | |
| std::vector< Position > | positions |
| The positions of the glyphs. | |
| std::vector< int > | glyph_to_char |
| The char index of the glyphs. | |
| Font | font |
| The font used to layout these. | |
Visual run contains data about the bit of text with the same font.
Definition at line 42 of file gfx_layout_fallback.cpp.
| FallbackParagraphLayout::FallbackVisualRun::FallbackVisualRun | ( | const Font & | font, |
| const char32_t * | chars, | ||
| int | char_count, | ||
| int | char_offset, | ||
| int | x | ||
| ) |
Create the visual run.
| font | The font to use for this run. |
| chars | The characters to use for this run. |
| char_count | The number of characters in this run. |
| char_offset | This run's offset from the start of the layout input string. |
| x | The initial x position for this run. |
Definition at line 113 of file gfx_layout_fallback.cpp.
References FontCache::GetGlyphWidth(), and FontCache::MapCharToGlyph().
|
inlineoverridevirtual |
Implements ParagraphLayouter::VisualRun.
Definition at line 51 of file gfx_layout_fallback.cpp.
|
inlineoverridevirtual |
Implements ParagraphLayouter::VisualRun.
Definition at line 52 of file gfx_layout_fallback.cpp.
|
inlineoverridevirtual |
Implements ParagraphLayouter::VisualRun.
Definition at line 53 of file gfx_layout_fallback.cpp.
|
inlineoverridevirtual |
Implements ParagraphLayouter::VisualRun.
Definition at line 56 of file gfx_layout_fallback.cpp.
|
inlineoverridevirtual |
Implements ParagraphLayouter::VisualRun.
Definition at line 55 of file gfx_layout_fallback.cpp.
|
inlineoverridevirtual |
Implements ParagraphLayouter::VisualRun.
Definition at line 54 of file gfx_layout_fallback.cpp.
|
private |
The font used to layout these.
Definition at line 47 of file gfx_layout_fallback.cpp.
|
private |
The char index of the glyphs.
Definition at line 45 of file gfx_layout_fallback.cpp.
|
private |
The glyphs we're drawing.
Definition at line 43 of file gfx_layout_fallback.cpp.
|
private |
The positions of the glyphs.
Definition at line 44 of file gfx_layout_fallback.cpp.