item

fun item(colors: PreferenceItemColors = PreferenceItemDefaults.colors(), innerPadding: PaddingValues = LocalPreferenceSettings.current.style.defaultItemStyle.innerPadding, outerPadding: PaddingValues = LocalPreferenceSettings.current.style.defaultItemStyle.outerPadding, shape: Shape = LocalPreferenceSettings.current.style.defaultItemStyle.shape, tonalElevation: Dp = 0.dp, shadowElevation: Dp = 0.dp, titleTextStyle: TextStyle = MaterialTheme.typography.labelLarge, subtitleTextStyle: TextStyle = MaterialTheme.typography.bodyMedium): PreferenceItemStyle

this function returns a PreferenceItemStyle defining the style of a preference item

check out the overload to find a background/foreground based function

Return

the PreferenceItemStyle holding the provided setup

Parameters

colors

the PreferenceItemColors of this item

innerPadding

the outer PaddingValues of this item

outerPadding

the inner PaddingValues of this item

shape

the Shape of this item

tonalElevation

the tonal elevation of this item

shadowElevation

the shadow elevation of this item

titleTextStyle

the shadow elevation of this item

subtitleTextStyle

the shadow elevation of this item


fun item(colorBackground: Color = MaterialTheme.colorScheme.surface, colorForeground: Color = MaterialTheme.colorScheme.onSurface, alphaVariant: Float = PreferenceItemDefaults.DEFAULT_ALPHA_VARIANT, shape: Shape = LocalPreferenceSettings.current.style.defaultItemStyle.shape, innerPadding: PaddingValues = LocalPreferenceSettings.current.style.defaultItemStyle.innerPadding, outerPadding: PaddingValues = LocalPreferenceSettings.current.style.defaultItemStyle.outerPadding, tonalElevation: Dp = 0.dp, shadowElevation: Dp = 0.dp, titleTextStyle: TextStyle = MaterialTheme.typography.labelLarge, subtitleTextStyle: TextStyle = MaterialTheme.typography.bodyMedium): PreferenceItemStyle

this function returns a PreferenceItemStyle defining the style of a preference item

check out the overload to find a background/foreground based function

Return

the PreferenceItemStyle holding the provided setup

Parameters

colorBackground

the background Color of this item

colorForeground

the foreground Color of this item

alphaVariant

the alpha value used to calculate the variant color from the provided colors

shape

the Shape of this item

tonalElevation

the tonal elevation of this item

shadowElevation

the shadow elevation of this item

titleTextStyle

the shadow elevation of this item

subtitleTextStyle

the shadow elevation of this item