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

FX::FXSwitcher Class Reference

The Switcher layout manager automatically arranges its child windows such that one of them is placed on top; all other child windows are hidden. More...

#include <FXSwitcher.h>

Inheritance diagram for FX::FXSwitcher:

FX::FXPacker FX::FXComposite FX::FXWindow FX::FXDrawable FX::FXId FX::FXObject List of all members.

Public Member Functions

 FXSwitcher (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)
virtual FXint getDefaultWidth ()
virtual FXint getDefaultHeight ()
virtual void layout ()
void setCurrent (FXint index, FXbool notify=FALSE)
FXint getCurrent () const
void setSwitcherStyle (FXuint style)
FXuint getSwitcherStyle () const
virtual void save (FXStream &store) const
virtual void load (FXStream &store)

Detailed Description

The Switcher layout manager automatically arranges its child windows such that one of them is placed on top; all other child windows are hidden.

Switcher provides a convenient method to conserve screen real-estate by arranging several GUI panels to appear in the same space, depending on context. Switcher ignores all layout hints from its children:- all children are stretched according to the switcher layout managers own size. When the SWITCHER_HCOLLAPSE or SWITCHER_VCOLLAPSE options are used, Switcher's default size is based on the width or height of the current child, instead of the maximum width or height of all of the children.

See also:


Constructor & Destructor Documentation

FX::FXSwitcher::FXSwitcher 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
 

Construct a switcher layout manager.


Member Function Documentation

virtual FXint FX::FXSwitcher::getDefaultWidth  )  [virtual]
 

Return default width.

Reimplemented from FX::FXPacker.

virtual FXint FX::FXSwitcher::getDefaultHeight  )  [virtual]
 

Return default height.

Reimplemented from FX::FXPacker.

virtual void FX::FXSwitcher::layout  )  [virtual]
 

Perform layout.

Reimplemented from FX::FXPacker.

void FX::FXSwitcher::setCurrent FXint  index,
FXbool  notify = FALSE
 

Bring the child window at index to the top.

FXint FX::FXSwitcher::getCurrent  )  const [inline]
 

Return the index of the child window currently on top.

void FX::FXSwitcher::setSwitcherStyle FXuint  style  ) 
 

Set the switcher style flags.

FXuint FX::FXSwitcher::getSwitcherStyle  )  const
 

Get the switcher style flags.

virtual void FX::FXSwitcher::save FXStream store  )  const [virtual]
 

Save to stream.

Reimplemented from FX::FXPacker.

virtual void FX::FXSwitcher::load FXStream store  )  [virtual]
 

Load from stream.

Reimplemented from FX::FXPacker.

Copyright © 1997-2004 Jeroen van der Zijp