#[non_exhaustive]pub enum Cmd {
Rect {
x: i32,
y: i32,
w: i32,
h: i32,
c: u32,
},
RRect {
x: i32,
y: i32,
w: i32,
h: i32,
r: u16,
t: u16,
fill: u32,
stroke: u32,
stroke2: u32,
},
PanelFx {
x: i32,
y: i32,
w: i32,
h: i32,
r: i32,
t: i32,
fill: u32,
stroke: u32,
},
Text {
x: i32,
y: i32,
font: u16,
size: i32,
c: u32,
maxw: i32,
s: Vec<u8>,
},
Icon {
x: i32,
y: i32,
cp: u32,
size: i32,
c: u32,
},
Image {
x: i32,
y: i32,
w: i32,
h: i32,
sf: Rc<Surface>,
ver: u32,
},
Clip {
x: i32,
y: i32,
w: i32,
h: i32,
},
Unclip,
Circle {
x: i32,
y: i32,
r: i32,
t: i32,
c: u32,
},
Line {
x0: i32,
y0: i32,
x1: i32,
y1: i32,
w: i32,
c: u32,
},
Custom {
x: i32,
y: i32,
w: i32,
h: i32,
f: Option<DrawRef>,
user: usize,
ver: u32,
},
Shadow {
x: i32,
y: i32,
w: i32,
h: i32,
r: i32,
depth: i32,
c: u32,
},
}Expand description
one recorded draw command [C_*]
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Rect
RRect
fill (alpha 0 = none), border t px in stroke, its bottom band in stroke2; r and t
are kept as u16
PanelFx
Fractional rounded panel; geometry is 24.8 pixels and composited once.
Text
text with baseline y; maxw != 0 clips it to x .. x + maxw
Icon
icon, em box top-left at x, y
Image
Clip
Unclip
Circle
24.8; t = 0 fills
Line
24.8, round caps
Custom
Shadow
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Cmd
impl !Send for Cmd
impl !Sync for Cmd
impl !UnwindSafe for Cmd
impl Forget for Cmd
impl Freeze for Cmd
impl Unpin for Cmd
impl UnsafeUnpin for Cmd
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