Class Fox::FX4Splitter |
|
The four-way splitter is a layout manager which manages four children like four panes in a window. You can use a four-way splitter for example in a CAD program where you may want to maintain three orthographic views, and one oblique view of a model. The four-way splitter allows interactive repartitioning of the panes by means of moving the central splitter bars. When the four-way splitter is itself resized, each child is proportionally resized, maintaining the same split-percentage.
The following messages are sent by FX4Splitter to its target:
SEL_LEFTBUTTONPRESS: | sent when the left mouse button goes down; the message data is an FXEvent instance. |
SEL_LEFTBUTTONRELEASE: | sent when the left mouse button goes up; the message data is an FXEvent instance. |
SEL_COMMAND: | sent at the end of a resize operation, to signal that the resize is complete |
SEL_CHANGED: | sent continuously while a resize operation is occurring |
FOURSPLITTER_TRACKING: | Track continuously during split |
FOURSPLITTER_NORMAL: | Normal mode (no continuous tracking) |
ID_EXPAND_ALL: | Expand all four panes |
ID_EXPAND_TOPLEFT: | Expand the top left pane |
ID_EXPAND_TOPRIGHT: | Expand the top right pane |
ID_EXPAND_BOTTOMLEFT: | Expand the bottom left pane |
ID_EXPAND_BOTTOMRIGHT: | Expand the bottom right pane |
Methods |
Attributes |
barSize | [RW] | Splitter bar width, in pixels [Integer] |
bottomLeft | [R] | Bottom left child window, if any [FXWindow] |
bottomRight | [R] | Bottom right child window, if any [FXWindow] |
expanded | [RW] | Currently expanded child (0, 1, 2 or 3) or -1 if not expanded [Integer] |
hSplit | [RW] | Horizontal split fraction [Integer] |
splitterStyle | [RW] | Current splitter style, either FOURSPLITTER_TRACKING or FOURSPLITTER_NORMAL |
topLeft | [R] | Top left child window, if any [FXWindow] |
topRight | [R] | Top right child window, if any [FXWindow] |
vSplit | [RW] | Vertical split fraction [Integer] |
Public Class methods |
new(p, opts=FOURSPLITTER_NORMAL, x=0, y=0, w=0, h=0) {|theSplitter | ...} |
Create 4-way splitter, initially shown as four unexpanded panes.
p: | the parent widget for this splitter [FXComposite] |
opts: | the options [Integer] |
x: | initial x-position, when the LAYOUT_FIX_X layout hint is in effect [Integer] |
y: | initial y-position, when the LAYOUT_FIX_Y layout hint is in effect [Integer] |
w: | initial width, when the LAYOUT_FIX_WIDTH layout hint is in effect [Integer] |
h: | initial height, when the LAYOUT_FIX_HEIGHT layout hint is in effect [Integer] |
new(p, tgt, sel, opts=FOURSPLITTER_NORMAL, x=0, y=0, w=0, h=0) {|theSplitter | ...} |
Create 4-way splitter, initially shown as four unexpanded panes; notifies tgt about size changes.
p: | the parent widget for this splitter [FXComposite] |
tgt: | message target [FXObject] |
sel: | message identifier [Integer] |
opts: | the options [Integer] |
x: | initial x-position, when the LAYOUT_FIX_X layout hint is in effect [Integer] |
y: | initial y-position, when the LAYOUT_FIX_Y layout hint is in effect [Integer] |
w: | initial width, when the LAYOUT_FIX_WIDTH layout hint is in effect [Integer] |
h: | initial height, when the LAYOUT_FIX_HEIGHT layout hint is in effect [Integer] |