pub struct WasmRect { /* private fields */ }
Implementations§
Source§impl WasmRect
impl WasmRect
pub fn new(origin: &WasmCoordinates, shape: &WasmShape) -> WasmRect
pub fn from_shape(shape: &WasmShape) -> WasmRect
pub fn from_origin(origin: &WasmCoordinates) -> WasmRect
pub fn from_xywh(x: u32, y: u32, width: u32, height: u32) -> WasmRect
pub fn from_many(rects: Vec<WasmRect>) -> Result<WasmRect, JsValue>
pub fn origin(&self) -> WasmCoordinates
pub fn shape(&self) -> WasmShape
pub fn into_many(&self) -> Vec<WasmRect>
pub fn into_single(&self) -> Vec<WasmRect>
pub fn into_perimeter(&self, offset: u32, size: u32) -> Vec<WasmRect>
pub fn into_bisector(&self, offset: u32, size: u32) -> Vec<WasmRect>
pub fn into_center(&self, offset: u32, size: u32) -> Vec<WasmRect>
pub fn into_rhombus(&self, dial: u32) -> Vec<WasmRect>
pub fn into_circle(&self) -> Vec<WasmRect>
pub fn into_odds(&self) -> Vec<WasmRect>
pub fn into_evens(&self) -> Vec<WasmRect>
Trait Implementations§
Source§impl FromWasmAbi for WasmRect
impl FromWasmAbi for WasmRect
Source§impl IntoWasmAbi for WasmRect
impl IntoWasmAbi for WasmRect
Source§impl LongRefFromWasmAbi for WasmRect
impl LongRefFromWasmAbi for WasmRect
Source§impl OptionFromWasmAbi for WasmRect
impl OptionFromWasmAbi for WasmRect
Source§impl OptionIntoWasmAbi for WasmRect
impl OptionIntoWasmAbi for WasmRect
Source§impl RefFromWasmAbi for WasmRect
impl RefFromWasmAbi for WasmRect
Source§impl RefMutFromWasmAbi for WasmRect
impl RefMutFromWasmAbi for WasmRect
Source§impl TryFromJsValue for WasmRect
impl TryFromJsValue for WasmRect
Source§impl VectorFromWasmAbi for WasmRect
impl VectorFromWasmAbi for WasmRect
Source§impl VectorIntoWasmAbi for WasmRect
impl VectorIntoWasmAbi for WasmRect
Source§impl WasmWrapper<Rect> for WasmRect
impl WasmWrapper<Rect> for WasmRect
impl Eq for WasmRect
impl StructuralPartialEq for WasmRect
impl SupportsConstructor for WasmRect
impl SupportsInstanceProperty for WasmRect
impl SupportsStaticProperty for WasmRect
Auto Trait Implementations§
impl Freeze for WasmRect
impl RefUnwindSafe for WasmRect
impl Send for WasmRect
impl Sync for WasmRect
impl Unpin for WasmRect
impl UnwindSafe for WasmRect
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.Source§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
Same as
IntoWasmAbi::Abi
Source§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
Same as
IntoWasmAbi::into_abi
, except that it may throw and never
return in the case of Err
.