KDockWidgetHeader class Reference (kdeui Library)

| # kdeui Library API Documentation
Overview | Class Hierarchy | Classes | Classes (annotated) | Members | Source Files

# KDockWidgetHeader Class Reference

The header (additional bar) for a KDockWidget s (and member of the dockwidget class set). More...

`#include <kdockwidget.h>`

Inheritance diagram for KDockWidgetHeader:

[legend]
Collaboration diagram for KDockWidgetHeader:

[legend]
List of all members.

## Public Member Functions
| KDockWidgetHeader (KDockWidget *parent, const char *name=0L)
| Constructs this.
virtual | ~KDockWidgetHeader ()
| Destructs this.
virtual void | setTopLevel (bool t)
| Hides the close button and stay button when switching to toplevel or vice versa shows them.
void | setDragPanel (KDockWidgetHeaderDrag *nd)
| Sets the drag panel of this header.
bool | dragEnabled () const
void | setDragEnabled (bool b)
void | showUndockButton (bool show)
| Since: 3.1
virtual void | saveConfig (KConfig *c)
| Saves the current button state to a KDE config container object.
virtual void | loadConfig (KConfig *)
| Loads the current button state from a KDE config container object.
## Protected Slots
void | slotStayClicked ()
| Sets dragging the dockwidget off when the stay button is pressed down and vice versa.
## Protected Member Functions
virtual void | virtual_hook (int id, void *data)
## Protected Attributes
QHBoxLayout * | layout
| A layout manager for placing the embedded buttons (close and stay).
KDockButton_Private * | closeButton
| a little button for closing (undocking and hiding) the dockwidget
KDockButton_Private * | stayButton
| a little button for enabling/disabling dragging the dockwidget with the mouse
KDockButton_Private * | dockbackButton
| a little button for dock back the dockwidget to it's previous dockwidget
KDockWidgetHeaderDrag * | drag
| the drag panel (double line)

## Detailed Description

The header (additional bar) for a KDockWidget s (and member of the dockwidget class set).

It have got the buttons located there. And it is for recording and reading the button states. More or less a minor helper class for the dockwidget class set.

Author:
  Max Judin (documentation: Falk Brettschneider).

Definition at line 233 of file kdockwidget.h.

## Constructor & Destructor Documentation

KDockWidgetHeader::KDockWidgetHeader | ( | KDockWidget * | parent,
|  | const char * | name = 0L
| ) |

  | Constructs this. Parameters:
  parent | the parent widget (usually a dockwidget)
  name | the object instance name
Definition at line 210 of file kdockwidget.cpp. References closeButton, dockbackButton, drag, layout, KStdAccel::name(), QPushButton::pixmap(), QPushButton::setPixmap(), QPushButton::setToggleButton(), slotStayClicked(), and stayButton.

virtual KDockWidgetHeader::~KDockWidgetHeader | ( |  | ) | `[inline, virtual]`

| Destructs this. Definition at line 249 of file kdockwidget.h.

## Member Function Documentation

void KDockWidgetHeader::setTopLevel | ( | bool | t | ) | `[virtual]`

  | Hides the close button and stay button when switching to toplevel or vice versa shows them. Parameters:
  t | toplevel or not
Reimplemented from KDockWidgetAbstractHeader. Definition at line 257 of file kdockwidget.cpp. References closeButton, dockbackButton, drag, KDockWidget::isDockBackPossible(), layout, and stayButton.

void KDockWidgetHeader::setDragPanel | ( | KDockWidgetHeaderDrag * | nd | ) |

  | Sets the drag panel of this header. Parameters:
  nd | A pointer to the new drag panel
Definition at line 283 of file kdockwidget.cpp. References closeButton, dockbackButton, drag, layout, and stayButton.

void KDockWidgetHeader::showUndockButton | ( | bool | show | ) |

| Since: 3.1 Definition at line 313 of file kdockwidget.cpp.

void KDockWidgetHeader::saveConfig | ( | KConfig * | c | ) | `[virtual]`

  | Saves the current button state to a KDE config container object. Parameters:
  c | the configuration safe
Reimplemented from KDockWidgetAbstractHeader. Definition at line 333 of file kdockwidget.cpp. References QPushButton::isOn(), KStdAccel::name(), stayButton, and KConfigBase::writeEntry().

void KDockWidgetHeader::loadConfig | ( | KConfig * |  | ) | `[virtual]`

  | Loads the current button state from a KDE config container object. Parameters:
  c | the configuration safe
Reimplemented from KDockWidgetAbstractHeader. Definition at line 338 of file kdockwidget.cpp. References KStdAccel::name(), and KConfigBase::readBoolEntry().

void KDockWidgetHeader::slotStayClicked | ( |  | ) | `[protected, slot]`

| Sets dragging the dockwidget off when the stay button is pressed down and vice versa. Definition at line 303 of file kdockwidget.cpp. References QPushButton::isOn(), and stayButton. Referenced by KDockWidgetHeader().

## Member Data Documentation

QHBoxLayout* KDockWidgetHeader::layout`[protected]`

| A layout manager for placing the embedded buttons (close and stay). Definition at line 297 of file kdockwidget.h. Referenced by KDockWidgetHeader(), setDragPanel(), and setTopLevel().

KDockButton_Private* KDockWidgetHeader::closeButton`[protected]`

| a little button for closing (undocking and hiding) the dockwidget Definition at line 302 of file kdockwidget.h. Referenced by KDockWidgetHeader(), setDragPanel(), and setTopLevel().

KDockButton_Private* KDockWidgetHeader::stayButton`[protected]`

| a little button for enabling/disabling dragging the dockwidget with the mouse Definition at line 307 of file kdockwidget.h. Referenced by KDockWidgetHeader(), saveConfig(), setDragPanel(), setTopLevel(), and slotStayClicked().

KDockButton_Private* KDockWidgetHeader::dockbackButton`[protected]`

| a little button for dock back the dockwidget to it's previous dockwidget Definition at line 312 of file kdockwidget.h. Referenced by KDockWidgetHeader(), setDragPanel(), and setTopLevel().

KDockWidgetHeaderDrag* KDockWidgetHeader::drag`[protected]`

| the drag panel (double line) Definition at line 317 of file kdockwidget.h. Referenced by KDockWidgetHeader(), setDragPanel(), and setTopLevel().

The documentation for this class was generated from the following files:

- kdockwidget.h
- kdockwidget.cpp

This file is part of the documentation for kdelibs Version 3.1.5.
Documentation copyright © 1996-2002 the KDE developers.
Generated on Wed Jan 28 13:00:34 2004 by doxygen 1.3.4 written by Dimitri van Heesch, © 1997-2001