Package ch.bailu.gtk.adw
Class Application
java.lang.Object
ch.bailu.gtk.type.Type
ch.bailu.gtk.type.Pointer
ch.bailu.gtk.gobject.Object
ch.bailu.gtk.gio.Application
ch.bailu.gtk.gtk.Application
ch.bailu.gtk.adw.Application
- All Implemented Interfaces:
PointerInterface
A base class for Adwaita applications.
`AdwApplication` handles library initialization by calling [func@init] in the
default [signal@Gio.Application::startup] signal handler, in turn chaining up
as required by [class@Gtk.Application]. Therefore, any subclass of
`AdwApplication` should always chain up its `startup` handler before using
any Adwaita or GTK API.
## Automatic Resources
`AdwApplication` will automatically load stylesheets located in the
application's resource base path (see
[method@Gio.Application.set_resource_base_path], if they're present.
They can be used to add custom styles to the application, as follows:
- `style.css` contains styles that are always present.
- `style-dark.css` contains styles only used when
[property@StyleManager:dark] is `TRUE`.
- `style-hc.css` contains styles used when the system high contrast
preference is enabled.
- `style-hc-dark.css` contains styles used when the system high contrast
preference is enabled and [property@StyleManager:dark] is `TRUE`.
`AdwApplication` handles library initialization by calling [func@init] in the
default [signal@Gio.Application::startup] signal handler, in turn chaining up
as required by [class@Gtk.Application]. Therefore, any subclass of
`AdwApplication` should always chain up its `startup` handler before using
any Adwaita or GTK API.
## Automatic Resources
`AdwApplication` will automatically load stylesheets located in the
application's resource base path (see
[method@Gio.Application.set_resource_base_path], if they're present.
They can be used to add custom styles to the application, as follows:
- `style.css` contains styles that are always present.
- `style-dark.css` contains styles only used when
[property@StyleManager:dark] is `TRUE`.
- `style-hc.css` contains styles used when the system high contrast
preference is enabled.
- `style-hc-dark.css` contains styles used when the system high contrast
preference is enabled and [property@StyleManager:dark] is `TRUE`.
https://gnome.pages.gitlab.gnome.org/libadwaita/doc/main/class.Application.html
-
Nested Class Summary
Nested classes/interfaces inherited from class ch.bailu.gtk.gtk.Application
Application.OnQueryEnd, Application.OnWindowAdded, Application.OnWindowRemoved
Nested classes/interfaces inherited from class ch.bailu.gtk.gio.Application
Application.OnActivate, Application.OnCommandLine, Application.OnHandleLocalOptions, Application.OnNameLost, Application.OnOpen, Application.OnShutdown, Application.OnStartup
Nested classes/interfaces inherited from class ch.bailu.gtk.gobject.Object
Object.OnBindingTransformFunc, Object.OnDestroyNotify, Object.OnDuplicateFunc, Object.OnNotify, Object.OnToggleNotify, Object.OnWeakNotify
-
Field Summary
Fields inherited from class ch.bailu.gtk.gtk.Application
SIGNAL_ON_QUERY_END, SIGNAL_ON_WINDOW_ADDED, SIGNAL_ON_WINDOW_REMOVED
Fields inherited from class ch.bailu.gtk.gio.Application
SIGNAL_ON_ACTIVATE, SIGNAL_ON_COMMAND_LINE, SIGNAL_ON_HANDLE_LOCAL_OPTIONS, SIGNAL_ON_NAME_LOST, SIGNAL_ON_OPEN, SIGNAL_ON_SHUTDOWN, SIGNAL_ON_STARTUP
Fields inherited from class ch.bailu.gtk.gobject.Object
SIGNAL_ON_NOTIFY
-
Constructor Summary
ConstructorDescriptionApplication
(PointerContainer pointer) Application
(Str application_id, int flags) Creates a new `AdwApplication`.Application
(String application_id, int flags) Creates a new `AdwApplication`. -
Method Summary
Modifier and TypeMethodDescriptionImplements interfaceActionGroup
.Implements interfaceActionMap
.static ClassHandler
static int
static long
static TypeSystem.TypeSize
Gets the style manager for @self.static long
static TypeSystem.TypeSize
Methods inherited from class ch.bailu.gtk.gtk.Application
addWindow, getAccelsForAction, getAccelsForAction, getActionsForAccel, getActionsForAccel, getActiveWindow, getMenubar, getMenuById, getMenuById, getWindowById, getWindows, inhibit, inhibit, listActionDescriptions, onQueryEnd, onWindowAdded, onWindowRemoved, removeWindow, setAccelsForAction, setAccelsForAction, setMenubar, uninhibit
Methods inherited from class ch.bailu.gtk.gio.Application
activate, addOptionGroup, bindBusyProperty, bindBusyProperty, getApplicationId, getDbusConnection, getDbusObjectPath, getDefault, getFlags, getInactivityTimeout, getIsBusy, getIsRegistered, getIsRemote, getResourceBasePath, hold, idIsValid, markBusy, onActivate, onCommandLine, onHandleLocalOptions, onNameLost, onOpen, onShutdown, onStartup, quit, register, release, run, sendNotification, sendNotification, setApplicationId, setApplicationId, setDefault, setFlags, setInactivityTimeout, setOptionContextDescription, setOptionContextDescription, setOptionContextParameterString, setOptionContextParameterString, setOptionContextSummary, setOptionContextSummary, setResourceBasePath, setResourceBasePath, unbindBusyProperty, unbindBusyProperty, unmarkBusy, withdrawNotification, withdrawNotification
Methods inherited from class ch.bailu.gtk.gobject.Object
addToggleRef, bindProperty, bindProperty, bindPropertyFull, bindPropertyFull, bindPropertyWithClosures, bindPropertyWithClosures, compatControl, connect, connect, disconnect, disconnect, dupData, dupData, dupQdata, forceFloating, freezeNotify, get, get, getData, getData, getProperty, getProperty, getQdata, interfaceFindProperty, interfaceInstallProperty, isFloating, notify, notify, notifyByPspec, onNotify, ref, refSink, removeToggleRef, replaceData, replaceData, replaceQdata, runDispose, set, set, setData, setData, setDataFull, setDataFull, setProperty, setProperty, setQdata, setQdataFull, stealData, stealData, stealQdata, takeRef, thawNotify, unref, watchClosure, weakRef, weakUnref
Methods inherited from class ch.bailu.gtk.type.Pointer
asCPointer, cast, connectSignal, disconnectSignals, disconnectSignals, equals, hashCode, throwIfNull, throwNullPointerException, toString, unregisterCallbacks, unregisterCallbacks
Methods inherited from class ch.bailu.gtk.type.Type
asCPointer, asCPointer, asCPointerNotNull, asJnaPointer, asJnaPointer, asPointer, asPointer, cast, cast, throwIfNull
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface ch.bailu.gtk.type.PointerInterface
asCPointerNotNull, asJnaPointer, asPointer, isNotNull, isNull
-
Constructor Details
-
Application
-
Application
Creates a new `AdwApplication`.
If `application_id` is not `NULL`, then it must be valid. See
[func@Gio.Application.id_is_valid].
If no application ID is given then some features (most notably application
uniqueness) will be disabled.- Parameters:
application_id
- The application IDflags
- The application flags
-
Application
Creates a new `AdwApplication`.
If `application_id` is not `NULL`, then it must be valid. See
[func@Gio.Application.id_is_valid].
If no application ID is given then some features (most notably application
uniqueness) will be disabled.- Parameters:
application_id
- The application IDflags
- The application flags
-
-
Method Details
-
getClassHandler
-
getStyleManager
Gets the style manager for @self.
This is a convenience property allowing to access `AdwStyleManager` through
property bindings or expressions.- Returns:
- the style manager
-
asActionGroup
Implements interfaceActionGroup
. Call this to get access to interface functions.- Overrides:
asActionGroup
in classApplication
- Returns:
ActionGroup
-
asActionMap
Implements interfaceActionMap
. Call this to get access to interface functions.- Overrides:
asActionMap
in classApplication
- Returns:
ActionMap
-
getTypeID
public static long getTypeID() -
getParentTypeID
public static long getParentTypeID() -
getTypeSize
-
getParentTypeSize
-
getInstanceSize
public static int getInstanceSize()
-