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

KDEUI

  • KStyle
  • ToolButton
Public Types | List of all members
KStyle::ToolButton Struct Reference
KStyle widget representation

#include <kstyle.h>

Public Types

enum  LayoutProps {
  ContentsMargin, FocusMargin = ContentsMargin + MarginInc, MenuIndicatorSize, InlineMenuIndicatorSize = FocusMargin + MarginInc,
  InlineMenuIndicatorXOff, InlineMenuIndicatorYOff
}
 
enum  Primitive { Panel }
 

Detailed Description

Describes widgets like QToolButton (usually inside a QToolBar).

The drawing of ToolButton's is much like that of PushButtons; however, in some cases the widget is configured to not have a separate arrow area, but to incorporate the area inside the button itself. To handle this mode, set InlineMenuIndicatorSize to the size of the arrow, and the InlineMenuIndicatorXOff, and InlineMenuIndicatorYOff to offset from the bottom-right corner to place that rectangle. If InlineMenuIndicatorSize isn't set, the arrow won't be drawn.

See also
WT_ToolButton

Definition at line 1388 of file kstyle.h.

Member Enumeration Documentation

enum KStyle::ToolButton::LayoutProps
See also
setWidgetLayoutProp()
Enumerator
ContentsMargin 

(5) Margin reserved around the contents size of a toolbutton.

Used to size the contents.

FocusMargin 

(3) Where the focus rect will be drawn, measured from the widget sides

MenuIndicatorSize 

(11) Size for the separate menu arrows on tool buttons [sets QStyle::PM_MenuButtonIndicator wheen a toolbutton option is passed in]

InlineMenuIndicatorSize 

(0) Size of arrow when it's incorporated into the button directly.

If it's 0, it will not be drawn

Since
4.1
InlineMenuIndicatorXOff 

Horizontal offset off the bottom-right corner to place the arrow if it's incorporated directly, and not in a separate area.

Since
4.1
InlineMenuIndicatorYOff 

Vertical offset off the bottom-right corner to place the arrow if it's incorporated directly, and not in a separate area.

Since
4.1

Definition at line 1393 of file kstyle.h.

enum KStyle::ToolButton::Primitive

Relevant Generic elements:

  • Generic::ArrowDown indicating an associated sub-menu
Todo:
Implement CE_ToolButtonLabel to have own Generic::Text, Generic::Icon, and LayoutProps PressedShiftHorizontal, PressedShiftVertical, TextToIconSpace, MenuIndicatorSize...
See also
drawKStylePrimitive()
Enumerator
Panel 

the toolbutton panel [implements QStyle::PE_PanelButtonTool]

Definition at line 1423 of file kstyle.h.


The documentation for this struct was generated from the following file:
  • kstyle.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:24:03 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KDEUI

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

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • 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

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal