• Skip to content
  • Skip to link menu
KDE 4.6 API Reference
  • KDE API Reference
  • kdelibs
  • KDE Home
  • Contact Us
 

KDEUI

Public Member Functions | Protected Member Functions

KHBox Class Reference

A container widget which arranges its children horizontally. More...

#include <khbox.h>

Inheritance diagram for KHBox:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 KHBox (QWidget *parent=0)
 ~KHBox ()
virtual QSize minimumSizeHint () const
void setMargin (int margin)
void setSpacing (int space)
void setStretchFactor (QWidget *widget, int stretch)
virtual QSize sizeHint () const

Protected Member Functions

 KHBox (bool vertical, QWidget *parent)
virtual void childEvent (QChildEvent *ev)

Detailed Description

A container widget which arranges its children horizontally.

When using a KHBox you don't need to create a layout nor to add the child widgets to it.

Both margin and spacing are initialized to 0. Use QHBoxLayout if you need standard layout margins.

khbox.png

KDE Horizontal Box containing three buttons

See also:
KVBox

Definition at line 40 of file khbox.h.


Constructor & Destructor Documentation

KHBox::KHBox ( QWidget *  parent = 0) [explicit]

Creates a new hbox.

Definition at line 26 of file khbox.cpp.

KHBox::~KHBox ( )

Destructor.

Definition at line 49 of file khbox.cpp.

KHBox::KHBox ( bool  vertical,
QWidget *  parent 
) [protected]

Definition at line 38 of file khbox.cpp.


Member Function Documentation

void KHBox::childEvent ( QChildEvent *  ev) [protected, virtual]

Definition at line 53 of file khbox.cpp.

QSize KHBox::minimumSizeHint ( ) const [virtual]

Calculate the recommended minimum size for this hbox.

Definition at line 90 of file khbox.cpp.

void KHBox::setMargin ( int  margin)

Sets the margin of the hbox.

Definition at line 108 of file khbox.cpp.

void KHBox::setSpacing ( int  space)

Sets the spacing between the child widgets to space.

To get the default layout spacing, set space to -1.

Definition at line 98 of file khbox.cpp.

void KHBox::setStretchFactor ( QWidget *  widget,
int  stretch 
)

Sets the stretch factor of widget to stretch.

Definition at line 103 of file khbox.cpp.

QSize KHBox::sizeHint ( void  ) const [virtual]

Calculate the recommended size for this hbox.

Definition at line 82 of file khbox.cpp.


The documentation for this class was generated from the following files:
  • khbox.h
  • khbox.cpp

KDEUI

Skip menu "KDEUI"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.7.3
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal