Font
Object Hierarchy:
Description:
[ CCode ( cname = "TTF_Font" , free_function = "TTF_CloseFont" ) ]
[ Compact ]
public class Font
[ Compact ]
public class Font
Namespace: SDLTTF
Package: SDL2_ttf
Content:
Properties:
- public FontStyle font_style { get; set; }
- public FontHinting hinting { get; set; }
- public bool kerning_allowed { get; set; }
- public int outline { get; set; }
Creation methods:
- public Font (string file, int ptsize)
- public Font.dpi (string file, int ptsize, uint hdpi, uint vdpi)
- public Font.dpi_index (string file, int ptsize, long index, uint hdpi, uint vdpi)
- public Font.from_rwops (RWops src, int ptsize, bool freesrc = false)
- public Font.from_rwops_dpi (RWops src, int ptsize, uint hdpi, uint vdpi, bool freesrc = false)
- public Font.from_rwops_index (RWops src, int ptsize, long index, bool freesrc = false)
- public Font.from_rwops_index_dpi (RWops src, int ptsize, long index, uint hdpi, uint vdpi, bool freesrc = false)
- public Font.index (string file, int ptsize, long index)
Methods:
- public int get_ascent ()
- public int get_descent ()
- public long get_faces ()
- public unowned string? get_family_name ()
- public int get_height ()
- public int get_kerning_size (unichar previous_ch, unichar ch)
- public int get_kerning_size_utf16 (unichar2 previous_ch, unichar ch)
- public int get_lineskip ()
- public int get_metrics (unichar ch, out int minx, out int maxx, out int miny, out int maxy, out int advance)
- public int get_metrics_16 (unichar2 utf16_ch, out int minx, out int maxx, out int miny, out int maxy, out int advance)
- public int get_size (string text, out int w, out int h)
- public int get_size_latin1 (uint8[] text, out int w, out int h)
- public int get_size_utf16 (string16 text, out int w, out int h)
- public unowned string? get_style_name ()
- public bool is_fixed_width ()
- public int measure_text (string text, int measure_width, out int extent, out int count)
- public int measure_text_latin1 (uint8[] text, int measure_width, out int extent, out int count)
- public int measure_text_utf16 (string16 text, int measure_width, out int extent, out int count)
- public bool provides_glyph (unichar ch)
- public bool provides_glyph_16 (unichar2 ch)
- public Surface? render (string text, Color fg)
- public Surface? render_blended (string text, Color fg)
- public Surface? render_blended_latin1 (uint8[] text, Color fg)
- public Surface? render_blended_utf16 (string16 text, Color fg)
- public Surface? render_blended_wrapped (string text, Color fg, uint32 wrap_length)
- public Surface? render_blended_wrapped_latin1 (uint8[] text, Color fg, uint32 wrap_length)
- public Surface? render_blended_wrapped_utf16 (string16 text, Color fg, uint32 wrap_length)
- public Surface? render_glyph_blended (unichar ch, Color fg)
- public Surface? render_glyph_blended_utf16 (unichar2 ch, Color fg)
- public Surface? render_glyph_shaded (unichar ch, Color fg, Color bg)
- public Surface? render_glyph_shaded_utf16 (unichar2 ch, Color fg, Color bg)
- public Surface? render_latin1 (uint8[] text, Color fg)
- public Surface? render_shaded (string text, Color fg, Color bg)
- public Surface? render_shaded_latin1 (uint8[] text, Color fg, Color bg)
- public Surface? render_shaded_utf16 (string16 text, Color fg, Color bg)
- public Surface? render_shaded_wrapped (string text, Color fg, Color bg, uint32 wrap_length)
- public Surface? render_shaded_wrapped_latin1 (uint8[] text, Color fg, Color bg, uint32 wrap_length)
- public Surface? render_shaded_wrapped_utf16 (string16 text, Color fg, Color bg, uint32 wrap_length)
- public Surface? render_utf16 (string16 text, Color fg)
- public int set_size (int ptsize)
- public int set_size_dpi (int ptsize, uint hdpi, uint vdpi)