GwyColorAxis

GwyColorAxis — Simple axis with a false color scale

Synopsis




struct      GwyColorAxisParams;
struct      GwyColorAxis;
struct      GwyColorAxisClass;
GtkWidget*  gwy_color_axis_new              (GtkOrientation orientation,
                                             gdouble min,
                                             gdouble max,
                                             GwyPalette *pal);
GtkWidget*  gwy_color_axis_new_default      (GtkOrientation orientation);
void        gwy_color_axis_get_range        (GwyColorAxis *axis,
                                             gdouble *min,
                                             gdouble *max);
void        gwy_color_axis_set_range        (GwyColorAxis *axis,
                                             gdouble min,
                                             gdouble max);
GwySIUnit*  gwy_color_axis_get_si_unit      (GwyColorAxis *axis);
void        gwy_color_axis_set_si_unit      (GwyColorAxis *axis,
                                             GwySIUnit *unit);
void        gwy_color_axis_set_gradient     (GwyColorAxis *axis,
                                             const gchar *gradient);
const gchar* gwy_color_axis_get_gradient    (GwyColorAxis *axis);
void        gwy_color_axis_set_unit         (GwyColorAxis *axis,
                                             GwySIUnit *unit);
void        gwy_color_axis_set_palette      (GwyColorAxis *axis,
                                             GwyPalette *pal);
GwyPalette* gwy_color_axis_get_palette      (GwyColorAxis *axis);

Object Hierarchy


  GObject
   +----GtkObject
         +----GtkWidget
               +----GwyColorAxis

Implemented Interfaces

GwyColorAxis implements AtkImplementorIface.

Description

Details

struct GwyColorAxisParams

struct GwyColorAxisParams {

    gint tick_length;
    gint textarea;    /*text area width*/

    PangoFontDescription *font;
};


struct GwyColorAxis

struct GwyColorAxis;


struct GwyColorAxisClass

struct GwyColorAxisClass {

    GtkWidgetClass parent_class;

    gpointer reserved1;
    gpointer reserved2;
};


gwy_color_axis_new ()

GtkWidget*  gwy_color_axis_new              (GtkOrientation orientation,
                                             gdouble min,
                                             gdouble max,
                                             GwyPalette *pal);

Creates a new color axis.

orientation : The orientation of the axis.
min : The minimum.
max : The maximum.
pal : The palette the color axis should use.
Returns : The newly created color axis as a GtkWidget.

gwy_color_axis_new_default ()

GtkWidget*  gwy_color_axis_new_default      (GtkOrientation orientation);

orientation :
Returns :

gwy_color_axis_get_range ()

void        gwy_color_axis_get_range        (GwyColorAxis *axis,
                                             gdouble *min,
                                             gdouble *max);

Gets the range of color axis axis.

axis : A color axis.
min : Where the range maximum should be stored (or NULL).
max : Where the range minimum should be stored (or NULL).

gwy_color_axis_set_range ()

void        gwy_color_axis_set_range        (GwyColorAxis *axis,
                                             gdouble min,
                                             gdouble max);

Sets the range for color axis axis to [min, max].

axis : A color axis.
min : The minimum.
max : The maximum.

gwy_color_axis_get_si_unit ()

GwySIUnit*  gwy_color_axis_get_si_unit      (GwyColorAxis *axis);

Returns the SI unit a color axis displays.

axis : A color axis.
Returns : The SI unit.

Since 1.8


gwy_color_axis_set_si_unit ()

void        gwy_color_axis_set_si_unit      (GwyColorAxis *axis,
                                             GwySIUnit *unit);

axis :
unit :

gwy_color_axis_set_gradient ()

void        gwy_color_axis_set_gradient     (GwyColorAxis *axis,
                                             const gchar *gradient);

Sets the color gradient a color axis should use.

axis : A color axis.
gradient : Name of gradient axis should use. It should exist.

Since 1.8


gwy_color_axis_get_gradient ()

const gchar* gwy_color_axis_get_gradient    (GwyColorAxis *axis);

Returns the color gradient a color axis uses.

axis : A color axis.
Returns : The color gradient.

Since 1.8


gwy_color_axis_set_unit ()

void        gwy_color_axis_set_unit         (GwyColorAxis *axis,
                                             GwySIUnit *unit);

Warning

gwy_color_axis_set_unit is deprecated and should not be used in newly-written code.

Sets the SI unit a color axis should display next to values.

axis : A color axis.
unit : An SI unit.

Since 1.8


gwy_color_axis_set_palette ()

void        gwy_color_axis_set_palette      (GwyColorAxis *axis,
                                             GwyPalette *pal);

Warning

gwy_color_axis_set_palette is deprecated and should not be used in newly-written code.

Sets the palette for color axis axis to pal.

axis : A color axis.
pal : A palette.

gwy_color_axis_get_palette ()

GwyPalette* gwy_color_axis_get_palette      (GwyColorAxis *axis);

Warning

gwy_color_axis_get_palette is deprecated and should not be used in newly-written code.

Returns the palette the color axis axis uses.

axis : A color axis.
Returns : The palette, as GwyPalette.