• Skip to content
  • Skip to link menu
KDE 4.1 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

KDEUI

KStyle::PushButton

KStyle::PushButton Struct Reference
[KStyle widget representation]

#include <kstyle.h>

List of all members.


Detailed Description

Describes widgets like QPushButton.

See also:
WT_PushButton

Definition at line 432 of file kstyle.h.


Public Types

enum  LayoutProp {
  ContentsMargin, FocusMargin = ContentsMargin + MarginInc, DefaultIndicatorMargin = FocusMargin + MarginInc, PressedShiftHorizontal = DefaultIndicatorMargin + MarginInc,
  PressedShiftVertical, MenuIndicatorSize, TextToIconSpace
}
enum  Primitive { Panel, DefaultButtonFrame }

Member Enumeration Documentation

enum KStyle::PushButton::LayoutProp

The layout of a PushButton is structured as follows:

  1. Between the very outside and the bevel is the default indicator area, controlled by the PushButton::DefaultIndicatorMargin .

  1. From the bevel, the content and focus rect margins are measured. Only the content margin is used to size the content area.
  2. Inside the content area, PushButton::MenuIndicatorSize is allocated to the down arrow if there is a popup menu.
  3. PushButton::TextToIconSpace is allocated between icon and text if both exist

See also:
setWidgetLayoutProp()
Enumerator:
ContentsMargin  (5) space between the bevel and the button contents
FocusMargin  (3) Used to calculate the area of the focus indicator. Measured from the bevel.
DefaultIndicatorMargin  (0 ?) Default indicator between the very outside and the bevel. KStyle may reserve this for auto-default buttons, too, for consistency's sake. [the MainMargin sets QStyle::PM_ButtonDefaultIndicator]
PressedShiftHorizontal  (2) horizontal contents shift for pressed buttons [sets QStyle::PM_ButtonShiftHorizontal]
PressedShiftVertical  (2) vertical contents shift for pressed buttons [sets QStyle::PM_ButtonShiftVertical]
MenuIndicatorSize  (8) Space inside the content area, which is allocated to the down arrow if there is a popup menu [sets QStyle::PM_MenuButtonIndicator, except for toolbuttons]
TextToIconSpace  (6) space between the icon and the text if both exist

Definition at line 446 of file kstyle.h.

enum KStyle::PushButton::Primitive

Relevant Generic elements:

  • Generic::Text the button's text
  • Generic::FocusIndicator indicating that the button has keyboard focus
  • Generic::ArrowDown indicating that the button has a popup menu associated to it.

[KStyle implements QStyle::CE_PushButtonBevel to compose the primitives]

See also:
drawKStylePrimitive()
Enumerator:
Panel  the pushbutton panel [implements QStyle::PE_PanelButtonCommand]
DefaultButtonFrame  frame indicating a default button, painted before the button Panel [implements QStyle::PE_FrameDefaultButton]

Definition at line 467 of file kstyle.h.


The documentation for this struct was generated from the following file:
  • kstyle.h

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
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • KIO
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • Kross
  • KUtils
  • Nepomuk
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.5.4
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