class KTMLayout

Special layout manager for KTMainWindow. More...

Definition#include <ktmlayout.h>
InheritsQLayout (qk)
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods


Detailed Description

KTMLayout is layout manager for KTMainWindow. It is customized specifically for KTMainWindow's layout. You can use it for your own widgets but there is probably little use for it. So this class can be regarded as a kdeui internal class.

It currently supports main widget with fixed size, fixed height and widgets with no size requirements. heightForWidth() widgets and fixed width widgets are not yet supported. It is currently unclear whether the concept of widthForHeight() vertical bars can be used in a widthForHeight() dominated world.

IMPORTANT: The layout functions and the corresponding size-calculation functions must always be kept 100% in sync!

KTMLayout ()

The constructor. It probably makes no use to call this version.

KTMLayout (QWidget *parent, int border = 0, int space = -1, const char *name = 0)

The constructor.

void addTopMenuBar (QWidget* w)

Register the top menu bar. There can only be one.

void addBottomMenuBar (QWidget* w)

Register the bottom menu bar. There can only be one.

void addFlatBar (QWidget* w)

Call this function to register all bars that are flattened. This can be tool bars as well as menu bars.

void addTopToolBar (KToolBar* w)

Register top tool bars. There is no limit in the number of tool bars that you can register.

void addLeftToolBar (KToolBar* w)

Register left hand side tool bars. There is no limit in the number of tool bars that you can register.

void addRightToolBar (KToolBar* w)

Register right hand side tool bars. There is no limit in the number of tool bars that you can register.

void addBottomToolBar (KToolBar* w)

Register bottom tool bars. There is no limit in the number of tool bars that you can register.

void addMainItem (QWidget* w)

Use this function to register the main widget. There must be exactly one main widget!

void addStatusBar (QWidget* w)

Use this function to register the status bar. There can only be one.

void setMaximumWraps (unsigned int wraps)

This function can be used to limit the number of lines/columns that are used by a single block of non-full-width toolbars. When the specified limit is reached the remaining bars will extend outside the window.

void setGeometry (const QRect& rect)

This function arranges the widgets. It determines the necessary space for the toolbars and assignes the remainder to the main widget.

QSize sizeHint ()
[const]

Returns the preferred size of the layout.

QSize minimumSize ()
[const]

Returns the minimum required size of the layout.

void addItem (QLayoutItem* item)

Never use this function. It is provided to be compliant with Qt.

QLayoutIterator iterator ()

Never use this function. It is provided to be compliant with Qt.