class MASKING_DLL_DECLSPEC Splitter

An invisible splitter object.

Inheritance:

Splitter - Dialog - Widget - Rect


Public Methods

[more]void Attach(Widget* w, int section)
Attaches an exisiting widget (or dialog) to the splitter.
[more]void Detach(Widget* w)
Removes the passed widget from the splitter
[more]void SetBufferZone(int pixels)
Sets the size of the buffer zone between widgets in pixels.
[more]void SetOffset(int x, int y)
Sets the offset of the centre point of the splitter from its centre.

Protected Fields

[more]Widget* attached[4]
Pointers to the 4 attached widgets/dialogs
[more]int bufferZone
The width of the buffer zone between dialogs.
[more]int offsetX
Horizontal offset from the centre
[more]int offsetY
Vertical offset from the centre

Protected Methods

[more]void UpdateSize()
Updates the size and position of all the widgets attached to the splitter.


Documentation

An invisible splitter object. Splitters can be used to separate and resize up to 4 widgets (or dialogs). The dialogs attached to a splitter share the area of the splitter and the splitter allows the user to resize them at will.
oWidget* attached[4]
Pointers to the 4 attached widgets/dialogs

oint bufferZone
The width of the buffer zone between dialogs. Should be positive. The default is 4 pixels.

oint offsetX
Horizontal offset from the centre

oint offsetY
Vertical offset from the centre

ovoid UpdateSize()
Updates the size and position of all the widgets attached to the splitter. This function places and resizes all the widgets so that they take up as much space of the spitter window as possible without overlapping.

ovoid Attach(Widget* w, int section)
Attaches an exisiting widget (or dialog) to the splitter. Pass the section of the splitter where you want to put the widget. Possible sections are:
      0 - top left
      1 - bottom left
      2 - top right
      3 - bottom right
If a widget already occupies the desired section, the existing widget will be removed.

ovoid Detach(Widget* w)
Removes the passed widget from the splitter

ovoid SetBufferZone(int pixels)
Sets the size of the buffer zone between widgets in pixels. The default value is 4.

ovoid SetOffset(int x, int y)
Sets the offset of the centre point of the splitter from its centre. The default is (0,0). Negative values move the splitter left and up, positive move it right and down.
Note: you can only set the offset after you've set the size of the splitter.


This class has no child classes.

Alphabetic index Hierarchy of classes


Back to front page   |   page generated with DOC++