|gtk-hst reference manual|
#include <gtk-hst/function.h> HstFunction; HstFunctionClass; typedef Tuple; typedef PointList;
"range-changed" : Run First
This is an object that wraps a 1D function and a range of validity for that function. The range is defined as an interval of evaluation and the number of points in which the function is evaluated. The range is the basis for defining an axis in a Histogram.
typedef struct _HstFunction HstFunction;
The HstFunction struct contains the following fields. (These fields should be considered read-only. They should never be set by an application.)
|double (*func)(double)||A pointer to a 1D function|
|int nbin||Number of bins|
|gdouble xmin||Minimum value of the X range|
|gdouble xmax||Maximum value of the X range|
|gchar *name||Name of the function|
typedef struct _HstFunctionClass HstFunctionClass;
A HstFunction implements three methods which are used to evaluate the function, to return an array of points in order to draw the function
"func" gpointer : Read / Write
A pointer to a double Hst1DFunction function that is to be evaluated by HstFunction
"name" gchararray : Read / Write
The name of the function.
Default value: "<unnamed>"
"nx" gint : Read / Write
The number of bins in the X axis
Allowed values: [1,999999]
Default value: 10
"range" gpointer : Read / Write
The range of the funtion represents any of nx, xmin, xmax. If any of those change, there will be a range-change notification.
"xmax" gdouble : Read / Write
The maximum value of X definig the range of validity of the function
Default value: 1
"xmin" gdouble : Read / Write
The minimum value of X definig the range of validity of the function
Default value: 0
"xstep" gdouble : Read / Write
step en X.
Default value: 1