gtk.Curve()
def reset()
def set_gamma(gamma
)
def set_range(min_x
, max_x
, min_y
, max_y
)
def get_vector(size
=1)
def set_vector(vector
)
def set_curve_type(type
)

gtk.Curve()
def reset()
def set_gamma(gamma
)
def set_range(min_x
, max_x
, min_y
, max_y
)
def get_vector(size
=1)
def set_vector(vector
)
def set_curve_type(type
)

def callback( 
This widget is considered too specialized or littleused for PyGTK, 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, it will eventually move out of the PyGTK distribution.
The gtk.Curve
widget
allows the user to edit a curve covering a range of values. It is typically
used to finetune color balances in graphics applications like the
Gimp. The gtk.Curve
widget has
3 modes of operation  spline, linear and free. In spline mode the user
places points on the curve which are automatically connected together into a
smooth curve. In linear mode the user places points on the curve which are
connected by straight lines. In free mode the user can draw the points of
the curve freely, and they are not connected at all.
def reset()
The reset
() method resets the curve to
a straight line from the minimum x and y values to the maximum x and y
values (i.e. from the bottomleft to the topright corners). The curve type
is not changed.
def set_gamma(gamma
)
 the gamma value 
The set_gamma
() method recomputes the
entire curve using the value in gamma
. A gamma value
of 1 results in a straight line. Values greater than 1 result in a curve
above the straight line. Values less than 1 result in a curve below the
straight line. The curve type is changed to
gtk.CURVE_TYPE_FREE
.
def set_range(min_x
, max_x
, min_y
, max_y
)
 the new minimum x value 
 the maximum x value. 
 the new minimum y value 
 the maximum y value. 
The set_range
() method sets the
"minx", "miny", "maxx" and "maxy" properties from
min_x
, min_y
,
max_x
, and max_y
. The curve is also reset
with a call to reset
().
def set_vector(size
=1)
 the number of points to return or 1 to return all the points in the curve. 
Returns :  a tuple containing the points 
The get_vector
() method returns a tuple
of points representing the curve. The number of points to return is
specified by size
; if size
is
1 all the points in the curve are returned.
def get_vector(vector
)
 a list or tuple containing the points of the curve 
The set_vector
() method sets the curve
using the points in vector
. The curve type is set to
gtk.CURVE_TYPE_FREE
.
def set_curve_type(type
)
 the new curve type:
gtk.CURVE_TYPE_LINEAR ,
gtk.CURVE_TYPE_SPLINE or
gtk.CURVE_TYPE_FREE 
The set_curve_type
() method sets the
"curvetype" property with the value of type
. The
curve type must be one of gtk.CURVE_TYPE_LINEAR
,
gtk.CURVE_TYPE_SPLINE
or
gtk.CURVE_TYPE_FREE
. The curve will remain unchanged
except when changing from a free curve to a linear or spline curve, in which
case the curve will be changed as little as possible.
def callback(curve
, user_param1
, ...
)
 the curve that received the signal 
 the first user parameter (if any) specified
with the connect () 
 additional user parameters (if any) 
The "curvetypechanged" signal is emitted when the curve type
has been changed. The curve type can be changed explicitly with a call to
set_curve_type
().
It is also changed as a sideeffect of calling reset
() or
set_gamma
()
© manpagez.com 20002024 Individual documents may contain additional copyright information.