FourWaySplitter
is a layout manager which manages 4 children like 4 panes in a
window.
The FourWaySplitter
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 FourWaySplitter
allows interactive repartitioning of the panes by
means of moving the central splitter bars. When the FourWaySplitter
is itself
resized, each child is proportionally resized, maintaining the same split-percentage.
The main characteristics of FourWaySplitter
are:
And a lot more. See the demo for a complete review of the functionalities.
Usage example:
import wx
import wx.lib.agw.fourwaysplitter as fws
class MyFrame(wx.Frame):
def __init__(self, parent):
wx.Frame.__init__(self, parent, -1, "FourWaySplitter Demo")
splitter = fws.FourWaySplitter(self, -1, agwStyle=wx.SP_LIVE_UPDATE)
# Put in some coloured panels...
for colour in [wx.RED, wx.WHITE, wx.BLUE, wx.GREEN]:
panel = wx.Panel(splitter)
panel.SetBackgroundColour(colour)
splitter.AppendWindow(panel)
# our normal wxApp-derived class, as usual
app = wx.App(0)
frame = MyFrame(None)
app.SetTopWindow(frame)
frame.Show()
app.MainLoop()
FourWaySplitter
has been tested on the following platforms:This class supports the following window styles:
Window Styles | Hex Value | Description |
---|---|---|
SP_NOSASH |
0x10 | No sash will be drawn on FourWaySplitter . |
SP_LIVE_UPDATE |
0x80 | Don’t draw XOR line but resize the child windows immediately. |
SP_3DBORDER |
0x200 | Draws a 3D effect border. |
This class processes the following events:
Event Name | Description |
---|---|
EVT_SPLITTER_SASH_POS_CHANGED |
The sash position was changed. This event is generated after the user releases the mouse after dragging the splitter. Processes a wx.wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED event. |
EVT_SPLITTER_SASH_POS_CHANGING |
The sash position is in the process of being changed. You may prevent this change from happening by calling Veto or you may also modify the position of the tracking bar to properly reflect the position that would be set if the drag were to be completed at this point. Processes a wx.wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING event. |
FourWaySplitter
is distributed under the wxPython license.
Latest Revision: Andrea Gavana @ 16 Jul 2012, 15.00 GMT
Version 0.5
FourWaySplitter |
This class is very similar to SplitterWindow except that it |
FourWaySplitterEvent |
This event class is almost the same as SplitterEvent except |