The QLayout class is the base class of geometry specifiers. More...
#include <qlayout.h>
Inherits QObject.
Inherited by QBoxLayout and QGridLayout.
This is an abstract base class. The concrete layout managers QBoxLayout and QGridLayout inherit from this one and make QLayout's functionality avaialble in friendly APIs.
Most users of Q*Layout are likely to use some of the basic functions provided by QLayout, such as
Geometry management stops when the layout manager is deleted.
To make a new layout manager, you need to implement the functions mainVerticalChain(), mainHorizontalChain() and initGM().
[protected]
Creates a new top-level QLayout with main widget parent. parent may not be 0.
border is the number of pixels between the edge of the widget and the managed children. autoBorder sets the value of defaultBorder(), which is interpreted by subclasses. If autoBorder is -1 the value of border is used.
name is the internal object name
Having several top-level layouts for the same widget will cause considerable confusion.
[protected]
Constructs a new child QLayout, If autoBorder is -1, this QLayout inherits parent's defaultBorder(), otherwise autoBorder is used.
[virtual]
Deletes all children layouts. Geometry management stops when a toplevel layout is deleted.
[virtual]
Starts geometry management - analogous to show() for widgets. This function should only be called for top level layouts.
Examples: pref/pref.cpp layout/layout.cpp widgets/widgets.cpp
[protected]
This function is called from addLayout functions in subclasses, to add l layout as a sublayout.
[protected]
Returns the QGManager for this layout. Returns 0 if this is a child layout which has not been inserted yet.
Returns the default border for the geometry manager.
Fixes the size of the main widget and distributes the available space to the child widgets. For widgets which should not be resizable, but where a QLayout subclass is used to set up the initial geometry.
A frozen layout cannot be unfrozen, the only sensible thing to do is to delete it.
The size is adjusted to a valid value. Thus freeze(0,0) fixes the widget to its minimum size.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This version of the method fixes the main widget at its minimum size. You can also achieve this with freeze( 0, 0 );.
[static protected]
This function works around a dubious feature in the C++ language definition, to provide access to mainHorizontalChain().
[virtual protected]
Implement this function to do what's necessary to initialize chains, once the layout has a basicManager().
Reimplemented in QGridLayout and QBoxLayout.
[virtual protected]
Implement this function to return the main horizontal chain.
Reimplemented in QGridLayout and QBoxLayout.
[virtual protected]
Implement this function to return the main vertical chain.
Reimplemented in QGridLayout and QBoxLayout.
Returns the main widget of this layout, or 0 if this layout is a sub-layout which is not yet inserted.
Makes the geometry manager take account of the menu bar w. All child widgets are placed below the bottom edge of the menu bar.
A menu bar does its own geometry managing, never do addWidget() on a menu bar.
Examples: widgets/widgets.cpp
[static protected]
This function works around a dubious feature in the C++ language definition, to provide access to mainVerticalChain().
Search the documentation, FAQ, qt-interest archive and more (uses
www.troll.no):
This file is part of the Qt toolkit, copyright © 1995-98 Troll Tech, all rights reserved.
It was generated from the following files:
Copyright © 1998 Troll Tech | Trademarks | Qt version 1.42
|