FreeBSD Manual Pages
AG_FIXED(3) Library Functions Manual AG_FIXED(3) NAME AG_Fixed -- agar fixed-position container widget SYNOPSIS #include <agar/core.h> #include <agar/gui.h> DESCRIPTION The AG_Fixed container widget positions and sizes its children at con- stant positions specified in pixels. INHERITANCE HIERARCHY AG_Object(3) -> AG_Widget(3) -> AG_Fixed. INITIALIZATION AG_Fixed * AG_FixedNew(AG_Widget *parent, Uint flags) void AG_FixedSetStyle(AG_Fixed *fixed, enum ag_fixed_style style) void AG_FixedSizeHint(AG_Fixed *fixed, int w, int h) The AG_FixedNew() function allocates, initializes, and attaches a new AG_Fixed widget. Accepted flags options include: AG_FIXED_NO_UPDATE Don't automatically call AG_WidgetUpdate(3) when- ever widgets are repositioned. This allows the caller to, as an optimization use AG_WidgetUpdate(3) only once after all widgets have been positioned. AG_FIXED_HFILL Expand horizontally in parent container. AG_FIXED_VFILL Expand vertically in parent container. AG_FIXED_EXPAND Shorthand for AG_FIXED_HFILL | AG_FIXED_VFILL. AG_FixedSetStyle() selects an alternate background and border style: AG_FIXED_STYLE_NONE No background. AG_FIXED_STYLE_BOX Raised box & border. AG_FIXED_STYLE_WELL 3D well & border (the default). AG_FIXED_STYLE_PLAIN Filled rectangle. Visible background styles use the style attributes "background-color", "low-color" and "high-color". AG_FixedSizeHint() requests an initial size of w by h pixels. CHILD WIDGETS void AG_FixedPut(AG_Fixed *fixed, AG_Widget *child, int x, int y) void AG_FixedDel(AG_Fixed *fixed, AG_Widget *child) void AG_FixedSize(AG_Fixed *fixed, AG_Widget *child, int width, int height) void AG_FixedMove(AG_Fixed *fixed, AG_Widget *child, int new_x, int new_y) The AG_FixedPut() function attaches the widget child and positions it at the given coordinates. AG_FixedDel() detaches the given widget. Alternatively, you can avoid AG_FixedPut() and AG_FixedDel() altogether and instead use AG_ObjectAttach(3) and AG_ObjectDetach(3) followed by calls to AG_FixedSize() and AG_FixedMove(). Functions AG_FixedSize() and AG_FixedMove() set the size and location of a given widget in pixels. EVENTS The AG_Fixed widget does not generate any event. STRUCTURE DATA For the AG_Fixed object: enum ag_fixed_style style Background style (see AG_FixedSetStyle()). EXAMPLES See tests/fixedres.c in the Agar source distribution. SEE ALSO AG_Box(3), AG_Intro(3), AG_MPane(3), AG_Pane(3), AG_Widget(3), AG_Window(3) HISTORY The AG_Fixed widget first appeared in Agar 1.0. In Agar 1.6.0 the for- mer AG_FIXED_BOX, AG_FIXED_INVBOX, AG_FIXED_FRAME and AG_FIXED_FILLBG flags were replaced by the AG_FixedSetStyle() and the style parameter. AG_FixedSizeHint() appeared in Agar 1.6.0. Agar 1.7 December 21, 2022 AG_FIXED(3)
NAME | SYNOPSIS | DESCRIPTION | INHERITANCE HIERARCHY | INITIALIZATION | CHILD WIDGETS | EVENTS | STRUCTURE DATA | EXAMPLES | SEE ALSO | HISTORY
Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=AG_Fixed&sektion=3&manpath=FreeBSD+Ports+14.3.quarterly>
