gtk.native_dialog

Module for [NativeDialog] class

Types 3

Native dialogs are platform dialogs that don't use gtk.dialog.Dialog.

They are used in order to integrate better with a platform, by looking the same as other native applications and supporting platform specific features.

The gtk.dialog.Dialog functions cannot be used on such objects, but we need a similar API in order to drive them. The gtk.native_dialog.NativeDialog object is an API that allows you to do this. It allows you to set various common properties on the dialog, as well as show and hide it and get a gtk.native_dialog.NativeDialog.response signal when the user finished with the dialog.

Note that unlike gtk.dialog.Dialog, gtk.native_dialog.NativeDialog objects are not toplevel widgets, and GTK does not keep them alive. It is your responsibility to keep a reference until you are done with the object.

Methods
GType _getGType() static nothrow
GType _gType() @property nothrow
NativeDialog self() nothrowReturns `this`, for use in `with` statements.
NativeDialogGidBuilder builder() static nothrowGet builder for [gtk.native_dialog.NativeDialog] Returns: New builder object
bool modal() @property nothrowGet `modal` property. Returns: Whether the window should be modal with respect to its transient parent.
void modal(bool propval) @property nothrowSet `modal` property. Params: propval = Whether the window should be modal with respect to its transient parent.
string title() @property nothrowGet `title` property. Returns: The title of the dialog window
void title(string propval) @property nothrowSet `title` property. Params: propval = The title of the dialog window
gtk.window.Window transientFor() @property nothrowGet `transientFor` property. Returns: The transient parent of the dialog, or null for none.
void transientFor(gtk.window.Window propval) @property nothrowSet `transientFor` property. Params: propval = The transient parent of the dialog, or null for none.
bool visible() @property nothrowGet `visible` property. Returns: Whether the window is currently visible.
void visible(bool propval) @property nothrowSet `visible` property. Params: propval = Whether the window is currently visible.
void destroy() nothrowDestroys a dialog.
bool getModal() nothrowReturns whether the dialog is modal. Returns: true if the dialog is set to be modal
string getTitle() nothrowGets the title of the [gtk.native_dialog.NativeDialog]. Returns: the title of the dialog, or null if none has been set explicitly. The returned string is owned by the widget and must not be modifie...
gtk.window.Window getTransientFor() nothrowFetches the transient parent for this window. Returns: the transient parent for this window, or null if no transient parent has been set.
bool getVisible() nothrowDetermines whether the dialog is visible. Returns: true if the dialog is visible
void hide() nothrowHides the dialog if it is visible, aborting any interaction.
void setModal(bool modal) nothrowSets a dialog modal or non-modal.
void setTitle(string title) nothrowSets the title of the `GtkNativeDialog.`
void setTransientFor(gtk.window.Window parent = null) nothrowDialog windows should be set transient for the main application window they were spawned from.
void show() nothrowShows the dialog on the display.
gulong connectResponse(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] == int))) && (Parameters!T.length < 2 || (ParameterStorageClassTuple!T[1] == ParameterStorageClass.none && is(Parameters!T[1] : gtk.native_dialog.NativeDialog))) && Parameters!T.length < 3) nothrowConnect to `Response` signal.
Constructors
this(void * ptr, Flag!"Take" take)

Fluent builder implementation template for gtk.native_dialog.NativeDialog

Methods
T modal(bool propval) nothrowSet `modal` property. Params: propval = Whether the window should be modal with respect to its transient parent. Returns: Builder instance for fluent chaining
T title(string propval) nothrowSet `title` property. Params: propval = The title of the dialog window Returns: Builder instance for fluent chaining
T transientFor(gtk.window.Window propval) nothrowSet `transientFor` property. Params: propval = The transient parent of the dialog, or null for none. Returns: Builder instance for fluent chaining
T visible(bool propval) nothrowSet `visible` property. Params: propval = Whether the window is currently visible. Returns: Builder instance for fluent chaining
Methods
NativeDialog build() nothrowCreate object from builder. Returns: New object