Font

Inherits: Resource < RefCounted < Object

Inherited By: FontFile, FontVariation, SystemFont

There is currently no description for this class. Please help us by contributing one!

Properties

Font[]

fallbacks

[]

Methods

float

draw_char ( RID canvas_item, Vector2 pos, int char, int font_size, Color modulate=Color(1, 1, 1, 1) ) const

float

draw_char_outline ( RID canvas_item, Vector2 pos, int char, int font_size, int size=-1, Color modulate=Color(1, 1, 1, 1) ) const

void

draw_multiline_string ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int max_lines=-1, Color modulate=Color(1, 1, 1, 1), BitField<LineBreakFlag> brk_flags=3, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

void

draw_multiline_string_outline ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int max_lines=-1, int size=1, Color modulate=Color(1, 1, 1, 1), BitField<LineBreakFlag> brk_flags=3, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

void

draw_string ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, Color modulate=Color(1, 1, 1, 1), BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

void

draw_string_outline ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int size=1, Color modulate=Color(1, 1, 1, 1), BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

RID

find_variation ( Dictionary variation_coordinates, int face_index=0, float strength=0.0, Transform2D transform=Transform2D(1, 0, 0, 1, 0, 0), int spacing_top=0, int spacing_bottom=0, int spacing_space=0, int spacing_glyph=0, float baseline_offset=0.0 ) const

float

get_ascent ( int font_size=16 ) const

Vector2

get_char_size ( int char, int font_size ) const

float

get_descent ( int font_size=16 ) const

int

get_face_count ( ) const

String

get_font_name ( ) const

int

get_font_stretch ( ) const

BitField<FontStyle>

get_font_style ( ) const

String

get_font_style_name ( ) const

int

get_font_weight ( ) const

float

get_height ( int font_size=16 ) const

Vector2

get_multiline_string_size ( String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int max_lines=-1, BitField<LineBreakFlag> brk_flags=3, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

Dictionary

get_opentype_features ( ) const

Dictionary

get_ot_name_strings ( ) const

RID[]

get_rids ( ) const

int

get_spacing ( SpacingType spacing ) const

Vector2

get_string_size ( String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

String

get_supported_chars ( ) const

Dictionary

get_supported_feature_list ( ) const

Dictionary

get_supported_variation_list ( ) const

float

get_underline_position ( int font_size=16 ) const

float

get_underline_thickness ( int font_size=16 ) const

bool

has_char ( int char ) const

bool

is_language_supported ( String language ) const

bool

is_script_supported ( String script ) const

void

set_cache_capacity ( int single_line, int multi_line )


Property Descriptions

Font[] fallbacks = []

  • void set_fallbacks ( Font[] value )

  • Font[] get_fallbacks ( )

There is currently no description for this property. Please help us by contributing one!


Method Descriptions

float draw_char ( RID canvas_item, Vector2 pos, int char, int font_size, Color modulate=Color(1, 1, 1, 1) ) const

There is currently no description for this method. Please help us by contributing one!


float draw_char_outline ( RID canvas_item, Vector2 pos, int char, int font_size, int size=-1, Color modulate=Color(1, 1, 1, 1) ) const

There is currently no description for this method. Please help us by contributing one!


void draw_multiline_string ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int max_lines=-1, Color modulate=Color(1, 1, 1, 1), BitField<LineBreakFlag> brk_flags=3, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

There is currently no description for this method. Please help us by contributing one!


void draw_multiline_string_outline ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int max_lines=-1, int size=1, Color modulate=Color(1, 1, 1, 1), BitField<LineBreakFlag> brk_flags=3, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

There is currently no description for this method. Please help us by contributing one!


void draw_string ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, Color modulate=Color(1, 1, 1, 1), BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

There is currently no description for this method. Please help us by contributing one!


void draw_string_outline ( RID canvas_item, Vector2 pos, String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int size=1, Color modulate=Color(1, 1, 1, 1), BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

There is currently no description for this method. Please help us by contributing one!


RID find_variation ( Dictionary variation_coordinates, int face_index=0, float strength=0.0, Transform2D transform=Transform2D(1, 0, 0, 1, 0, 0), int spacing_top=0, int spacing_bottom=0, int spacing_space=0, int spacing_glyph=0, float baseline_offset=0.0 ) const

There is currently no description for this method. Please help us by contributing one!


float get_ascent ( int font_size=16 ) const

There is currently no description for this method. Please help us by contributing one!


Vector2 get_char_size ( int char, int font_size ) const

There is currently no description for this method. Please help us by contributing one!


float get_descent ( int font_size=16 ) const

There is currently no description for this method. Please help us by contributing one!


int get_face_count ( ) const

There is currently no description for this method. Please help us by contributing one!


String get_font_name ( ) const

There is currently no description for this method. Please help us by contributing one!


int get_font_stretch ( ) const

There is currently no description for this method. Please help us by contributing one!


BitField<FontStyle> get_font_style ( ) const

There is currently no description for this method. Please help us by contributing one!


String get_font_style_name ( ) const

There is currently no description for this method. Please help us by contributing one!


int get_font_weight ( ) const

There is currently no description for this method. Please help us by contributing one!


float get_height ( int font_size=16 ) const

There is currently no description for this method. Please help us by contributing one!


Vector2 get_multiline_string_size ( String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, int max_lines=-1, BitField<LineBreakFlag> brk_flags=3, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

There is currently no description for this method. Please help us by contributing one!


Dictionary get_opentype_features ( ) const

There is currently no description for this method. Please help us by contributing one!


Dictionary get_ot_name_strings ( ) const

There is currently no description for this method. Please help us by contributing one!


RID[] get_rids ( ) const

There is currently no description for this method. Please help us by contributing one!


int get_spacing ( SpacingType spacing ) const

There is currently no description for this method. Please help us by contributing one!


Vector2 get_string_size ( String text, HorizontalAlignment alignment=0, float width=-1, int font_size=16, BitField<JustificationFlag> justification_flags=3, Direction direction=0, Orientation orientation=0 ) const

There is currently no description for this method. Please help us by contributing one!


String get_supported_chars ( ) const

There is currently no description for this method. Please help us by contributing one!


Dictionary get_supported_feature_list ( ) const

There is currently no description for this method. Please help us by contributing one!


Dictionary get_supported_variation_list ( ) const

There is currently no description for this method. Please help us by contributing one!


float get_underline_position ( int font_size=16 ) const

There is currently no description for this method. Please help us by contributing one!


float get_underline_thickness ( int font_size=16 ) const

There is currently no description for this method. Please help us by contributing one!


bool has_char ( int char ) const

There is currently no description for this method. Please help us by contributing one!


bool is_language_supported ( String language ) const

There is currently no description for this method. Please help us by contributing one!


bool is_script_supported ( String script ) const

There is currently no description for this method. Please help us by contributing one!


void set_cache_capacity ( int single_line, int multi_line )

There is currently no description for this method. Please help us by contributing one!