ModifiersBuilders.Transformation.Builder


public final class ModifiersBuilders.Transformation.Builder


Builder for Transformation

Summary

Public constructors

Creates an instance of Builder.

Public methods

@NonNull ModifiersBuilders.Transformation

Builds an instance from accumulated values.

@NonNull ModifiersBuilders.Transformation.Builder

Sets the horizontal location of the point around which the element is rotated and scaled.

@NonNull ModifiersBuilders.Transformation.Builder

Sets the vertical location of the point around which the element is rotated and scaled.

@NonNull ModifiersBuilders.Transformation.Builder

Sets the clockwise degrees that the element is rotated around the pivot point.

@NonNull ModifiersBuilders.Transformation.Builder
@RequiresSchemaVersion(major = 1, minor = 400)
setScaleX(@NonNull TypeBuilders.FloatProp scaleX)

Sets the scale of this element in the x direction around the pivot point, as a proportion of the element's unscaled width.

@NonNull ModifiersBuilders.Transformation.Builder
@RequiresSchemaVersion(major = 1, minor = 400)
setScaleY(@NonNull TypeBuilders.FloatProp scaleY)

Sets the scale of this element in the y direction around the pivot point, as a proportion of the element's unscaled height.

@NonNull ModifiersBuilders.Transformation.Builder
@RequiresSchemaVersion(major = 1, minor = 400)
setTranslationX(@NonNull DimensionBuilders.DpProp translationX)

Sets the horizontal offset of this element relative to the location where the element's layout placed it.

@NonNull ModifiersBuilders.Transformation.Builder
@RequiresSchemaVersion(major = 1, minor = 400)
setTranslationY(@NonNull DimensionBuilders.DpProp translationY)

Sets the vertical offset of this element in addition to the location where the element's layout placed it.

Public constructors

Builder

Added in 1.2.0
public Builder()

Creates an instance of Builder.

Public methods

build

Added in 1.2.0
public @NonNull ModifiersBuilders.Transformation build()

Builds an instance from accumulated values.

setPivotX

Added in 1.2.0
@RequiresSchemaVersion(major = 1, minor = 400)
public @NonNull ModifiersBuilders.Transformation.Builder setPivotX(@NonNull DimensionBuilders.PivotDimension pivotX)

Sets the horizontal location of the point around which the element is rotated and scaled. With type DpProp, it is the offset from the element center; otherwise with type BoundingBoxRatio, it is the location proportional to the bounding box width. Dynamic value is supported. If not set, defaults to the element center.

setPivotY

Added in 1.2.0
@RequiresSchemaVersion(major = 1, minor = 400)
public @NonNull ModifiersBuilders.Transformation.Builder setPivotY(@NonNull DimensionBuilders.PivotDimension pivotY)

Sets the vertical location of the point around which the element is rotated and scaled. With type DpProp, it is the offset from the element center; otherwise with type BoundingBoxRatio, it is the location proportional to the bounding box height. Dynamic value is supported. If not set, defaults to the element center.

setRotation

Added in 1.2.0
@RequiresSchemaVersion(major = 1, minor = 400)
public @NonNull ModifiersBuilders.Transformation.Builder setRotation(@NonNull DimensionBuilders.DegreesProp rotation)

Sets the clockwise degrees that the element is rotated around the pivot point. If not set, defaults to zero.

setScaleX

Added in 1.2.0
@RequiresSchemaVersion(major = 1, minor = 400)
public @NonNull ModifiersBuilders.Transformation.Builder setScaleX(@NonNull TypeBuilders.FloatProp scaleX)

Sets the scale of this element in the x direction around the pivot point, as a proportion of the element's unscaled width. If not set, defaults to one.

setScaleY

Added in 1.2.0
@RequiresSchemaVersion(major = 1, minor = 400)
public @NonNull ModifiersBuilders.Transformation.Builder setScaleY(@NonNull TypeBuilders.FloatProp scaleY)

Sets the scale of this element in the y direction around the pivot point, as a proportion of the element's unscaled height. If not set, defaults to one.

setTranslationX

Added in 1.2.0
@RequiresSchemaVersion(major = 1, minor = 400)
public @NonNull ModifiersBuilders.Transformation.Builder setTranslationX(@NonNull DimensionBuilders.DpProp translationX)

Sets the horizontal offset of this element relative to the location where the element's layout placed it. If not set, defaults to zero.

setTranslationY

Added in 1.2.0
@RequiresSchemaVersion(major = 1, minor = 400)
public @NonNull ModifiersBuilders.Transformation.Builder setTranslationY(@NonNull DimensionBuilders.DpProp translationY)

Sets the vertical offset of this element in addition to the location where the element's layout placed it. If not set, defaults to zero.