Struct sensehat_screen::fonts::FONT_COLLECTION [−]
pub struct FONT_COLLECTION { /* fields omitted */ }
A static FontCollection
that offers a higher-level API for working with
pixel frames, clips, scrolls, etc.
FONT_COLLECTION.sanitize_str(&str)
returns a sanitized FontString
,
and use that to render pixel frames..
FONT_COLLECTION.get(font: char)
returns the low-level FontUnicode
if the font
is found in the collection.
Methods from __Deref<Target = FontCollection>
pub fn get(&self, symbol: char) -> Option<&FontUnicode>
[src]
pub fn get(&self, symbol: char) -> Option<&FontUnicode>
Get an Option
with the symbol's byte rendering.
pub fn contains_key(&self, symbol: char) -> bool
[src]
pub fn contains_key(&self, symbol: char) -> bool
Search if collection has a symbol by its unicode key.
pub fn sanitize_str(&self, s: &str) -> Result<FontString, FromUtf16Error>
[src]
pub fn sanitize_str(&self, s: &str) -> Result<FontString, FromUtf16Error>
Sanitize a &str
and create a new FontString
.
Trait Implementations
impl __Deref for FONT_COLLECTION
impl __Deref for FONT_COLLECTION
type Target = FontCollection
The resulting type after dereferencing.
fn deref(&self) -> &FontCollection
fn deref(&self) -> &FontCollection
Dereferences the value.
impl LazyStatic for FONT_COLLECTION
impl LazyStatic for FONT_COLLECTION
fn initialize(lazy: &Self)
fn initialize(lazy: &Self)
Auto Trait Implementations
impl Send for FONT_COLLECTION
impl Send for FONT_COLLECTION
impl Sync for FONT_COLLECTION
impl Sync for FONT_COLLECTION