Tryst::SDL::Font
A TrueType/OpenType font at a fixed point size, for rendering text into a Texture via Renderer#load_font.
TTF_RenderText_Blended hands back straight alpha with the foreground colour baked into fully-transparent background pixels - a blend mode that reads source RGB independently of source alpha would show that colour as a solid rect. #render_text premultiplies the surface itself and tags the resulting texture with BlendMode::BlendPremultiplied, which is the exact blend SDL3 ships for this - no custom-composed blend mode needed the way porting this from SDL2 would otherwise call for.
Constructors
Instance methods
Distance from the baseline to the top of the tallest glyph in this font - useful for cropping rendered text to its visible glyph area rather than the full line height.
The pixel size text would occupy if rendered now, without
rendering it - for layout math that only needs the dimensions.