About my projects, examples and tutorials
Gnome::Gtk4::ShortcutsSection

Gnome::Gtk4::ShortcutsSection

Description§

A Gnome::Gtk4::ShortcutsSection collects all the keyboard shortcuts and gestures for a major application mode.

If your application needs multiple sections, you should give each section a unique section-name and a title that can be shown in the section selector of the Gnome::Gtk4::ShortcutsWindow.

The max-height property can be used to influence how the groups in the section are distributed over pages and columns.

This widget is only meant to be used with Gnome::Gtk4::ShortcutsWindow.

The recommended way to construct a Gnome::Gtk4::ShortcutsSection is with Gnome::Gtk4::Builder, by using the `<child>` tag to populate a Gnome::Gtk4::ShortcutsSection with one or more Gnome::Gtk4::ShortcutsGroup instances, which in turn contain one or more Gnome::Gtk4::ShortcutsShortcut objects.

If you need to add a group programmatically, use .add-group().

Uml Diagram§

UNKNOWN image§

=for image :class<inline> :src<asset_files/images/plantuml/ShortcutsSection.png> :width<70\%>

Class initialization§

new§

:native-object§

Create an object using a native object from an object of the same type found elsewhere. See also Gnome::N::TopLevelSupportClass.

multi method new ( N-Object() :$native-object! )
Code

Methods§

add-group§

Adds a group to the shortcuts section.

This is the programmatic equivalent to using Gnome::Gtk4::Builder and a `<child>` tag to add the child.

Adding children with the Gnome::Gtk4::Box API is not appropriate, as Gnome::Gtk4::ShortcutsSection manages its children internally.

method add-group ( N-Object() $group )
Code

Signals§

change-current-page§

method handler (
  gint $object,
  Int :$_handle_id,
  N-GObject :$_native-object,
  Gnome::Gtk4::ShortcutsSection :$_widget,
  *%user-options
  --> gboolean
)
Code
  • $object; .
  • $_handle_id; The registered event handler id.
  • $_native-object; The native object provided by the Raku object which registered this event. This is a native Gnome::Gtk4::ShortcutsSection object.
  • %user-options; A list of named arguments provided by .register-signal() in class Object.

Return value;