Package ch.bailu.gtk.adw
Klasse Flap
- Alle implementierten Schnittstellen:
PointerInterface
An adaptive container acting like a box or an overlay.
<picture>
<source srcset="flap-wide-dark.png" media="(prefers-color-scheme: dark)">
<img src="flap-wide.png" alt="flap-wide">
</picture>
<picture>
<source srcset="flap-narrow-dark.png" media="(prefers-color-scheme: dark)">
<img src="flap-narrow.png" alt="flap-narrow">
</picture>
The `AdwFlap` widget can display its children like a [class@Gtk.Box] does or
like a [class@Gtk.Overlay] does, according to the
[property@Flap:fold-policy] value.
`AdwFlap` has at most three children: [property@Flap:content],
[property@Flap:flap] and [property@Flap:separator]. Content is the primary
child, flap is displayed next to it when unfolded, or overlays it when
folded. Flap can be shown or hidden by changing the
[property@Flap:reveal-flap] value, as well as via swipe gestures if
[property@Flap:swipe-to-open] and/or [property@Flap:swipe-to-close] are set
to `TRUE`.
Optionally, a separator can be provided, which would be displayed between
the content and the flap when there's no shadow to separate them, depending
on the transition type.
[property@Flap:flap] is transparent by default; add the
[`.background`](style-classes.html#background) style class to it if this is
unwanted.
If [property@Flap:modal] is set to `TRUE`, content becomes completely
inaccessible when the flap is revealed while folded.
The position of the flap and separator children relative to the content is
determined by orientation, as well as the [property@Flap:flap-position]
value.
Folding the flap will automatically hide the flap widget, and unfolding it
will automatically reveal it. If this behavior is not desired, the
[property@Flap:locked] property can be used to override it.
Common use cases include sidebars, header bars that need to be able to
overlap the window content (for example, in fullscreen mode) and bottom
sheets.
## AdwFlap as GtkBuildable
The `AdwFlap` implementation of the [iface@Gtk.Buildable] interface supports
setting the flap child by specifying “flap” as the “type” attribute of a
`<child>` element, and separator by specifying “separator”. Specifying
“content” child type or omitting it results in setting the content child.
## CSS nodes
`AdwFlap` has a single CSS node with name `flap`. The node will get the style
classes `.folded` when it is folded, and `.unfolded` when it's not.
<picture>
<source srcset="flap-wide-dark.png" media="(prefers-color-scheme: dark)">
<img src="flap-wide.png" alt="flap-wide">
</picture>
<picture>
<source srcset="flap-narrow-dark.png" media="(prefers-color-scheme: dark)">
<img src="flap-narrow.png" alt="flap-narrow">
</picture>
The `AdwFlap` widget can display its children like a [class@Gtk.Box] does or
like a [class@Gtk.Overlay] does, according to the
[property@Flap:fold-policy] value.
`AdwFlap` has at most three children: [property@Flap:content],
[property@Flap:flap] and [property@Flap:separator]. Content is the primary
child, flap is displayed next to it when unfolded, or overlays it when
folded. Flap can be shown or hidden by changing the
[property@Flap:reveal-flap] value, as well as via swipe gestures if
[property@Flap:swipe-to-open] and/or [property@Flap:swipe-to-close] are set
to `TRUE`.
Optionally, a separator can be provided, which would be displayed between
the content and the flap when there's no shadow to separate them, depending
on the transition type.
[property@Flap:flap] is transparent by default; add the
[`.background`](style-classes.html#background) style class to it if this is
unwanted.
If [property@Flap:modal] is set to `TRUE`, content becomes completely
inaccessible when the flap is revealed while folded.
The position of the flap and separator children relative to the content is
determined by orientation, as well as the [property@Flap:flap-position]
value.
Folding the flap will automatically hide the flap widget, and unfolding it
will automatically reveal it. If this behavior is not desired, the
[property@Flap:locked] property can be used to override it.
Common use cases include sidebars, header bars that need to be able to
overlap the window content (for example, in fullscreen mode) and bottom
sheets.
## AdwFlap as GtkBuildable
The `AdwFlap` implementation of the [iface@Gtk.Buildable] interface supports
setting the flap child by specifying “flap” as the “type” attribute of a
`<child>` element, and separator by specifying “separator”. Specifying
“content” child type or omitting it results in setting the content child.
## CSS nodes
`AdwFlap` has a single CSS node with name `flap`. The node will get the style
classes `.folded` when it is folded, and `.unfolded` when it's not.
https://gnome.pages.gitlab.gnome.org/libadwaita/doc/main/class.Flap.html
-
Verschachtelte Klassen - Übersicht
Von Klasse geerbte verschachtelte Klassen/Schnittstellen ch.bailu.gtk.gtk.Widget
Widget.OnDestroy, Widget.OnDestroyNotify, Widget.OnDirectionChanged, Widget.OnHide, Widget.OnKeynavFailed, Widget.OnMap, Widget.OnMnemonicActivate, Widget.OnMoveFocus, Widget.OnQueryTooltip, Widget.OnRealize, Widget.OnShow, Widget.OnStateFlagsChanged, Widget.OnTickCallback, Widget.OnUnmap, Widget.OnUnrealize
Von Klasse geerbte verschachtelte Klassen/Schnittstellen ch.bailu.gtk.gobject.Object
Object.OnBindingTransformFunc, Object.OnDuplicateFunc, Object.OnNotify, Object.OnToggleNotify, Object.OnWeakNotify
-
Feldübersicht
Von Klasse geerbte Felder ch.bailu.gtk.gtk.Widget
SIGNAL_ON_DESTROY, SIGNAL_ON_DIRECTION_CHANGED, SIGNAL_ON_HIDE, SIGNAL_ON_KEYNAV_FAILED, SIGNAL_ON_MAP, SIGNAL_ON_MNEMONIC_ACTIVATE, SIGNAL_ON_MOVE_FOCUS, SIGNAL_ON_QUERY_TOOLTIP, SIGNAL_ON_REALIZE, SIGNAL_ON_SHOW, SIGNAL_ON_STATE_FLAGS_CHANGED, SIGNAL_ON_UNMAP, SIGNAL_ON_UNREALIZE
Von Klasse geerbte Felder ch.bailu.gtk.gobject.Object
SIGNAL_ON_NOTIFY
-
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungImplements interfaceAccessible
.Implements interfaceBuildable
.Implements interfaceConstraintTarget
.Implements interfaceOrientable
.Implements interfaceSwipeable
.static ClassHandler
Veraltet.getFlap()
Veraltet.int
Veraltet.int
Veraltet.boolean
Veraltet.int
Veraltet.int
Veraltet.static int
boolean
Veraltet.boolean
getModal()
Veraltet.static long
static TypeSystem.TypeSize
boolean
Veraltet.Veraltet.double
Veraltet.Veraltet.boolean
Veraltet.boolean
Veraltet.int
Veraltet.static long
static TypeSystem.TypeSize
void
setContent
(Widget content) Veraltet.void
Veraltet.void
setFlapPosition
(int position) Veraltet.void
setFoldDuration
(int duration) Veraltet.void
setFoldPolicy
(int policy) Veraltet.void
setFoldThresholdPolicy
(int policy) Veraltet.void
setLocked
(boolean locked) Veraltet.void
setModal
(boolean modal) Veraltet.void
setRevealFlap
(boolean reveal_flap) Veraltet.void
setRevealParams
(SpringParams params) Veraltet.void
setSeparator
(Widget separator) Veraltet.void
setSwipeToClose
(boolean swipe_to_close) Veraltet.void
setSwipeToOpen
(boolean swipe_to_open) Veraltet.void
setTransitionType
(int transition_type) Veraltet.Von Klasse geerbte Methoden ch.bailu.gtk.gtk.Widget
actionSetEnabled, actionSetEnabled, activate, activateAction, activateAction, activateActionVariant, activateActionVariant, activateDefault, addController, addCssClass, addCssClass, addMnemonicLabel, addTickCallback, allocate, childFocus, computeBounds, computeExpand, computePoint, computeTransform, contains, createPangoContext, createPangoLayout, createPangoLayout, disposeTemplate, dragCheckThreshold, errorBell, getAllocatedBaseline, getAllocatedHeight, getAllocatedWidth, getAllocation, getAncestor, getBaseline, getCanFocus, getCanTarget, getChildVisible, getClipboard, getColor, getCssClasses, getCssName, getCursor, getDefaultDirection, getDirection, getDisplay, getFirstChild, getFocusable, getFocusChild, getFocusOnClick, getFontMap, getFontOptions, getFrameClock, getHalign, getHasTooltip, getHeight, getHexpand, getHexpandSet, getLastChild, getLayoutManager, getLimitEvents, getMapped, getMarginBottom, getMarginEnd, getMarginStart, getMarginTop, getName, getNative, getNextSibling, getOpacity, getOverflow, getPangoContext, getParent, getPreferredSize, getPrevSibling, getPrimaryClipboard, getRealized, getReceivesDefault, getRequestMode, getRoot, getScaleFactor, getSensitive, getSettings, getSize, getSizeRequest, getStateFlags, getStyleContext, getTemplateChild, getTemplateChild, getTooltipMarkup, getTooltipText, getValign, getVexpand, getVexpandSet, getVisible, getWidth, grabFocus, hasCssClass, hasCssClass, hasDefault, hasFocus, hasVisibleFocus, hide, inDestruction, initTemplate, insertActionGroup, insertActionGroup, insertAfter, insertBefore, isAncestor, isDrawable, isFocus, isSensitive, isVisible, keynavFailed, listMnemonicLabels, map, measure, mnemonicActivate, observeChildren, observeControllers, onDestroy, onDirectionChanged, onHide, onKeynavFailed, onMap, onMnemonicActivate, onMoveFocus, onQueryTooltip, onRealize, onShow, onStateFlagsChanged, onUnmap, onUnrealize, pick, queueAllocate, queueDraw, queueResize, realize, removeController, removeCssClass, removeCssClass, removeMnemonicLabel, removeTickCallback, setCanFocus, setCanTarget, setChildVisible, setCssClasses, setCursor, setCursorFromName, setCursorFromName, setDefaultDirection, setDirection, setFocusable, setFocusChild, setFocusOnClick, setFontMap, setFontOptions, setHalign, setHasTooltip, setHexpand, setHexpandSet, setLayoutManager, setLimitEvents, setMarginBottom, setMarginEnd, setMarginStart, setMarginTop, setName, setName, setOpacity, setOverflow, setParent, setReceivesDefault, setSensitive, setSizeRequest, setStateFlags, setTooltipMarkup, setTooltipMarkup, setTooltipText, setTooltipText, setValign, setVexpand, setVexpandSet, setVisible, shouldLayout, show, sizeAllocate, snapshotChild, triggerTooltipQuery, unmap, unparent, unrealize, unsetStateFlags
Von Klasse geerbte Methoden ch.bailu.gtk.type.PropertyHolder
getBooleanProperty, getIntProperty, getObjectProperty, getStringProperty, getStrProperty, setBooleanProperty, setIntProperty, setObjectProperty, setStringProperty, setStrProperty
Von Klasse geerbte Methoden 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
Von Klasse geerbte Methoden ch.bailu.gtk.type.Pointer
asCPointer, cast, connectSignal, disconnectSignals, disconnectSignals, equals, hashCode, throwIfNull, throwNullPointerException, toString, unregisterCallbacks, unregisterCallbacks
Von Klasse geerbte Methoden ch.bailu.gtk.type.Type
asCPointer, asCPointer, asCPointerNotNull, asJnaPointer, asJnaPointer, asPointer, asPointer, cast, cast, throwIfNull
Von Klasse geerbte Methoden java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Von Schnittstelle geerbte Methoden ch.bailu.gtk.type.PointerInterface
asCPointerNotNull, asJnaPointer, asPointer, isNotNull, isNull
-
Konstruktordetails
-
Flap
-
Flap
Veraltet.Creates a new `AdwFlap`.
-
-
Methodendetails
-
getClassHandler
-
getContent
Veraltet.Gets the content widget for @self.- Gibt zurück:
- the content widget for @self
-
getFlap
Veraltet.Gets the flap widget for @self.- Gibt zurück:
- the flap widget for @self
-
getFlapPosition
Veraltet.Gets the flap position for @self.- Gibt zurück:
- the flap position for @self
-
getFoldDuration
Veraltet.Gets the fold transition animation duration for @self, in milliseconds.- Gibt zurück:
- the fold transition duration
-
getFoldPolicy
Veraltet.Gets the fold policy for @self.- Gibt zurück:
- the fold policy for @self
-
getFoldThresholdPolicy
Veraltet.Gets the fold threshold policy for @self.- Gibt zurück:
- the fold threshold policy
-
getFolded
Veraltet.Gets whether @self is currently folded.
See [property@Flap:fold-policy].- Gibt zurück:
- `TRUE` if @self is currently folded
-
getLocked
Veraltet.Gets whether @self is locked.- Gibt zurück:
- `TRUE` if @self is locked
-
getModal
Veraltet.Gets whether @self is modal.- Gibt zurück:
- `TRUE` if @self is modal
-
getRevealFlap
Veraltet.Gets whether the flap widget is revealed for @self.- Gibt zurück:
- `TRUE` if the flap widget is revealed
-
getRevealParams
Veraltet.Gets the reveal animation spring parameters for @self.- Gibt zurück:
- the reveal animation parameters
-
getRevealProgress
Veraltet.Gets the current reveal progress for @self.
0 means fully hidden, 1 means fully revealed.
See [property@Flap:reveal-flap].- Gibt zurück:
- the current reveal progress for @self
-
getSeparator
Veraltet.Gets the separator widget for @self.- Gibt zurück:
- the separator widget for @self
-
getSwipeToClose
Veraltet.Gets whether @self can be closed with a swipe gesture.- Gibt zurück:
- `TRUE` if @self can be closed with a swipe gesture
-
getSwipeToOpen
Veraltet.Gets whether @self can be opened with a swipe gesture.- Gibt zurück:
- `TRUE` if @self can be opened with a swipe gesture
-
getTransitionType
Veraltet.Gets the type of animation used for reveal and fold transitions in @self.- Gibt zurück:
- the current transition type of @self
-
setContent
Veraltet.Sets the content widget for @self.
It's always displayed when unfolded, and partially visible when folded.- Parameter:
content
- the content widget
-
setFlap
Veraltet.Sets the flap widget for @self.
It's only visible when [property@Flap:reveal-progress] is greater than 0.- Parameter:
flap
- the flap widget
-
setFlapPosition
Veraltet.Sets the flap position for @self.
If it's set to `GTK_PACK_START`, the flap is displayed before the content,
if `GTK_PACK_END`, it's displayed after the content.- Parameter:
position
- the new value
-
setFoldDuration
Veraltet.Sets the fold transition animation duration for @self, in milliseconds.- Parameter:
duration
- the new duration, in milliseconds
-
setFoldPolicy
Veraltet.Sets the fold policy for @self.- Parameter:
policy
- the fold policy
-
setFoldThresholdPolicy
Veraltet.Sets the fold threshold policy for @self.
If set to `ADW_FOLD_THRESHOLD_POLICY_MINIMUM`, flap will only fold when the
children cannot fit anymore. With `ADW_FOLD_THRESHOLD_POLICY_NATURAL`, it
will fold as soon as children don't get their natural size.
This can be useful if you have a long ellipsizing label and want to let it
ellipsize instead of immediately folding.- Parameter:
policy
- the policy to use
-
setLocked
Veraltet.Sets whether @self is locked.
If `FALSE`, folding when the flap is revealed automatically closes it, and
unfolding it when the flap is not revealed opens it. If `TRUE`,
[property@Flap:reveal-flap] value never changes on its own.- Parameter:
locked
- the new value
-
setModal
Veraltet.Sets whether @self is modal.
If `TRUE`, clicking the content widget while flap is revealed, as well as
pressing the <kbd>Esc</kbd> key, will close the flap. If `FALSE`, clicks are
passed through to the content widget.- Parameter:
modal
- whether @self is modal
-
setRevealFlap
Veraltet.Sets whether the flap widget is revealed for @self.- Parameter:
reveal_flap
- whether to reveal the flap widget
-
setRevealParams
Veraltet.Sets the reveal animation spring parameters for @self.
The default value is equivalent to:
```c
adw_spring_params_new (1, 0.5, 500)
```- Parameter:
params
- the new parameters
-
setSeparator
Veraltet.Sets the separator widget for @self.
It's displayed between content and flap when there's no shadow to display.
When exactly it's visible depends on the [property@Flap:transition-type]
value.- Parameter:
separator
- the separator widget
-
setSwipeToClose
Veraltet.Sets whether @self can be closed with a swipe gesture.
The area that can be swiped depends on the [property@Flap:transition-type]
value.- Parameter:
swipe_to_close
- whether @self can be closed with a swipe gesture
-
setSwipeToOpen
Veraltet.Sets whether @self can be opened with a swipe gesture.
The area that can be swiped depends on the [property@Flap:transition-type]
value.- Parameter:
swipe_to_open
- whether @self can be opened with a swipe gesture
-
setTransitionType
Veraltet.Sets the type of animation used for reveal and fold transitions in @self.
[property@Flap:flap] is transparent by default, which means the content will
be seen through it with `ADW_FLAP_TRANSITION_TYPE_OVER` transitions; add the
[`.background`](style-classes.html#background) style class to it if this is
unwanted.- Parameter:
transition_type
- the new transition type
-
asSwipeable
Implements interfaceSwipeable
. Call this to get access to interface functions.- Gibt zurück:
Swipeable
-
asAccessible
Implements interfaceAccessible
. Call this to get access to interface functions.- Setzt außer Kraft:
asAccessible
in KlasseWidget
- Gibt zurück:
Accessible
-
asBuildable
Implements interfaceBuildable
. Call this to get access to interface functions.- Setzt außer Kraft:
asBuildable
in KlasseWidget
- Gibt zurück:
Buildable
-
asConstraintTarget
Implements interfaceConstraintTarget
. Call this to get access to interface functions.- Setzt außer Kraft:
asConstraintTarget
in KlasseWidget
- Gibt zurück:
ConstraintTarget
-
asOrientable
Implements interfaceOrientable
. Call this to get access to interface functions.- Gibt zurück:
Orientable
-
getTypeID
public static long getTypeID() -
getParentTypeID
public static long getParentTypeID() -
getTypeSize
-
getParentTypeSize
-
getInstanceSize
public static int getInstanceSize()
-