Package wx :: Package lib :: Module foldpanelbar
[frames | no frames]

Module wx.lib.foldpanelbar

Description:

The FoldPanelBar is a control that contains multiple panels (FoldPanel items) that can be expanded or collapsed. The captionbar of the FoldPanel can be customized by setting it to a horizontal gradient style, vertical gradient style, a single color, a rectangle or filled rectangle. The FoldPanel items can be collapsed in place or to the bottom of the control. The wxWindow derived controls can be added dynamically, and separated by separator lines. FoldPanelBar is freeware and distributed under the wxPython license.

The internals of the FoldPanelBar is a list of FoldPanelItem objects. Through the reference of FoldPanel these panels can be controlled by adding new controls to a FoldPanel or adding new FoldPanels to the FoldPanelBar. The CaptionBar fires events to the parent (container of all panel items) when a sub-panel needs resizing (either folding or expanding). The fold or expand process is simply a resize of the panel so it looks like all controls on it are gone. All controls are still child of the FoldPanel they are located on. If they don't handle the event (and they won't) then the owner of the FoldPanelBar gets the events. This is what you need to handle the controls. There isn't much to it just a lot of calculations to see what panel belongs where. There are no sizers involved in the panels, everything is purely x-y positioning.

FoldPanelBar is supported on the following platforms: Windows (Verified on Windows XP, 2000) Linux/Unix (GTK2) (Thanks To Toni Brkic And Robin Dunn) Mac OSX (Thanks To Robin Dunn For The CaptionBar Size Patch)

Latest Revision: Andrea Gavana @ 30 Mar 2005, 22.30 CET


Classes
CaptionBar  
CaptionBarEvent  
CaptionBarStyle  
FoldPanelBar  
FoldPanelItem  
FoldWindowItem  

Function Summary
  GetCollapsedIconBitmap()
  GetCollapsedIconData()
  GetCollapsedIconImage()
  GetExpandedIconBitmap()
  GetExpandedIconData()
  GetExpandedIconImage()

Variable Summary
int CAPTIONBAR_FILLED_RECTANGLE = 5                                                                     
int CAPTIONBAR_GRADIENT_H = 2                                                                     
int CAPTIONBAR_GRADIENT_V = 1                                                                     
int CAPTIONBAR_NOSTYLE = 0                                                                     
int CAPTIONBAR_RECTANGLE = 4                                                                     
int CAPTIONBAR_SINGLE = 3                                                                     
PyEventBinder EVT_CAPTIONBAR = <wx._core.PyEventBinder object at 0x406...
int FPB_ALIGN_LEFT = 0                                                                     
int FPB_ALIGN_WIDTH = 1                                                                     
int FPB_BMP_RIGHTSPACE = 2                                                                     
int FPB_COLLAPSE_TO_BOTTOM = 2                                                                     
int FPB_DEFAULT_EXTRASTYLE = 0                                                                     
int FPB_DEFAULT_LEFTLINESPACING = 2                                                                     
int FPB_DEFAULT_LEFTSPACING = 5                                                                     
int FPB_DEFAULT_RIGHTLINESPACING = 2                                                                     
int FPB_DEFAULT_RIGHTSPACING = 10                                                                    
int FPB_DEFAULT_SPACING = 8                                                                     
int FPB_DEFAULT_STYLE = 2621440                                                               
int FPB_EXCLUSIVE_FOLD = 3                                                                     
int FPB_EXTRA_X = 10                                                                    
int FPB_EXTRA_Y = 4                                                                     
int FPB_HORIZONTAL = 4                                                                     
int FPB_SINGLE_FOLD = 1                                                                     
int FPB_VERTICAL = 8                                                                     
int wxEVT_CAPTIONBAR = 10271                                                                 

Variable Details

CAPTIONBAR_FILLED_RECTANGLE

Type:
int
Value:
5                                                                     

CAPTIONBAR_GRADIENT_H

Type:
int
Value:
2                                                                     

CAPTIONBAR_GRADIENT_V

Type:
int
Value:
1                                                                     

CAPTIONBAR_NOSTYLE

Type:
int
Value:
0                                                                     

CAPTIONBAR_RECTANGLE

Type:
int
Value:
4                                                                     

CAPTIONBAR_SINGLE

Type:
int
Value:
3                                                                     

EVT_CAPTIONBAR

Type:
PyEventBinder
Value:
<wx._core.PyEventBinder object at 0x40694ecc>                          

FPB_ALIGN_LEFT

Type:
int
Value:
0                                                                     

FPB_ALIGN_WIDTH

Type:
int
Value:
1                                                                     

FPB_BMP_RIGHTSPACE

Type:
int
Value:
2                                                                     

FPB_COLLAPSE_TO_BOTTOM

Type:
int
Value:
2                                                                     

FPB_DEFAULT_EXTRASTYLE

Type:
int
Value:
0                                                                     

FPB_DEFAULT_LEFTLINESPACING

Type:
int
Value:
2                                                                     

FPB_DEFAULT_LEFTSPACING

Type:
int
Value:
5                                                                     

FPB_DEFAULT_RIGHTLINESPACING

Type:
int
Value:
2                                                                     

FPB_DEFAULT_RIGHTSPACING

Type:
int
Value:
10                                                                    

FPB_DEFAULT_SPACING

Type:
int
Value:
8                                                                     

FPB_DEFAULT_STYLE

Type:
int
Value:
2621440                                                               

FPB_EXCLUSIVE_FOLD

Type:
int
Value:
3                                                                     

FPB_EXTRA_X

Type:
int
Value:
10                                                                    

FPB_EXTRA_Y

Type:
int
Value:
4                                                                     

FPB_HORIZONTAL

Type:
int
Value:
4                                                                     

FPB_SINGLE_FOLD

Type:
int
Value:
1                                                                     

FPB_VERTICAL

Type:
int
Value:
8                                                                     

wxEVT_CAPTIONBAR

Type:
int
Value:
10271                                                                 

Generated by Epydoc 2.1.20040428.rpd on Tue Apr 26 14:24:40 2005 http://epydoc.sf.net