11.104Class GtkRuler

Base class for horizontal or vertical rulers

Class GtkRuler

Note: This widget is considered too specialized/little-used for GTK+, and will in the future be moved to some other package. If your application needs this widget, feel free to use it, as the widget does work and is useful in some applications; it's just not of general interest. However, we are not accepting new features for the widget, and it will eventually move out of the GTK+ distribution.

The GTKRuler widget is a base class for horizontal and vertical rulers. Rulers are used to show the mouse pointer's location in a window. The ruler can either be horizontal or vertical on the window. Within the ruler a small triangle indicates the location of the mouse relative to the horizontal or vertical ruler. See GtkHRuler to learn how to create a new horizontal ruler. See GtkVRuler to learn how to create a new vertical ruler.

Methods
get_metricGets the units used for a GtkRuler.
get_rangeRetrieves values indicating the range and current position of a GtkRuler.
set_metricThis calls the GTKMetricType to set the ruler to units defined.
set_rangeThis sets the range of the ruler.

Methods

get_metric

Gets the units used for a GtkRuler.

GtkRuler.get_metric()
Returnthe units currently used for ruler

get_range

Retrieves values indicating the range and current position of a GtkRuler.

GtkRuler.get_range()
Return[ lower, upper, position, max_size ]

set_metric

This calls the GTKMetricType to set the ruler to units defined.

GtkRuler.set_metric( metric )
metric the unit of measurement

Available units are GTK_PIXELS, GTK_INCHES, or GTK_CENTIMETERS. The default unit of measurement is GTK_PIXELS.

set_range

This sets the range of the ruler.

GtkRuler.set_range( lower, upper, position, max_size )
lower the lower limit of the ruler
upper the upper limit of the ruler
position the mark on the ruler
max_size the maximum size of the ruler used when calculating the space to leave for the text
Made with http://www.falconpl.org