pub struct EmuPoint(pub i64, pub i64);Expand description
2D 几何点(EMU 整数坐标)。
主要给以下场景使用:
- 连接器的 begin / end;
- freeform 的内部路径点(
a:cubicBezTo/a:lineTo/a:moveTo); - 占位符锚点(
a:off x="" y="")。
§与 python-pptx 的对应
python-pptx 中没有 EmuPoint 这样的直接类型;最接近的是
(x: int, y: int) 元组。本库用 NewType 是为了类型安全与可读性。
Tuple Fields§
§0: i64x 坐标(EMU)。
1: i64y 坐标(EMU)。
Implementations§
Trait Implementations§
impl Copy for EmuPoint
impl Eq for EmuPoint
impl StructuralPartialEq for EmuPoint
Auto Trait Implementations§
impl Freeze for EmuPoint
impl RefUnwindSafe for EmuPoint
impl Send for EmuPoint
impl Sync for EmuPoint
impl Unpin for EmuPoint
impl UnsafeUnpin for EmuPoint
impl UnwindSafe for EmuPoint
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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.