Banner
Object Hierarchy:
Adw.Banner
Adw.Banner
Adw.Banner
Gtk.Widget
Gtk.Widget
Gtk.Widget->Adw.Banner
GLib.InitiallyUnowned
GLib.InitiallyUnowned
GLib.InitiallyUnowned->Gtk.Widget
GLib.Object
GLib.Object
GLib.Object->GLib.InitiallyUnowned
Gtk.Accessible
Gtk.Accessible
Gtk.Accessible->Adw.Banner
Gtk.Accessible->Gtk.Widget
Gtk.Buildable
Gtk.Buildable
Gtk.Buildable->Adw.Banner
Gtk.Buildable->Gtk.Widget
Gtk.ConstraintTarget
Gtk.ConstraintTarget
Gtk.ConstraintTarget->Adw.Banner
Gtk.ConstraintTarget->Gtk.Widget
Gtk.Actionable
Gtk.Actionable
Gtk.Actionable->Adw.Banner
Description:
[ CCode ( type_id = "adw_banner_get_type ()" ) ] [ Version ( since = "1.3" ) ]public sealed class Banner : Widget , Accessible , Actionable , Buildable , ConstraintTarget
A bar with contextual information.
<picture> <source srcset="banner-dark.png" media="(prefers-color-scheme: dark)"> <img src="banner.png" alt="banner">
</picture>
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:AdwBanner:button-clicked
] signal.
CSS nodes
`AdwBanner` has a main CSS node with the name `banner`.
Content:
Properties:
public string button_label { get ; set ; }
The label to show on the button.
public bool revealed { get ; set ; }
Whether the banner is currently revealed.
public string title { get ; set ; }
The title for this banner.
public bool use_markup { get ; set ; }
Whether to use Pango markup for the banner title.
Creation methods:
Methods:
public unowned string ? get_button_label ()
Gets the button label for this .
public bool get_revealed ()
Gets if a banner is revealed
public unowned string get_title ()
Gets the title for this .
public bool get_use_markup ()
Gets whether to use Pango markup for the banner title.
public void set_button_label (string ? label)
Sets the button label for this .
public void set_revealed (bool revealed)
Sets whether a banner should be revealed
public void set_title (string title)
Sets the title for this banner.
public void set_use_markup (bool use_markup)
Sets whether to use Pango markup for the banner title.
Signals:
Inherited Members:
All known members inherited from class Gtk.Widget
All known members inherited from class GLib.Object
@get
@new
@ref
@set
add_toggle_ref
add_weak_pointer
bind_property
connect
constructed
disconnect
dispose
dup_data
dup_qdata
force_floating
freeze_notify
get_class
get_data
get_property
get_qdata
get_type
getv
interface_find_property
interface_install_property
interface_list_properties
is_floating
new_valist
new_with_properties
newv
notify
notify_property
ref_count
ref_sink
remove_toggle_ref
remove_weak_pointer
replace_data
replace_qdata
set_data
set_data_full
set_property
set_qdata
set_qdata_full
set_valist
setv
steal_data
steal_qdata
thaw_notify
unref
watch_closure
weak_ref
weak_unref
All known members inherited from interface Gtk.Accessible
accessible_role
announce
get_accessible_parent
get_accessible_role
get_at_context
get_bounds
get_first_accessible_child
get_next_accessible_sibling
get_platform_state
reset_property
reset_relation
reset_state
set_accessible_parent
update_next_accessible_sibling
update_property
update_property_value
update_relation
update_relation_value
update_state
update_state_value
All known members inherited from interface Gtk.Actionable
action_name
action_target
get_action_name
get_action_target_value
set_action_name
set_action_target
set_action_target_value
set_detailed_action_name
All known members inherited from interface Gtk.Buildable
add_child
custom_finished
custom_tag_end
custom_tag_start
get_buildable_id
get_id
get_internal_child
parser_finished
set_buildable_property
set_id