WearWidgetDocument

class WearWidgetDocument : WearWidgetData


Defines the content of a widget using Remote Compose.

The provided composable content will be captured into a Remote Compose document for display within a widget.

Summary

Public constructors

WearWidgetDocument(
    background: WearWidgetBrush,
    content: @RemoteComposable @Composable () -> Unit
)

Public constructors

WearWidgetDocument

Added in 1.0.0-alpha05
WearWidgetDocument(
    background: WearWidgetBrush,
    content: @RemoteComposable @Composable () -> Unit
)
Parameters
background: WearWidgetBrush

The WearWidgetBrush for the widget's background. The system draws this behind the content, applying host-defined clipping and padding.

content: @RemoteComposable @Composable () -> Unit

The RemoteComposable content of the widget. This content is rendered in a padded area on top of the background. See WearWidgetParams.horizontalPaddingDp and WearWidgetParams.verticalPaddingDp.