class Dimension


Represents a dimension (width or height) of a constrained widget

Summary

Nested types

Public functions

Unit
apply(state: State!, constraintWidget: ConstraintWidget!, orientation: Int)

Apply the dimension to the given constraint widget

java-static Dimension!
createFixed(value: Any!)
java-static Dimension!
createFixed(value: Int)
java-static Dimension!
java-static Dimension!
createPercent(key: Any!, value: Float)
java-static Dimension!
java-static Dimension!
java-static Dimension!
createSuggested(startValue: Any!)
java-static Dimension!
java-static Dimension!
Boolean

Returns true if the dimension is a fixed dimension of the same given value

Dimension!
fixed(value: Any!)
Dimension!
fixed(value: Int)
Dimension!
max(value: Any!)
Dimension!
max(value: Int)
Dimension!
min(value: Any!)
Dimension!
min(value: Int)
Dimension!
percent(key: Any!, value: Float)
Dimension!
ratio(ratio: String!)
Dimension!
suggested(value: Any!)
Dimension!
suggested(value: Int)

Constants

FIXED_DIMENSION

Added in 1.1.0
const val FIXED_DIMENSIONAny!

PARENT_DIMENSION

Added in 1.1.0
const val PARENT_DIMENSIONAny!

PERCENT_DIMENSION

Added in 1.1.0
const val PERCENT_DIMENSIONAny!

RATIO_DIMENSION

Added in 1.1.0
const val RATIO_DIMENSIONAny!

SPREAD_DIMENSION

Added in 1.1.0
const val SPREAD_DIMENSIONAny!

WRAP_DIMENSION

Added in 1.1.0
const val WRAP_DIMENSIONAny!

Public functions

apply

Added in 1.1.0
fun apply(state: State!, constraintWidget: ConstraintWidget!, orientation: Int): Unit

Apply the dimension to the given constraint widget

createFixed

Added in 1.1.0
java-static fun createFixed(value: Any!): Dimension!

createFixed

Added in 1.1.0
java-static fun createFixed(value: Int): Dimension!

createParent

Added in 1.1.0
java-static fun createParent(): Dimension!

createPercent

Added in 1.1.0
java-static fun createPercent(key: Any!, value: Float): Dimension!

createRatio

Added in 1.1.0
java-static fun createRatio(ratio: String!): Dimension!

createSpread

Added in 1.1.0
java-static fun createSpread(): Dimension!

createSuggested

Added in 1.1.0
java-static fun createSuggested(startValue: Any!): Dimension!

createSuggested

Added in 1.1.0
java-static fun createSuggested(value: Int): Dimension!

createWrap

Added in 1.1.0
java-static fun createWrap(): Dimension!

equalsFixedValue

Added in 1.1.0
fun equalsFixedValue(value: Int): Boolean

Returns true if the dimension is a fixed dimension of the same given value

fixed

Added in 1.1.0
fun fixed(value: Any!): Dimension!

fixed

Added in 1.1.0
fun fixed(value: Int): Dimension!

max

Added in 1.1.0
fun max(value: Any!): Dimension!

max

Added in 1.1.0
fun max(value: Int): Dimension!

min

Added in 1.1.0
fun min(value: Any!): Dimension!

min

Added in 1.1.0
fun min(value: Int): Dimension!

percent

Added in 1.1.0
fun percent(key: Any!, value: Float): Dimension!

ratio

Added in 1.1.0
fun ratio(ratio: String!): Dimension!

suggested

Added in 1.1.0
fun suggested(value: Any!): Dimension!

suggested

Added in 1.1.0
fun suggested(value: Int): Dimension!