pub struct Font {
pub name: String,
pub size: i32,
pub sheet_width: i32,
pub sheet_height: i32,
pub character_set: Option<String>,
pub sprite_sheet: Option<String>,
pub material: Option<String>,
pub char_map: Vec<i32>,
pub glyphs: Vec<[i32; 4]>,
pub unknown: [i32; 3],
}Expand description
UI::Font, block version 2.
Original: Runtime 0x180119f60.
Fields§
§name: StringThe font’s name.
size: i32The font’s size, in pixels.
sheet_width: i32The glyph sheet’s width.
sheet_height: i32The glyph sheet’s height.
character_set: Option<String>The character set resource.
sprite_sheet: Option<String>Sprite sheet holding one sprite per glyph, in glyph order.
material: Option<String>The material the glyphs are drawn with.
char_map: Vec<i32>Code point -> glyph index; negative or 0xffff means no glyph.
glyphs: Vec<[i32; 4]>Per glyph: (a, c, b, d): advance = a + b, with the previous glyph’s c added; d raises the bottom of the sprite above the baseline.
unknown: [i32; 3]Serialized descent, ellipsis advance, and space advance (Runtime Font/58/5c).
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Font
impl RefUnwindSafe for Font
impl Send for Font
impl Sync for Font
impl Unpin for Font
impl UnsafeUnpin for Font
impl UnwindSafe for Font
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more