We just launched Compose Examples featuring over 150+ components! Check it out →

MaterialTheme

Android

Component in Wear Material 3 Compose

MaterialTheme defines the styling principles from the Wear Material3 design specification which extends the Material design specification.

Wear Material components from package/sub-packages in [androidx.wear.compose.material3] use values provided here when retrieving default values.

All values may be set by providing this component with the [colors][ColorScheme], [typography][Typography], and [shapes][Shapes] attributes. Use this to configure the overall theme of elements within this MaterialTheme.

Any values that are not set will inherit the current value from the theme, falling back to the defaults if there is no parent MaterialTheme. This allows using a MaterialTheme at the top of your application, and then separate MaterialTheme(s) for different screens / parts of your UI, overriding only the parts of the theme definition that need to change.

Last updated:

Installation

dependencies {
   implementation("androidx.wear.compose:compose-material3:1.0.0-alpha27")
}

Overloads

@Composable
fun MaterialTheme(
    colorScheme: ColorScheme = MaterialTheme.colorScheme,
    typography: Typography = MaterialTheme.typography,
    shapes: Shapes = MaterialTheme.shapes,
    motionScheme: MotionScheme = MaterialTheme.motionScheme,
    content: @Composable () -> Unit
)

Parameters

namedescription
colorSchemeA complete definition of the Wear Material Color theme for this hierarchy
typographyA set of text styles to be used as this hierarchy's typography system
shapesA set of shapes to be used by the components in this hierarchy
motionSchemea set of motion specs used to animate content for this hierarchy.
contentSlot for composable content displayed with this theme
by @alexstyl