gtk.shortcuts_window
Module for [ShortcutsWindow] class
Types 3
A GtkShortcutsWindow shows brief information about the keyboard shortcuts and gestures of an application. The shortcuts can be grouped, and you can have multiple sections in this window, corresponding to the major modes of your application.
Additionally, the shortcuts can be filtered by the current view, to avoid showing information that is not relevant in the current application context.
The recommended way to construct a GtkShortcutsWindow is with GtkBuilder, by populating a #GtkShortcutsWindow with one or more #GtkShortcutsSection objects, which contain #GtkShortcutsGroups that in turn contain objects of class #GtkShortcutsShortcut.
A simple example:

This example has as single section. As you can see, the shortcut groups are arranged in columns, and spread across several pages if there are too many to find on a single page.
The .ui file for this example can be found here.
An example with multiple views:

This example shows a #GtkShortcutsWindow that has been configured to show only the shortcuts relevant to the "stopwatch" view.
The .ui file for this example can be found here.
An example with multiple sections:

This example shows a #GtkShortcutsWindow with two sections, "Editor Shortcuts" and "Terminal Shortcuts".
The .ui file for this example can be found here.
ShortcutsWindowGidBuilder builder() static nothrowGet builder for [gtk.shortcuts_window.ShortcutsWindow] Returns: New builder objectstring sectionName() @property nothrowGet `sectionName` property. Returns: The name of the section to show.void sectionName(string propval) @property nothrowSet `sectionName` property. Params: propval = The name of the section to show.string viewName() @property nothrowGet `viewName` property. Returns: The view name by which to filter the contents.void viewName(string propval) @property nothrowSet `viewName` property. Params: propval = The view name by which to filter the contents.gulong connectClose(T)(T callback, Flag!"After" after = No.After) if (isCallable!T
&& is(ReturnType!T == void)
&& (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] : gtk.shortcuts_window.ShortcutsWindow)))
&& Parameters!T.length < 2) nothrowConnect to `Close` signal.gulong connectSearch(T)(T callback, Flag!"After" after = No.After) if (isCallable!T
&& is(ReturnType!T == void)
&& (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] : gtk.shortcuts_window.ShortcutsWindow)))
&& Parameters!T.length < 2) nothrowConnect to `Search` signal.Fluent builder implementation template for gtk.shortcuts_window.ShortcutsWindow
T sectionName(string propval) nothrowSet `sectionName` property. Params: propval = The name of the section to show.T viewName(string propval) nothrowSet `viewName` property. Params: propval = The view name by which to filter the contents.Fluent builder for gtk.shortcuts_window.ShortcutsWindow