CtkBox

## CtkBox CtkBox — Base class for box containers |

## Synopsis

                        CtkBoxPrivate;
                        CtkBoxChild;
                        CtkBox;
    void                ctk_box_pack                        (CtkBox *box,
                                                             ClutterActor *child,
                                                             gboolean expand,
                                                             gboolean fill);
    void                ctk_box_set_homogeneous             (CtkBox *box,
                                                             gboolean homogeneous);
    gboolean            ctk_box_get_homogeneous             (CtkBox *box);
    void                ctk_box_set_spacing                 (CtkBox *box,
                                                             gint spacing);
    gint                ctk_box_get_spacing                 (CtkBox *box);
    void                ctk_box_set_orientation             (CtkBox *box,
                                                             CtkOrientation orient);
    CtkOrientation      ctk_box_get_orientation             (CtkBox *box);
    void                ctk_box_sort_children               (CtkBox *box,
                                                             GCompareFunc func);

## Object Hierarchy

      GObject
       +----GInitiallyUnowned
             +----ClutterActor
                   +----CtkActor
                         +----CtkBox
                               +----CtkHBox
                               +----CtkVBox

## Implemented Interfaces

CtkBox implements ClutterScriptable, CtkFocusable and ClutterContainer.

## Properties

      "homogeneous"              gboolean              : Read / Write
      "orientation"              gint                  : Read / Write
      "spacing"                  gint                  : Read / Write

## Description

CtkBox is a base class for our box containers, It handles all the logic for CtkVbox and CtkHbox

## Details

### CtkBoxPrivate

    typedef struct _CtkBoxPrivate CtkBoxPrivate;

### CtkBoxChild

    typedef struct _CtkBoxChild CtkBoxChild;

### CtkBox

    typedef struct _CtkBox CtkBox;

### ctk_box_pack ()

    void                ctk_box_pack                        (CtkBox *box,
                                                             ClutterActor *child,
                                                             gboolean expand,
                                                             gboolean fill);

Adds an `actor` to the given `box`, the `actor` is added to the end of the box

`box` : | A CtkBox
`child` : | The ClutterActor that is to be added to the `box`
`expand` : | TRUE if the `actor` is to be given extra space allocated to `box`
`fill` : | TRUE if space given to `actor` by the expand option is actually allocated to `actor`, rather than just padding it.

### ctk_box_set_homogeneous ()

    void                ctk_box_set_homogeneous             (CtkBox *box,
                                                             gboolean homogeneous);

sets the "homogeneous" property of the `box`, controls whether all the children in `box` are given equal space.

`box` : | a CtkBox
`homogeneous` : | a boolean value dictating if children in `box` are homogeneous

### ctk_box_get_homogeneous ()

    gboolean            ctk_box_get_homogeneous             (CtkBox *box);

gets whether the `box` is homogeneous, see `ctk_box_set_homogeneous()`

`box` : | a CtkBox
Returns : | TRUE or FALSE

### ctk_box_set_spacing ()

    void                ctk_box_set_spacing                 (CtkBox *box,
                                                             gint spacing);

Sets the size of the spacing for `box`, which is the number of pixels between the children of `box`

`box` : | a CtkBox
`spacing` : | a gint refering to the size of the spacing in pixels

### ctk_box_get_spacing ()

    gint                ctk_box_get_spacing                 (CtkBox *box);

Returns the spacing of `box`, see also `ctk_box_set_spacing()`

`box` : | a CtkBox
Returns : | An integer regarding `box` spacing

### ctk_box_set_orientation ()

    void                ctk_box_set_orientation             (CtkBox *box,
                                                             CtkOrientation orient);

Sets the orientation of the given box, see CtkOrientation

`box` : | a CtkBox
`orient` : | a CtkOrientation orientation

### ctk_box_get_orientation ()

    CtkOrientation      ctk_box_get_orientation             (CtkBox *box);

Gets the orientation of `box`

`box` : | a CtkBox
Returns : | a CtkOrientation detailing `box` orientation

### ctk_box_sort_children ()

    void                ctk_box_sort_children               (CtkBox *box,
                                                             GCompareFunc func);

Sorts the children in `box` using `func` as its comparison function

`box` : | a CtkBox
`func` : | a GCompareFunc to be used to sort children in `box`

## Property Details

### The `"homogeneous"` property

      "homogeneous"              gboolean              : Read / Write

Whether the children should all be the same size.

Default value: FALSE

### The `"orientation"` property

      "orientation"              gint                  : Read / Write

The orientation of the box.

Allowed values: [0,1]

Default value: 1

### The `"spacing"` property

      "spacing"                  gint                  : Read / Write

The amount of space between the children.

Allowed values: >= 0

Default value: 0

## See Also

CtkVBox CtkHBox `include` ctk-box.h