Banner

class Banner(pointer: <Error class: unknown class><<Error class: unknown class>>)

A bar with contextual information.

banner

Banners are hidden by default, use property@Banner:revealed to show them.

Banners have a title, set with property@Banner:title. Titles can be marked up with Pango markup, use property@Banner:use-markup to enable it.

The title will be shown centered or left-aligned depending on available space.

Banners can optionally have a button with text on it, set through property@Banner:button-label. The button can be used with a GAction, or with the signal@Banner::button-clicked signal.

CSS nodes

AdwBanner has a main CSS node with the name banner.

Since

1.3

Constructors

Link copied to clipboard
constructor(title: String)

Creates a new AdwBanner.

constructor(pointer: <Error class: unknown class><<Error class: unknown class>>)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val adwBannerPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard

The label to show on the button.

Link copied to clipboard
open val gtkAccessiblePointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open val gtkActionablePointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open val gtkBuildablePointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
open val gtkConstraintTargetPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard

Whether the banner is currently revealed.

Link copied to clipboard

The title for this banner.

Link copied to clipboard

Whether to use Pango markup for the banner title.

Functions

Link copied to clipboard
fun connectButtonClicked(connectFlags: <Error class: unknown class> = ConnectFlags(0u), handler: () -> Unit): <Error class: unknown class>

This signal is emitted after the action button has been clicked.

Link copied to clipboard

Gets the button label for @self.

Link copied to clipboard

Gets if a banner is revealed

Link copied to clipboard

Gets the title for @self.

Link copied to clipboard

Gets whether to use Pango markup for the banner title.

Link copied to clipboard
fun setButtonLabel(label: String? = null)

Sets the button label for @self.

Link copied to clipboard
fun setRevealed(revealed: Boolean)

Sets whether a banner should be revealed

Link copied to clipboard
fun setTitle(title: String)

Sets the title for this banner.

Link copied to clipboard
fun setUseMarkup(useMarkup: Boolean)

Sets whether to use Pango markup for the banner title.