TypeBuilders.StringLayoutConstraint


@RequiresSchemaVersion(major = 1, minor = 200)
public final class TypeBuilders.StringLayoutConstraint


A type for specifying layout constraints when using StringProp on a data bindable layout element.

Summary

Nested types

Builder for StringLayoutConstraint.

Public methods

int

Gets angular alignment of the actual content within the space reserved by value.

@NonNull String

Gets the text string to use as the pattern for the largest text that can be laid out.

Public methods

getAlignment

Added in 1.0.0
public int getAlignment()

Gets angular alignment of the actual content within the space reserved by value.

getPatternForLayout

Added in 1.0.0
public @NonNull String getPatternForLayout()

Gets the text string to use as the pattern for the largest text that can be laid out. Used to ensure that the layout is of a known size during the layout pass.