Struct gdnative::BitmapFont
[−]
[src]
pub struct BitmapFont { /* fields omitted */ }
core class BitmapFont : Font
(reference counted)
Base class
BitmapFont inherits Font and all of its methods.
Memory management
The lifetime of this object is automatically managed through reference counting.
Methods
impl BitmapFont
[src]
pub fn as_font(&self) -> Font
[src]
Up-cast.
pub fn new() -> Self
[src]
pub fn new_ref(&self) -> Self
[src]
Creates a new reference to the same object.
pub fn create_from_fnt(&mut self, path: GodotString) -> GodotResult
[src]
pub fn set_height(&mut self, px: f64)
[src]
pub fn set_ascent(&mut self, px: f64)
[src]
pub fn add_kerning_pair(&mut self, char_a: i64, char_b: i64, kerning: i64)
[src]
pub fn get_kerning_pair(&self, char_a: i64, char_b: i64) -> i64
[src]
pub fn add_texture(&mut self, texture: Option<Texture>)
[src]
pub fn add_char(
&mut self,
character: i64,
texture: i64,
rect: Rect2,
align: Vector2,
advance: f64
)
[src]
&mut self,
character: i64,
texture: i64,
rect: Rect2,
align: Vector2,
advance: f64
)
pub fn get_texture_count(&self) -> i64
[src]
pub fn get_texture(&self, idx: i64) -> Option<Texture>
[src]
pub fn get_char_size(&self, char: i64, next: i64) -> Vector2
[src]
pub fn set_distance_field_hint(&mut self, enable: bool)
[src]
pub fn clear(&mut self)
[src]
pub fn _set_chars(&mut self, arg0: Int32Array)
[src]
pub fn _get_chars(&self) -> Int32Array
[src]
pub fn _set_kernings(&mut self, arg0: Int32Array)
[src]
pub fn _get_kernings(&self) -> Int32Array
[src]
pub fn _set_textures(&mut self, arg0: VariantArray)
[src]
pub fn _get_textures(&self) -> VariantArray
[src]
pub fn set_fallback(&mut self, fallback: Option<BitmapFont>)
[src]
pub fn get_fallback(&self) -> Option<BitmapFont>
[src]
pub fn cast<T: GodotObject>(&self) -> Option<T>
[src]
Methods from Deref<Target = Font>
pub fn as_resource(&self) -> Resource
[src]
Up-cast.
pub fn draw(
&self,
canvas_item: Rid,
position: Vector2,
string: GodotString,
modulate: Color,
clip_w: i64
)
[src]
&self,
canvas_item: Rid,
position: Vector2,
string: GodotString,
modulate: Color,
clip_w: i64
)
pub fn get_ascent(&self) -> f64
[src]
pub fn get_descent(&self) -> f64
[src]
pub fn get_height(&self) -> f64
[src]
pub fn is_distance_field_hint(&self) -> bool
[src]
pub fn get_string_size(&self, string: GodotString) -> Vector2
[src]
pub fn draw_char(
&self,
canvas_item: Rid,
position: Vector2,
char: i64,
next: i64,
modulate: Color
) -> f64
[src]
&self,
canvas_item: Rid,
position: Vector2,
char: i64,
next: i64,
modulate: Color
) -> f64
pub fn update_changes(&mut self)
[src]
pub fn cast<T: GodotObject>(&self) -> Option<T>
[src]
Trait Implementations
impl GodotObject for BitmapFont
[src]
fn class_name() -> &'static str
[src]
unsafe fn from_sys(obj: *mut godot_object) -> Self
[src]
unsafe fn to_sys(&self) -> *mut godot_object
[src]
impl Deref for BitmapFont
[src]
type Target = Font
The resulting type after dereferencing.
fn deref(&self) -> &Self::Target
[src]
Dereferences the value.