pub struct DrawBorder {
pub rect: Rect,
pub radius: Radius,
pub border: Border,
}Expand description
Layout-aware border drawn around a rounded rectangle.
§Examples
use ailloli_ui_core::{Border, Color, Radius, Rect};
use ailloli_ui_runtime::scene::DrawBorder;
let draw = DrawBorder {
rect: Rect::new(0.0, 0.0, 40.0, 20.0),
radius: Radius::uniform(3.0),
border: Border::new(1.0, Color::WHITE),
};
assert_eq!(draw.border.widths.left, 1.0);Fields§
§rect: RectBorder box in window-space logical pixels.
radius: RadiusPer-corner radii in logical pixels.
border: BorderPer-edge widths, colors, and stroke style.
Trait Implementations§
Source§impl Clone for DrawBorder
impl Clone for DrawBorder
Source§fn clone(&self) -> DrawBorder
fn clone(&self) -> DrawBorder
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DrawBorder
impl Debug for DrawBorder
Source§impl PartialEq for DrawBorder
impl PartialEq for DrawBorder
impl Copy for DrawBorder
impl StructuralPartialEq for DrawBorder
Auto Trait Implementations§
impl Freeze for DrawBorder
impl RefUnwindSafe for DrawBorder
impl Send for DrawBorder
impl Sync for DrawBorder
impl Unpin for DrawBorder
impl UnwindSafe for DrawBorder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<A> IntoClickAction<A> for Awhere
A: Clone + 'static,
impl<A> IntoClickAction<A> for Awhere
A: Clone + 'static,
Source§fn into_click_action(self) -> ClickAction<A>
fn into_click_action(self) -> ClickAction<A>
Implements the into_click_action helper used by this module.