:right-sidebar: True AnchorHints =================================================================== .. currentmodule:: gi.repository.Gdk .. class:: AnchorHints :no-contents-entry: 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, :const:`~gi.repository.Gdk.AnchorHints.FLIP_X` will replace :const:`~gi.repository.Gdk.Gravity.NORTH_WEST` with :const:`~gi.repository.Gdk.Gravity.NORTH_EAST` and vice versa if the surface extends beyond the left or right edges of the monitor. If :const:`~gi.repository.Gdk.AnchorHints.SLIDE_X` is set, the surface can be shifted horizontally to fit on-screen. If :const:`~gi.repository.Gdk.AnchorHints.RESIZE_X` 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. Fields ------ .. rst-class:: interim-class .. class:: AnchorHints :no-index: .. attribute:: FLIP Allow flipping anchors on both axes .. attribute:: FLIP_X Allow flipping anchors horizontally .. attribute:: FLIP_Y Allow flipping anchors vertically .. attribute:: RESIZE Allow resizing surface on both axes .. attribute:: RESIZE_X Allow resizing surface horizontally .. attribute:: RESIZE_Y Allow resizing surface vertically .. attribute:: SLIDE Allow sliding surface on both axes .. attribute:: SLIDE_X Allow sliding surface horizontally .. attribute:: SLIDE_Y Allow sliding surface vertically