Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Related Pages

Box: The Box Layout Container.

Defines the Ewl_Box class used for laying out Ewl_Widget's in a horizontal or vertical line. More...

Data Structures

struct  Ewl_Box
 Inherits from an Ewl_Container to provide layout facilities for child widgets placed inside. More...

struct  Ewl_Box
 Inherits from an Ewl_Container to provide layout facilities for child widgets placed inside. More...


Defines

#define EWL_BOX(box)   ((Ewl_Box *) box)
 Typecast a pointer to an Ewl_Box pointer.

#define ewl_hbox_new()   ewl_box_new(EWL_ORIENTATION_HORIZONTAL)
 Shortcut to allocate a new horizontal Ewl_Box.

#define ewl_vbox_new()   ewl_box_new(EWL_ORIENTATION_VERTICAL)
 Shortcut to allocate a new vertical Ewl_Box.


Typedefs

typedef Ewl_Box Ewl_Box
 The box widget is an Ewl_Container and lays out Ewl_Widget's either horizontally or vertically.


Functions

Ewl_Widgetewl_box_new (Ewl_Orientation orientation)
 Allocate and initialize a new box with given orientation.

int ewl_box_init (Ewl_Box *box, Ewl_Orientation orientation)
 Initialize the box to starting values.

void ewl_box_orientation_set (Ewl_Box *b, Ewl_Orientation o)
 Change the specified box's orientation.

Ewl_Orientation ewl_box_orientation_get (Ewl_Box *b)
 Retrieves the orientation of the box.

void ewl_box_spacing_set (Ewl_Box *b, int spacing)
 Changes the spacing between the objects in the box.

void ewl_box_homogeneous_set (Ewl_Box *b, int h)
 Change the homogeneous layout of the box.


Detailed Description

Defines the Ewl_Box class used for laying out Ewl_Widget's in a horizontal or vertical line.


Function Documentation

void ewl_box_homogeneous_set Ewl_Box b,
int  h
 

Change the homogeneous layout of the box.

Parameters:
b: the box to change homogeneous layout
h: the boolean value to change the layout mode to
Returns:
Returns no value.
Boxes use homogeneous layout by default, this can be used to change that.

int ewl_box_init Ewl_Box b,
Ewl_Orientation  o
 

Initialize the box to starting values.

Parameters:
b: the box to initialize
o: the orientation for the box to layout child widgets
Returns:
Returns no value.
Responsible for setting up default values and callbacks within a box structure.

Ewl_Widget* ewl_box_new Ewl_Orientation  o  ) 
 

Allocate and initialize a new box with given orientation.

Parameters:
o: the orientation for the box's layout
Returns:
Returns NULL on failure, or a newly allocated box on success.

Ewl_Orientation ewl_box_orientation_get Ewl_Box b  ) 
 

Retrieves the orientation of the box.

Parameters:
b: the box to retrieve orientation
Returns:
Returns the orientation value of the box b.

void ewl_box_orientation_set Ewl_Box b,
Ewl_Orientation  o
 

Change the specified box's orientation.

Parameters:
b: the box to change the orientation
o: the orientation to set for the box
Returns:
Returns no value.
Changes the orientation of the specified box, and reconfigures it in order for the appearance to be updated.

void ewl_box_spacing_set Ewl_Box b,
int  s
 

Changes the spacing between the objects in the box.

Parameters:
b: the box to change the spacing
s: the spacing to put between the child widgets
Returns:
Returns no value.
Adjust the spacing of the specified box and reconfigure it to change the appearance.