Google is committed to advancing racial equity for Black communities. See how.

Builder

class Builder : Builder<InlineSuggestionUi.Style!>
androidx.autofill.inline.v1.InlineSuggestionUi.Style.Builder

Builder for the Style.

Summary

Public methods
InlineSuggestionUi.Style

InlineSuggestionUi.Style.Builder
setChipStyle(@NonNull chipStyle: ViewStyle)

Sets the chip style.

InlineSuggestionUi.Style.Builder
setEndIconStyle(@NonNull endIconStyle: ImageViewStyle)

Sets the end icon style.

InlineSuggestionUi.Style.Builder
setLayoutDirection(layoutDirection: Int)

Sets the layout direction for the UI.

InlineSuggestionUi.Style.Builder

Sets the icon style for the case where there is a single icon and no text in the chip.

InlineSuggestionUi.Style.Builder
setSingleIconChipStyle(@NonNull chipStyle: ViewStyle)

Sets the chip style for the case where there is a single icon and no text.

InlineSuggestionUi.Style.Builder
setStartIconStyle(@NonNull startIconStyle: ImageViewStyle)

Sets the start icon style.

InlineSuggestionUi.Style.Builder
setSubtitleStyle(@NonNull subtitleStyle: TextViewStyle)

Sets the subtitle style.

InlineSuggestionUi.Style.Builder
setTitleStyle(@NonNull titleStyle: TextViewStyle)

Sets the title style.

Public methods

build

@NonNull fun build(): InlineSuggestionUi.Style

setChipStyle

@NonNull fun setChipStyle(@NonNull chipStyle: ViewStyle): InlineSuggestionUi.Style.Builder

Sets the chip style.

See setSingleIconChipStyle(ViewStyle) for more information about setting a special chip style for the case where the entire chip is a single icon.

setEndIconStyle

@NonNull fun setEndIconStyle(@NonNull endIconStyle: ImageViewStyle): InlineSuggestionUi.Style.Builder

Sets the end icon style.

setLayoutDirection

@NonNull fun setLayoutDirection(layoutDirection: Int): InlineSuggestionUi.Style.Builder

Sets the layout direction for the UI.

Note that the process that renders the UI needs to have android:supportsRtl="true" for this to take effect.

Parameters
layoutDirection Int: the layout direction to set. Should be one of: View#LAYOUT_DIRECTION_LTR, View#LAYOUT_DIRECTION_RTL.

setSingleIconChipIconStyle

@NonNull fun setSingleIconChipIconStyle(@NonNull iconStyle: ImageViewStyle): InlineSuggestionUi.Style.Builder

Sets the icon style for the case where there is a single icon and no text in the chip. If not provided, will fallback to use the icon style provided by setStartIconStyle(ImageViewStyle)

setSingleIconChipStyle

@NonNull fun setSingleIconChipStyle(@NonNull chipStyle: ViewStyle): InlineSuggestionUi.Style.Builder

Sets the chip style for the case where there is a single icon and no text. If not provided, will fallback to use the chip style provided by (ViewStyle).

setStartIconStyle

@NonNull fun setStartIconStyle(@NonNull startIconStyle: ImageViewStyle): InlineSuggestionUi.Style.Builder

Sets the start icon style.

See setSingleIconChipIconStyle(ImageViewStyle) for more information about setting a special icon style for the case where the entire chip is a single icon.

setSubtitleStyle

@NonNull fun setSubtitleStyle(@NonNull subtitleStyle: TextViewStyle): InlineSuggestionUi.Style.Builder

Sets the subtitle style.

setTitleStyle

@NonNull fun setTitleStyle(@NonNull titleStyle: TextViewStyle): InlineSuggestionUi.Style.Builder

Sets the title style.