Struct iced_native::renderer::Null
source · [−]pub struct Null;
Expand description
A renderer that does nothing.
It can be useful if you are writing tests!
Implementations
Trait Implementations
sourceimpl Renderer for Null
impl Renderer for Null
sourcefn with_layer(&mut self, _bounds: Rectangle, _f: impl FnOnce(&mut Self))
fn with_layer(&mut self, _bounds: Rectangle, _f: impl FnOnce(&mut Self))
Draws the primitives recorded in the given closure in a new layer. Read more
sourcefn with_translation(&mut self, _translation: Vector, _f: impl FnOnce(&mut Self))
fn with_translation(&mut self, _translation: Vector, _f: impl FnOnce(&mut Self))
Applies a translation
to the primitives recorded in the given closure.
sourcefn fill_quad(&mut self, _quad: Quad, _background: impl Into<Background>)
fn fill_quad(&mut self, _quad: Quad, _background: impl Into<Background>)
Fills a Quad
with the provided Background
.
sourceimpl Renderer for Null
impl Renderer for Null
sourceconst CHECKMARK_ICON: char = '0'
const CHECKMARK_ICON: char = '0'
sourceconst ARROW_DOWN_ICON: char = '0'
const ARROW_DOWN_ICON: char = '0'
sourcefn default_size(&self) -> u16
fn default_size(&self) -> u16
Returns the default size of Text
.
sourcefn measure(
&self,
_content: &str,
_size: u16,
_font: Font,
_bounds: Size
) -> (f32, f32)
fn measure(
&self,
_content: &str,
_size: u16,
_font: Font,
_bounds: Size
) -> (f32, f32)
Measures the text in the given bounds and returns the minimum boundaries that can fit the contents. Read more
sourcefn hit_test(
&self,
_contents: &str,
_size: f32,
_font: Self::Font,
_bounds: Size,
_point: Point,
_nearest_only: bool
) -> Option<Hit>
fn hit_test(
&self,
_contents: &str,
_size: f32,
_font: Self::Font,
_bounds: Size,
_point: Point,
_nearest_only: bool
) -> Option<Hit>
Tests whether the provided point is within the boundaries of text laid out with the given parameters, returning information about the nearest character. Read more
impl Copy for Null
Auto Trait Implementations
impl RefUnwindSafe for Null
impl Send for Null
impl Sync for Null
impl Unpin for Null
impl UnwindSafe for Null
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more