pub struct ShapeCollection { /* private fields */ }
Implementations§
Source§impl ShapeCollection
impl ShapeCollection
pub fn with_draw_type(&self, draw_type: DrawType) -> ShapeCollection
Source§impl ShapeCollection
impl ShapeCollection
pub fn with_translation<P>(&self, delta: P) -> ShapeCollection
pub fn with_move<P>(&self, xy: P) -> ShapeCollection
Source§impl ShapeCollection
impl ShapeCollection
pub fn with_scale(&self, scale: f32) -> ShapeCollection
Source§impl ShapeCollection
impl ShapeCollection
pub fn with_rotation(&self, degrees: isize) -> ShapeCollection
Source§impl ShapeCollection
impl ShapeCollection
pub fn with_scale_around<P>(&self, scale: f32, center: P) -> ShapeCollection
Source§impl ShapeCollection
impl ShapeCollection
pub fn with_rotation_around<P>( &self, degrees: isize, center: P, ) -> ShapeCollection
Source§impl ShapeCollection
impl ShapeCollection
pub fn iter(&self) -> Iter<'_, Drawable<ShapeBox>>
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn remove(&mut self, idx: usize) -> Drawable<ShapeBox>
pub fn bounds(&self) -> &Rect
pub fn left(&self) -> isize
pub fn top(&self) -> isize
pub fn bottom(&self) -> isize
pub fn right(&self) -> isize
pub fn center(&self) -> Coord
Trait Implementations§
Source§impl Clone for ShapeCollection
impl Clone for ShapeCollection
Source§fn clone(&self) -> ShapeCollection
fn clone(&self) -> ShapeCollection
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 ShapeCollection
impl Debug for ShapeCollection
Source§impl Default for ShapeCollection
impl Default for ShapeCollection
Source§fn default() -> ShapeCollection
fn default() -> ShapeCollection
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ShapeCollection
impl<'de> Deserialize<'de> for ShapeCollection
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ShapeCollection, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ShapeCollection, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl InsertDrawable<ShapeBox> for ShapeCollection
impl InsertDrawable<ShapeBox> for ShapeCollection
Source§impl<S> InsertShape<S> for ShapeCollectionwhere
S: Shape,
impl<S> InsertShape<S> for ShapeCollectionwhere
S: Shape,
Source§impl InsertShapeBox for ShapeCollection
impl InsertShapeBox for ShapeCollection
Source§impl PartialEq for ShapeCollection
impl PartialEq for ShapeCollection
Source§impl Renderable<ShapeCollection> for ShapeCollection
impl Renderable<ShapeCollection> for ShapeCollection
Source§impl Serialize for ShapeCollection
impl Serialize for ShapeCollection
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for ShapeCollection
Auto Trait Implementations§
impl Freeze for ShapeCollection
impl RefUnwindSafe for ShapeCollection
impl Send for ShapeCollection
impl Sync for ShapeCollection
impl Unpin for ShapeCollection
impl UnwindSafe for ShapeCollection
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<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.