A specialized layout taking care of panel display.
More...
List of all members.
Classes |
struct | PanelWrapper |
Public Types |
enum | Position { West,
North,
South,
East
} |
Public Slots |
virtual void | addItem (QLayoutItem *item) |
virtual void | setGeometry (const QRect &rect) |
void | add (QLayoutItem *item, Position position) |
void | addWidget (QWidget *widget, Position position) |
| Add a panel at a given position.
|
Public Member Functions |
| QPanelLayout (QEditor *p) |
| ctor
|
| QPanelLayout (const QString &layout, QEditor *p) |
| ctor
|
virtual | ~QPanelLayout () |
| dtor
|
virtual int | count () const |
virtual bool | hasHeightForWidth () const |
virtual Qt::Orientations | expandingDirections () const |
virtual QSize | sizeHint () const |
virtual QSize | minimumSize () const |
virtual QLayoutItem * | itemAt (int idx) const |
virtual QLayoutItem * | takeAt (int idx) |
QString | serialized () const |
void | addSerialized (const QString &layout) |
| Add the content of a serialized layout structure.
|
QList< QPanel * > | panels () const |
Detailed Description
A specialized layout taking care of panel display.
The panel layout is specialized in several ways :
-
It only operates on specific widgets (which inherit QPanel)
-
It can only layout widgets in the viewport margins of a QEditor (could work with any QAbstractScrollArea if a single method was made public instead of protected...) so it does not qualify as a "real" layout (contrary to grid/box layouts)
-
It positions widgets on the border of the editor in the same way the Border Layout example does (most of the layout code actually comes from there).
-
It provides serialization/deserialization of its layout structure
Constructor & Destructor Documentation
QPanelLayout::QPanelLayout |
( |
const QString & |
layout, |
|
|
QEditor * |
p |
|
) |
| |
ctor
- Parameters:
-
layout | structure to deserailize |
References addSerialized().
Member Function Documentation
int QPanelLayout::count |
( |
| ) |
const |
|
virtual |
- Returns:
- the count of managed panels
- Returns:
- the list of panels managed by the layout
QString QPanelLayout::serialized |
( |
| ) |
const |
- Returns:
- A serialized layout strucure
The documentation for this class was generated from the following files: