TooltipDefaults
-
Cmn
@ExperimentalMaterial3Api
object TooltipDefaults
Tooltip defaults that contain default values for both PlainTooltip and RichTooltip
Summary
Public functions |
||
|---|---|---|
DefaultTooltipCaretShape |
The default caret shape used for tooltips and is |
Cmn
|
Shape |
caretShape(caretSize: DpSize)The caret shape used for tooltips. |
Cmn
|
PopupPositionProvider |
@ComposableThis function is deprecated. Deprecated in favor of rememberTooltipPositionProvider API. |
Cmn
|
PopupPositionProvider |
@ComposableThis function is deprecated. Deprecated in favor of rememberTooltipPositionProvider API. |
Cmn
|
PopupPositionProvider |
@ComposableThis function is deprecated. Deprecated in favor of rememberTooltipPositionProvider API that takes a preferred positioning. |
Cmn
|
PopupPositionProvider |
@Composable
|
Cmn
|
RichTooltipColors |
Method to create a |
Cmn
|
RichTooltipColors |
@ComposableMethod to create a |
Cmn
|
Public properties |
||
|---|---|---|
DpSize |
The default |
Cmn
|
Color |
The default |
Cmn
|
Shape |
The default |
Cmn
|
Color |
The default |
Cmn
|
Dp |
The default maximum width for plain tooltips. |
Cmn
|
Shape |
The default |
Cmn
|
Dp |
The default maximum width for rich tooltips. |
Cmn
|
Public functions
caretShape
fun caretShape(): DefaultTooltipCaretShape
The default caret shape used for tooltips and is TooltipDefaults.caretSize dimensions.
caretShape
fun caretShape(caretSize: DpSize = TooltipDefaults.caretSize): Shape
The caret shape used for tooltips.
rememberPlainTooltipPositionProvider
@Composable
funrememberPlainTooltipPositionProvider(
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor
): PopupPositionProvider
PopupPositionProvider that should be used with PlainTooltip. It correctly positions the tooltip in respect to the anchor content.
| Parameters | |
|---|---|
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor |
the spacing between the tooltip and the anchor content. |
rememberRichTooltipPositionProvider
@Composable
funrememberRichTooltipPositionProvider(
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor
): PopupPositionProvider
PopupPositionProvider that should be used with RichTooltip. It correctly positions the tooltip in respect to the anchor content.
| Parameters | |
|---|---|
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor |
the spacing between the tooltip and the anchor content. |
rememberTooltipPositionProvider
@Composable
funrememberTooltipPositionProvider(
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor
): PopupPositionProvider
PopupPositionProvider that should be used with either RichTooltip or PlainTooltip. It correctly positions the tooltip in respect to the anchor content.
| Parameters | |
|---|---|
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor |
the spacing between the tooltip and the anchor content. |
rememberTooltipPositionProvider
@Composable
fun rememberTooltipPositionProvider(
positioning: TooltipAnchorPosition,
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor
): PopupPositionProvider
PopupPositionProvider that should be used with either RichTooltip or PlainTooltip. It correctly positions the tooltip in respect to the anchor content.
| Parameters | |
|---|---|
positioning: TooltipAnchorPosition |
|
spacingBetweenTooltipAndAnchor: Dp = SpacingBetweenTooltipAndAnchor |
the spacing between the tooltip and the anchor content. |
richTooltipColors
@Composable
fun richTooltipColors(): RichTooltipColors
Method to create a RichTooltipColors for RichTooltip using RichTooltipTokens to obtain the default colors.
richTooltipColors
@Composable
fun richTooltipColors(
containerColor: Color = Color.Unspecified,
contentColor: Color = Color.Unspecified,
titleContentColor: Color = Color.Unspecified,
actionContentColor: Color = Color.Unspecified
): RichTooltipColors
Method to create a RichTooltipColors for RichTooltip using RichTooltipTokens to obtain the default colors.
Public properties
plainTooltipContainerColor
val plainTooltipContainerColor: Color
The default Color for a PlainTooltip's container.
plainTooltipContainerShape
val plainTooltipContainerShape: Shape
The default Shape for a PlainTooltip's container.
plainTooltipContentColor
val plainTooltipContentColor: Color
The default Color for the content within the PlainTooltip.
richTooltipContainerShape
val richTooltipContainerShape: Shape
The default Shape for a RichTooltip's container.