Home | Trees | Index | Help |
|
---|
Package stripchart :: Module vgrade :: Class VGrade |
|
Widget that shows a zoomable, scrollable vertical scale.
This class is a composite megawidget in the form of a graduated, interactive vertical numerical scale that is both zoomable and scrollable. The zoom is adjusted by dragging in the scale region of the widget to the left, whereas the widget can be scrolled by dragging in the trackbar on the right. Both regions of the widget hilight when the mouse is moved over them, to hint to the user that interaction is possible.
The widget is composed of a VGradeZoom
widget and a
gtk.DrawingArea
widget. These widgets are packaged within a
gtk.HBox
widget.
The data model of the VGrade
widget is a
gtk.Adjustment
object. The interpretation of the adjustment
is as follows: The
value
of the adjustment
is the minimum value displayed
on the widget. The maximum value displayed on the widget is the
value
plus the page_size
of the adjustment
. The widget will not allow the
user to change the adjustment
so that any part of the display
lies outside the range from the lower
to upper
values of the adjustment
.
gtk.HBox
widget container can be accessed
via the special widget
attribute. This attribute cannot be
changed nor deleted.
See Also: VGradeZoom
Method Summary | |
---|---|
Initializes the widget. | |
Delete attributes method. | |
Get attributes method. | |
Set attributes method. | |
Set the adjustment used as the data model. | |
Handles the expose event for the dragbar. | |
Handles notification of mouse motion within the dragbar. | |
Handler for dragbar mouse button press events. | |
Handler for dragbar mouse button release events. | |
Handler for enter events on the dragbar. | |
Initializes the GC for drawing the dragbar. | |
Handler for leave events on the dragbar. | |
Sets the color of the drag bar. |
Instance Variable Summary | |
---|---|
gtk.Adjustment |
adjustment : Adjustment data model for controlling the range of the widget. |
gtk.HBox |
widget : Read-only pseudo-parent widget. |
Method Details |
---|
__init__(self,
adjustment=None)
Initializes the widget.
|
__delattr__(self, name)Delete attributes method. |
__getattr__(self,
name)
Get attributes method.
|
__setattr__(self, name, value)Set attributes method. |
set_adjustment(self, adjustment)Set the adjustment used as the data model. If object.adjustment = adjustmentEG: >>> import gtk, vgrade >>> v = vgrade.VGrade() >>> a1 = gtk.Adjustment() >>> a2 = gtk.Adjustment() >>> v.set_adjustment(a1) >>> v.adjustment is a1 1 >>> v.adjustment = a2 >>> v.adjustment is a2 1 >>> v.adjustment is a1 0
|
__bar_expose_handler(self, widget, event)Handles the expose event for the dragbar. |
__bar_motion_notify_handler(self, widget, event)Handles notification of mouse motion within the dragbar. |
__button_press_handler(self, widget, event)Handler for dragbar mouse button press events. |
__button_release_handler(self, widget, event)Handler for dragbar mouse button release events. |
__enter_notify_handler(self, widget, event)Handler for enter events on the dragbar. |
__init_barGC(self)Initializes the GC for drawing the dragbar. |
__leave_notify_handler(self, widget, event)Handler for leave events on the dragbar. |
__set_bar_color(self, color)Sets the color of the drag bar. This method is used internally within the class to cause hilighting of the drag bar and is not intended for general use.
|
Instance Variable Details |
---|
adjustmentAdjustment data model for controlling the range of the widget.
|
widgetRead-only pseudo-parent widget.
|
Home | Trees | Index | Help |
|
---|
Generated by Epydoc 2.0 on Sat Oct 25 11:04:43 2003 | http://epydoc.sf.net |