#[non_exhaustive]pub enum GizmoShape {
Rect {
rect: PxRect,
},
Line {
from: (i32, i32),
to: (i32, i32),
},
Cross {
at: (i32, i32),
size: u8,
},
Circle {
center: (i32, i32),
radius: u16,
},
Label {
at: (i32, i32),
text: LabelText,
},
}Expand description
A gizmo’s shape as the frame keeps it, in console pixels.
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
The outline of a rectangle, one pixel wide, inside it.
Line
A line one pixel wide, both ends drawn.
Cross
A plus: size pixels each way from its centre.
Circle
The outline of a circle, 2 × radius + 1 pixels across.
Label
Text in the glyph cells from the one holding at: its glyphs are
in the cells, and the item draws no pixels.
Implementations§
Trait Implementations§
Source§impl Clone for GizmoShape
impl Clone for GizmoShape
Source§fn clone(&self) -> GizmoShape
fn clone(&self) -> GizmoShape
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for GizmoShape
Source§impl Debug for GizmoShape
impl Debug for GizmoShape
impl Eq for GizmoShape
Source§impl Hash for GizmoShape
impl Hash for GizmoShape
Source§impl PartialEq for GizmoShape
impl PartialEq for GizmoShape
impl StructuralPartialEq for GizmoShape
Auto Trait Implementations§
impl Freeze for GizmoShape
impl RefUnwindSafe for GizmoShape
impl Send for GizmoShape
impl Sync for GizmoShape
impl Unpin for GizmoShape
impl UnsafeUnpin for GizmoShape
impl UnwindSafe for GizmoShape
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