Package: gdk

GFlags gdk:anchor-hints

Declaration

(gobject:define-gflags "GdkAnchorHints" anchor-hints
  (:export t
   :type-initializer "gdk_anchor_hints_get_type")
  (:flip-x #.(ash 1 0))
  (:flip-y #.(ash 1 1))
  (:slide-x #.(ash 1 2))
  (:slide-y #.(ash 1 3))
  (:resize-x #.(ash 1 4))
  (:resize-y #.(ash 1 5))
  (:flip #.(+ (ash 1 0) (ash 1 1)))
  (:slide #.(+ (ash 1 2) (ash 1 3)))
  (:resize #.(+ (ash 1 4) (ash 1 5))))  

Values

:flip-x
Allow flipping anchors horizontally.
:flip-y
Allow flipping anchors vertically.
:slide-x
Allow sliding surface horizontally.
:slide-y
Allow sliding surface vertically.
:resize-x
Allow resizing surface horizontally.
:resize-y
Allow resizing surface vertically.
:flip
Allow flipping anchors on both axes.
:slide
Allow sliding surface on both axes.
:resize
Allow resizing surface on both axes.

Details

Positioning hints for aligning a surface relative to a rectangle. These hints determine how the surface should be positioned in the case that the surface would fall off-screen if placed in its ideal position.

For example, the :flip-x value will replace the :north-west gravity with the :north-east gravity and vice versa if the surface extends beyond the left or right edges of the monitor.

If the :slide-x value is set, the surface can be shifted horizontally to fit on-screen. If the :resize-x value is set, the surface can be shrunken horizontally to fit.

In general, when multiple flags are set, flipping should take precedence over sliding, which should take precedence over resizing.
 

See also

2024-2-17