appdimens-dynamic

//AppDimens SDP, HDP, WDP: Scalable Width and Height Dimensions/com.appdimens.dynamic.compose.diagonal/DimenDiagonal

DimenDiagonal

class DimenDiagonal(val initialBaseDp: ERROR CLASS: Symbol not found for Dp, val sortedCustomEntries: List<CustomDpEntry> = emptyList(), val ignoreMultiWindows: Boolean = false, val applyAspectRatio: Boolean = false, val customSensitivityK: Float? = null)

EN A Stable class that allows defining custom dimensions based on screen qualifiers (UiModeType, Width, Height, Smallest Width).

The Dp value is resolved at composition (Compose) and uses the base value or a custom value, applying dynamic scaling at the end.

PT Classe Stable que permite a definição de dimensões customizadas baseadas em qualificadores de tela (UiModeType, Largura, Altura, Smallest Width).

O valor Dp é resolvido na composição (Compose) e usa o valor base ou um valor customizado, aplicando o dimensionamento dinâmico no final.

private constructor(initialBaseDp: ERROR CLASS: Symbol not found for Dp, sortedCustomEntries: List<CustomDpEntry> = emptyList(), ignoreMultiWindows: Boolean = false, applyAspectRatio: Boolean = false, customSensitivityK: Float? = null)

private val applyAspectRatio: Boolean

private val customSensitivityK: Float?

val dghdp: ERROR CLASS: Symbol not found for Dp

EN The final Dp value resolved in Compose (Screen Height). PT O valor final Dp resolvido no Compose (Altura da Tela).

val dghdpPx: Float

EN The final Pixel (Float) value resolved in Compose (Screen Height). PT O valor final em Pixels (Float) resolvido no Compose (Altura da Tela).

val dgsdp: ERROR CLASS: Symbol not found for Dp

EN The final Dp value resolved in Compose (Smallest Width). PT O valor final Dp resolvido no Compose (Smallest Width).

val dgsdpPx: Float

EN The final Pixel (Float) value resolved in Compose (Smallest Width). PT O valor final em Pixels (Float) resolvido no Compose (Smallest Width).

val dgwdp: ERROR CLASS: Symbol not found for Dp

EN The final Dp value resolved in Compose (Screen Width). PT O valor final Dp resolvido no Compose (Largura da Tela).

val dgwdpPx: Float

EN The final Pixel (Float) value resolved in Compose (Screen Width). PT O valor final em Pixels (Float) resolvido no Compose (Largura da Tela).

private val ignoreMultiWindows: Boolean

private val initialBaseDp: ERROR CLASS: Symbol not found for Dp

private val sortedCustomEntries: List<CustomDpEntry>

fun aspectRatio(enable: Boolean = true, sensitivityK: Float? = null): DimenDiagonal

EN Allow applying aspect ratio based constraint scaling. PT Permite aplicar o redimensionamento baseado na proporção da tela.

fun ignoreMultiWindows(ignore: Boolean = true): DimenDiagonal

EN Allow ignoring the constraint scaling based on multi-window resizing properties. PT Permite ignorar o dimensionamento para os layouts de múltiplas janelas (divisão de tela).

private fun reorderEntries(newEntry: CustomDpEntry): List<CustomDpEntry>

EN Adds a new entry and re-sorts the list. Sorting is crucial: first by priority (ascending), and then by dpQualifierEntry.value (descending) so that larger qualifiers (e.g., sw600dp) are checked before smaller qualifiers (e.g., sw320dp).

private fun resolve(qualifier: DpQualifier): ERROR CLASS: Symbol not found for Dp

EN Resolves the final dimension. This is the Composable part that reads the current configuration and decides which Dp to use.

private fun resolvePx(qualifier: DpQualifier): Float

fun screen(orientation: Orientation = Orientation.DEFAULT, customValue: ERROR CLASS: Symbol not found for Dp, finalQualifierResolver: DpQualifier? = null, inverter: Inverter? = Inverter.DEFAULT): DimenDiagonal

EN Priority 4: Orientation. This is an overload that accepts an Int for customValue.

EN Priority 2: UiModeType qualifier (e.g., TELEVISION, WATCH).

EN Priority 2: UiModeType qualifier (e.g., TELEVISION, WATCH). This is an overload that accepts an Int for customValue.

EN Priority 3: Dp qualifier (sw, h, w) without UiModeType restriction.

EN Priority 3: Dp qualifier (sw, h, w) without UiModeType restriction. This is an overload that accepts an Int for customValue.

EN Priority 1: Most specific qualifier - Combines UiModeType AND Dp Qualifier (sw, h, w).

EN Priority 1: Most specific qualifier - Combines UiModeType AND Dp Qualifier (sw, h, w). This is an overload that accepts an Int for customValue.

Constructors

Name Summary
DimenDiagonal  

Properties

Name Summary
applyAspectRatio  
customSensitivityK  
dghdp  
dghdpPx  
dgsdp  
dgsdpPx  
dgwdp  
dgwdpPx  
ignoreMultiWindows  
initialBaseDp  
sortedCustomEntries  

Functions

Name Summary
aspectRatio  
ignoreMultiWindows  
reorderEntries  
resolve  
resolvePx  
screen