[][src]Struct google_docs1::CropProperties

pub struct CropProperties {
    pub offset_bottom: Option<f32>,
    pub angle: Option<f32>,
    pub offset_left: Option<f32>,
    pub offset_right: Option<f32>,
    pub offset_top: Option<f32>,
}

The crop properties of an image.

The crop rectangle is represented using fractional offsets from the original content's four edges.

  • If the offset is in the interval (0, 1), the corresponding edge of crop rectangle is positioned inside of the image's original bounding rectangle.
  • If the offset is negative or greater than 1, the corresponding edge of crop rectangle is positioned outside of the image's original bounding rectangle.
  • If all offsets and rotation angle are 0, the image is not cropped.

This type is not used in any activity, and only used as part of another schema.

Fields

offset_bottom: Option<f32>

The offset specifies how far inwards the bottom edge of the crop rectangle is from the bottom edge of the original content as a fraction of the original content's height.

angle: Option<f32>

The clockwise rotation angle of the crop rectangle around its center, in radians. Rotation is applied after the offsets.

offset_left: Option<f32>

The offset specifies how far inwards the left edge of the crop rectangle is from the left edge of the original content as a fraction of the original content's width.

offset_right: Option<f32>

The offset specifies how far inwards the right edge of the crop rectangle is from the right edge of the original content as a fraction of the original content's width.

offset_top: Option<f32>

The offset specifies how far inwards the top edge of the crop rectangle is from the top edge of the original content as a fraction of the original content's height.

Trait Implementations

impl Clone for CropProperties[src]

impl Debug for CropProperties[src]

impl Default for CropProperties[src]

impl<'de> Deserialize<'de> for CropProperties[src]

impl Part for CropProperties[src]

impl Serialize for CropProperties[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Typeable for T where
    T: Any