ScrollBar Class Reference
from PyKDE4.plasma import *
Inherits: QGraphicsProxyWidget → QGraphicsWidget → QObject
Namespace: Plasma
Detailed Description
ScrollBar plasma/widgets/scrollbar.h <Plasma/Widgets/ScrollBar>
Provides a plasma-themed QScrollBar.
Signals |
| sliderMoved (int value) |
| valueChanged (int value) |
Methods |
| __init__ (self, QGraphicsWidget parent=0) |
| contextMenuEvent (self, QGraphicsSceneContextMenuEvent event) |
int | maximum (self) |
int | minimum (self) |
QScrollBar | nativeWidget (self) |
Qt::Orientation | orientation (self) |
int | pageStep (self) |
| setMaximum (self, int max) |
| setMinimum (self, int min) |
| setOrientation (self, Qt::Orientation orientation) |
| setPageStep (self, int val) |
| setRange (self, int min, int max) |
| setSingleStep (self, int val) |
| setStyleSheet (self, QString stylesheet) |
| setValue (self, int val) |
int | singleStep (self) |
QString | styleSheet (self) |
int | value (self) |
Signal Documentation
sliderMoved |
( |
int |
value |
|
) |
|
|
|
Emitted when the slider has been moved by the user
- Since:
- 4.6
- Signal syntax:
QObject.connect(source, SIGNAL("sliderMoved(int)"), target_slot)
valueChanged |
( |
int |
value |
|
) |
|
|
|
Emitted when the value of the slider changes
- Signal syntax:
QObject.connect(source, SIGNAL("valueChanged(int)"), target_slot)
Method Documentation
__init__ |
( |
self, |
|
|
|
QGraphicsWidget |
parent=0 |
|
) |
|
|
|
Creates a scrollbar; the default orientation is vertical
contextMenuEvent |
( |
self, |
|
|
|
QGraphicsSceneContextMenuEvent |
event |
|
) |
|
|
|
- Returns:
- the maximum value bound of this ScrollBar
- Returns:
- the minimum value bound of this ScrollBar
QScrollBar nativeWidget |
( |
|
self ) |
|
- Returns:
- the native widget wrapped by this ScrollBar
- Returns:
- the orientation of the scrollbar
- Since:
- 4.4
- Returns:
- the amount of the page step
setMaximum |
( |
self, |
|
|
|
int |
max |
|
) |
|
|
|
- Parameters:
-
| the | maximum value bound of this ScrollBar
|
- Since:
- 4.6
setMinimum |
( |
self, |
|
|
|
int |
min |
|
) |
|
|
|
- Parameters:
-
| the | minimum value bound of this ScrollBar
|
- Since:
- 4.6
Sets the orientation of the ScrollBar.
setPageStep |
( |
self, |
|
|
|
int |
val |
|
) |
|
|
|
Sets the amount the slider will scroll when the user press page up or page down
- Parameters:
-
setRange |
( |
self, |
|
|
|
int |
min, |
|
|
int |
max |
|
) |
|
|
|
Sets the scrollbar minimum and maximum values
- Parameters:
-
| min | minimum value
|
| max | maximum value
|
setSingleStep |
( |
self, |
|
|
|
int |
val |
|
) |
|
|
|
Sets the amount of the single step
i.e how much the slider will move when the user press an arrow button
- Parameters:
-
setStyleSheet |
( |
self, |
|
|
|
QString |
stylesheet |
|
) |
|
|
|
Sets the stylesheet used to control the visual display of this ScrollBar
- Parameters:
-
setValue |
( |
self, |
|
|
|
int |
val |
|
) |
|
|
|
Sets the current value for the ScrollBar
- Parameters:
-
| value | must be minimum() <= value <= maximum()
|
- Returns:
- the amount of the single step
QString styleSheet |
( |
|
self ) |
|
- Returns:
- the stylesheet currently used with this widget
- Returns:
- the current scrollbar value