Skip to main content

ShapePropertiesExt

Trait ShapePropertiesExt 

Source
pub trait ShapePropertiesExt {
    // Required methods
    fn offset_emu(&self) -> Option<(i64, i64)>;
    fn extent_emu(&self) -> Option<(i64, i64)>;
    fn rotation_angle_deg(&self) -> Option<f64>;
    fn is_flip_h(&self) -> bool;
    fn is_flip_v(&self) -> bool;
    fn has_line(&self) -> bool;
}
Expand description

Extension methods for CTShapeProperties (ECMA-376 §20.1.6.6, CT_ShapeProperties).

Provides convenient access to position, size, rotation, and line properties. All coordinate values are in EMU (914400 per inch).

Required Methods§

Source

fn offset_emu(&self) -> Option<(i64, i64)>

Get the position offset in EMU as (x, y).

Returns None if no transform or offset is set.

Source

fn extent_emu(&self) -> Option<(i64, i64)>

Get the extent (width, height) in EMU.

Returns None if no transform or extents are set.

Source

fn rotation_angle_deg(&self) -> Option<f64>

Get the rotation angle in degrees (rot / 60000.0).

Source

fn is_flip_h(&self) -> bool

Check if the shape is flipped horizontally.

Source

fn is_flip_v(&self) -> bool

Check if the shape is flipped vertically.

Source

fn has_line(&self) -> bool

Check if the shape has an explicit line (stroke) defined.

Implementors§