class CompositeUiScalingStrategy(uiScalingStrategies: UiScalingStrategy) : UiScalingStrategy

A composition of UI scaling strategies. When getUiScalingFactor is invoked, it will return the value of the first strategy in uiScalingStrategies that returns a non-null value.


Link copied to clipboard
fun CompositeUiScalingStrategy(vararg uiScalingStrategies: UiScalingStrategy)


Link copied to clipboard
open override fun getUiScalingFactor(context: Context): Float?

Returns an optional UI scaling factor for the given context. When a non-null value is returned, the value can be used to scale the UI accordingly. When null is returned, another strategy may be invoked, or the caller can choose to not scale the UI.