Skip to main content

CompositionSurfaceBrushProps

Struct CompositionSurfaceBrushProps 

Source
pub struct CompositionSurfaceBrushProps { /* private fields */ }
Expand description

The UI-thread properties of CompositionSurfaceBrush.

Implementations§

Source§

impl CompositionSurfaceBrushProps

Source

pub fn new() -> Self

Creates the properties with every field at the default of its type. The defaults of the schema are applied by initialize_defaults.

Source

pub fn base(&self) -> &CompositionBrushProps

The properties of the base class.

Source

pub fn initialize_defaults(&self, host: &dyn CompositionSurfaceBrushHooks)

The InitializeDefaults calls of the constructor chain: the base classes first, then this class.

Source

pub fn initialize_own_defaults(&self, host: &dyn CompositionSurfaceBrushHooks)

InitializeDefaults of this class alone.

Source

pub fn surface(&self) -> Option<Rc<dyn ICompositionObject>>

Surface (FerroUI overlay).

Source

pub fn set_surface( &self, host: &dyn CompositionSurfaceBrushHooks, value: Option<Rc<dyn ICompositionObject>>, )

Sets Surface (FerroUI overlay).

Source

pub fn stretch(&self) -> CompositionStretch

Stretch (default CompositionStretch::Fill, FerroUI overlay).

Source

pub fn set_stretch( &self, host: &dyn CompositionSurfaceBrushHooks, value: CompositionStretch, )

Sets Stretch (default CompositionStretch::Fill, FerroUI overlay).

Source

pub fn horizontal_alignment_ratio(&self) -> f32

HorizontalAlignmentRatio (animated, default 0.5, FerroUI overlay).

Source

pub fn set_horizontal_alignment_ratio( &self, host: &dyn CompositionSurfaceBrushHooks, value: f32, )

Sets HorizontalAlignmentRatio (animated, default 0.5, FerroUI overlay).

Source

pub fn vertical_alignment_ratio(&self) -> f32

VerticalAlignmentRatio (animated, default 0.5, FerroUI overlay).

Source

pub fn set_vertical_alignment_ratio( &self, host: &dyn CompositionSurfaceBrushHooks, value: f32, )

Sets VerticalAlignmentRatio (animated, default 0.5, FerroUI overlay).

Source

pub fn bitmap_interpolation_mode(&self) -> CompositionBitmapInterpolationMode

BitmapInterpolationMode (default CompositionBitmapInterpolationMode::Linear, FerroUI overlay).

Source

pub fn set_bitmap_interpolation_mode( &self, host: &dyn CompositionSurfaceBrushHooks, value: CompositionBitmapInterpolationMode, )

Sets BitmapInterpolationMode (default CompositionBitmapInterpolationMode::Linear, FerroUI overlay).

Source

pub fn anchor_point(&self) -> Vector

AnchorPoint (animated, FerroUI overlay).

Source

pub fn set_anchor_point( &self, host: &dyn CompositionSurfaceBrushHooks, value: Vector, )

Sets AnchorPoint (animated, FerroUI overlay).

Source

pub fn center_point(&self) -> Vector

CenterPoint (animated, FerroUI overlay).

Source

pub fn set_center_point( &self, host: &dyn CompositionSurfaceBrushHooks, value: Vector, )

Sets CenterPoint (animated, FerroUI overlay).

Source

pub fn offset(&self) -> Vector

Offset (animated, FerroUI overlay).

Source

pub fn set_offset(&self, host: &dyn CompositionSurfaceBrushHooks, value: Vector)

Sets Offset (animated, FerroUI overlay).

Source

pub fn rotation_angle(&self) -> f32

RotationAngle (animated, FerroUI overlay).

Source

pub fn set_rotation_angle( &self, host: &dyn CompositionSurfaceBrushHooks, value: f32, )

Sets RotationAngle (animated, FerroUI overlay).

Source

pub fn scale(&self) -> Vector

Scale (animated, default Vector::new(1.0, 1.0), FerroUI overlay).

Source

pub fn set_scale(&self, host: &dyn CompositionSurfaceBrushHooks, value: Vector)

Sets Scale (animated, default Vector::new(1.0, 1.0), FerroUI overlay).

Source

pub fn transform_matrix(&self) -> Matrix

TransformMatrix (animated, default Matrix::IDENTITY, FerroUI overlay).

Source

pub fn set_transform_matrix( &self, host: &dyn CompositionSurfaceBrushHooks, value: Matrix, )

Sets TransformMatrix (animated, default Matrix::IDENTITY, FerroUI overlay).

Source

pub fn snap_to_pixels(&self) -> bool

SnapToPixels (FerroUI overlay).

Source

pub fn set_snap_to_pixels( &self, host: &dyn CompositionSurfaceBrushHooks, value: bool, )

Sets SnapToPixels (FerroUI overlay).

Source

pub fn start_animation( &self, host: &dyn CompositionSurfaceBrushHooks, property_name: &str, animation: &dyn ICompositionAnimation, final_value: Option<ExpressionVariant>, ) -> bool

Connects an animation with the named property. Returns false when neither this class nor its generated bases have an animated property of that name: the caller continues with its hand-written base.

Source

pub fn serialize_changes_core( &self, host: &dyn CompositionSurfaceBrushHooks, writer: &mut BatchStreamWriter<'_>, )

Writes the changes of the object: the base class first, then the changed-fields mask and the changed members of this class.

Trait Implementations§

Source§

impl Default for CompositionSurfaceBrushProps

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> ClassDefaults for T
where T: ?Sized,

Source§

fn static_constructor()

The static constructor of a type: work done once per thread, after the properties of the type are registered and before its first instance exists (class handlers, affects_render, metadata overrides). Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.