Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

FXPacker Class Reference

#include <FXPacker.h>

Inheritance diagram for FXPacker:

FXComposite FXWindow FXDrawable FXId FXObject FXColorSelector FXComboBox FXDirSelector FXFileSelector FXFontSelector FXGroupBox FXHorizontalFrame FXListBox FXMatrix FXSpinner FXSwitcher FXTabBar FXToolbar FXTreeListBox FXVerticalFrame List of all members.

Public Methods

 FXPacker (FXComposite *p, FXuint opts=0, FXint x=0, FXint y=0, FXint w=0, FXint h=0, FXint pl=DEFAULT_SPACING, FXint pr=DEFAULT_SPACING, FXint pt=DEFAULT_SPACING, FXint pb=DEFAULT_SPACING, FXint hs=DEFAULT_SPACING, FXint vs=DEFAULT_SPACING)
 Construct packer layout manager.

virtual FXint getDefaultWidth ()
 Return default width.

virtual FXint getDefaultHeight ()
 Return default height.

void setFrameStyle (FXuint style)
 Change frame style.

FXuint getFrameStyle () const
 Get current frame style.

void setPackingHints (FXuint ph)
 Change packing hints.

FXuint getPackingHints () const
 Return packing hints.

FXint getBorderWidth () const
 Get border width.

void setPadTop (FXint pt)
 Change top padding.

FXint getPadTop () const
 Get top interior padding.

void setPadBottom (FXint pb)
 Change bottom padding.

FXint getPadBottom () const
 Get bottom interior padding.

void setPadLeft (FXint pl)
 Change left padding.

FXint getPadLeft () const
 Get left interior padding.

void setPadRight (FXint pr)
 Change right padding.

FXint getPadRight () const
 Get right interior padding.

void setHiliteColor (FXColor clr)
 Change highlight color.

FXColor getHiliteColor () const
 Get highlight color.

void setShadowColor (FXColor clr)
 Change shadow color.

FXColor getShadowColor () const
 Get shadow color.

void setBorderColor (FXColor clr)
 Change border color.

FXColor getBorderColor () const
 Get border color.

void setBaseColor (FXColor clr)
 Change base gui color.

FXColor getBaseColor () const
 Get base gui color.

void setHSpacing (FXint hs)
 Change horizontal inter-child spacing.

FXint getHSpacing () const
 Return current horizontal inter-child spacing.

void setVSpacing (FXint vs)
 Change vertical inter-child spacing.

FXint getVSpacing () const
 Return current vertical inter-child spacing.

virtual void save (FXStream &store) const
 Save to stream.

virtual void load (FXStream &store)
 Load from stream.


Detailed Description

Packer is a layout manager which automatically places child windows inside its area against the left, right, top, or bottom side. Each time a child is placed, the remaining space is decreased by the amount of space taken by the child window. The side against which a child is placed is determined by the LAYOUT_SIDE_TOP, LAYOUT_SIDE_BOTTOM, LAYOUT_SIDE_LEFT, and LAYOUT_SIDE_RIGHT hints given by the child window. Other layout hints from the child are observed as far as sensible. So for example, a child placed against the right edge can still have LAYOUT_FILL_Y or LAYOUT_TOP, and so on. The last child may have both LAYOUT_FILL_X and LAYOUT_FILL_Y, in which case it will be placed to take all remaining space.