Struct glium_glyph::GlyphBrush
source · pub struct GlyphBrush<'font, 'a, H: BuildHasher = DefaultSectionHasher> { /* private fields */ }
Implementations§
source§impl<'font, 'p> GlyphBrush<'font, 'p>
impl<'font, 'p> GlyphBrush<'font, 'p>
source§impl<'font, 'p, H: BuildHasher> GlyphBrush<'font, 'p, H>
impl<'font, 'p, H: BuildHasher> GlyphBrush<'font, 'p, H>
sourcepub fn queue_custom_layout<'a, S, G>(&mut self, section: S, custom_layout: &G)where
G: GlyphPositioner,
S: Into<Cow<'a, VariedSection<'a>>>,
pub fn queue_custom_layout<'a, S, G>(&mut self, section: S, custom_layout: &G)where
G: GlyphPositioner,
S: Into<Cow<'a, VariedSection<'a>>>,
Queues a section/layout to be drawn by the next call of
draw_queued
. Can be called multiple times
to queue multiple sections for drawing.
Used to provide custom GlyphPositioner
logic, if using built-in
Layout
simply use queue
Benefits from caching, see caching behaviour.
sourcepub fn queue<'a, S>(&mut self, section: S)where
S: Into<Cow<'a, VariedSection<'a>>>,
pub fn queue<'a, S>(&mut self, section: S)where
S: Into<Cow<'a, VariedSection<'a>>>,
Queues a section/layout to be drawn by the next call of
draw_queued
. Can be called multiple times
to queue multiple sections for drawing.
Benefits from caching, see caching behaviour.
pub fn draw_queued<F: Facade + Deref<Target = Context>>(
&mut self,
facade: &F,
frame: &mut Frame
)
pub fn draw_queued_with_transform<F: Facade + Deref<Target = Context>>(
&mut self,
transform: [[f32; 4]; 4],
facade: &F,
frame: &mut Frame
)
sourcepub fn fonts(&self) -> &[Font<'font>]
pub fn fonts(&self) -> &[Font<'font>]
Returns the available fonts.
The FontId
corresponds to the index of the font data.