pub struct ElementPlacement {
pub x: u32,
pub y: u32,
pub width: u32,
pub height: u32,
}Expand description
Position and optional size for a slide element, in EMU.
Fields§
§x: u32§y: u32§width: u32§height: u32Implementations§
Source§impl ElementPlacement
impl ElementPlacement
Sourcepub const fn chart_defaults() -> Self
pub const fn chart_defaults() -> Self
Create placement with default chart dimensions (5“ × 3.75“).
Sourcepub const fn image_defaults() -> Self
pub const fn image_defaults() -> Self
Create placement with default image dimensions (2“ square).
Sourcepub fn with_position(self, x: u32, y: u32) -> Self
pub fn with_position(self, x: u32, y: u32) -> Self
Set position (fluent, consuming).
Sourcepub fn set_position(&mut self, x: u32, y: u32)
pub fn set_position(&mut self, x: u32, y: u32)
Set position (mutable builder style).
Trait Implementations§
Source§impl Clone for ElementPlacement
impl Clone for ElementPlacement
Source§fn clone(&self) -> ElementPlacement
fn clone(&self) -> ElementPlacement
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 ElementPlacement
Source§impl Debug for ElementPlacement
impl Debug for ElementPlacement
Source§impl Default for ElementPlacement
impl Default for ElementPlacement
Source§fn default() -> ElementPlacement
fn default() -> ElementPlacement
Returns the “default value” for a type. Read more
impl Eq for ElementPlacement
Source§impl PartialEq for ElementPlacement
impl PartialEq for ElementPlacement
Source§fn eq(&self, other: &ElementPlacement) -> bool
fn eq(&self, other: &ElementPlacement) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for ElementPlacement
Auto Trait Implementations§
impl Freeze for ElementPlacement
impl RefUnwindSafe for ElementPlacement
impl Send for ElementPlacement
impl Sync for ElementPlacement
impl Unpin for ElementPlacement
impl UnsafeUnpin for ElementPlacement
impl UnwindSafe for ElementPlacement
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