GtkDatabox A set of GTK+ widgets to display large amounts of numerical data quickly and easily.

- Main Page
- Data Structures
- Files

- File List
- Globals

Data Structures | Defines | Typedefs | Functions
gtk/gtkdatabox_graph.h File Reference
`#include <gtk/gtkstyle.h>`
`#include <gdk/gdk.h>`
`#include <pango/pango.h>`
`#include <gtkdatabox.h>`
Include dependency graph for gtkdatabox_graph.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Data Structures
struct | _GtkDataboxGraph
struct | _GtkDataboxGraphClass
## Defines
#define | GTK_DATABOX_TYPE_GRAPH (gtk_databox_graph_get_type ())
#define | GTK_DATABOX_GRAPH(obj)
#define | GTK_DATABOX_GRAPH_CLASS(klass)
#define | GTK_DATABOX_IS_GRAPH(obj)
#define | GTK_DATABOX_IS_GRAPH_CLASS(klass)
#define | GTK_DATABOX_GRAPH_GET_CLASS(obj)
## Typedefs
typedef struct _GtkDataboxGraphClass | GtkDataboxGraphClass
typedef struct _GtkDataboxGraphPrivate | GtkDataboxGraphPrivate
## Functions
GType | gtk_databox_graph_get_type (void)
GdkGC * | gtk_databox_graph_get_gc (GtkDataboxGraph *graph)
void | gtk_databox_graph_set_gc (GtkDataboxGraph *graph, GdkGC *gc)
void | gtk_databox_graph_set_hide (GtkDataboxGraph *graph, gboolean hide)
gboolean | gtk_databox_graph_get_hide (GtkDataboxGraph *graph)
void | gtk_databox_graph_set_color (GtkDataboxGraph *graph, GdkColor *color)
GdkColor * | gtk_databox_graph_get_color (GtkDataboxGraph *graph)
void | gtk_databox_graph_set_size (GtkDataboxGraph *graph, gint size)
gint | gtk_databox_graph_get_size (GtkDataboxGraph *graph)
gint | gtk_databox_graph_calculate_extrema (GtkDataboxGraph *graph, gfloat *min_x, gfloat *max_x, gfloat *min_y, gfloat *max_y)
void | gtk_databox_graph_draw (GtkDataboxGraph *graph, GtkDatabox *box)
GdkGC * | gtk_databox_graph_create_gc (GtkDataboxGraph *graph, GtkDatabox *box)

## Define Documentation

#define GTK_DATABOX_GRAPH | ( |  | obj | ) |

Value:

    (G_TYPE_CHECK_INSTANCE_CAST ((obj), \
                                               GTK_DATABOX_TYPE_GRAPH, \
                                               GtkDataboxGraph))

#define GTK_DATABOX_GRAPH_CLASS | ( |  | klass | ) |

Value:

    (G_TYPE_CHECK_CLASS_CAST ((klass), \
                                               GTK_DATABOX_TYPE_GRAPH, \
                                               GtkDataboxGraphClass))

#define GTK_DATABOX_GRAPH_GET_CLASS | ( |  | obj | ) |

Value:

    (G_TYPE_INSTANCE_GET_CLASS ((obj), \
                                               GTK_DATABOX_TYPE_GRAPH, \
                                               GtkDataboxGraphClass))

#define GTK_DATABOX_IS_GRAPH | ( |  | obj | ) |

Value:

    (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
                                               GTK_DATABOX_TYPE_GRAPH))

#define GTK_DATABOX_IS_GRAPH_CLASS | ( |  | klass | ) |

Value:

    (G_TYPE_CHECK_CLASS_TYPE ((klass), \
                                               GTK_DATABOX_TYPE_GRAPH))

#define GTK_DATABOX_TYPE_GRAPH (gtk_databox_graph_get_type ())

SECTION:gtkdatabox_graph : An abstract anchestor for all "real" graphs. gtkdatabox_graph.h : GtkDatabox, GtkDataboxPoints, GtkDataboxLines, GtkDataboxBars, GtkDataboxGrid, GtkDataboxCrossSimple

GtkDataboxGraphs can display data or other things in a GtkDatabox widget.

This class is just the basic interface. Other graph classes are derived from this class and implement some real things.

## Typedef Documentation

typedef struct _GtkDataboxGraphClass GtkDataboxGraphClass

typedef struct _GtkDataboxGraphPrivate GtkDataboxGraphPrivate

GtkDataboxGraphPrivate

A private data structure used by the GtkDataboxGraph. It shields all internal things from developers who are just using the object.

## Function Documentation

gint gtk_databox_graph_calculate_extrema | ( | GtkDataboxGraph * | graph,
|  | gfloat * | min_x,
|  | gfloat * | max_x,
|  | gfloat * | min_y,
|  | gfloat * | max_y
| ) |  |

gtk_databox_graph_calculate_extrema: : A GtkDataboxGraph object : Will be filled with the lowest x value of the dataset : Will be filled with the highest x value of the dataset : Will be filled with the lowest y value of the dataset : Will be filled with the highest y value of the dataset

Virtual function which determines the minimum and maximum x and y values of the values of this GtkDataboxGraph object if applicable (there are graphs which do not contain data).

Return value: 0 on success, -1 if no data is available,

Here is the caller graph for this function:

GdkGC* gtk_databox_graph_create_gc | ( | GtkDataboxGraph * | graph,
|  | GtkDatabox * | box
| ) |  |

gtk_databox_graph_create_gc: : A GtkDataboxGraph object : A GtkDatabox object

Virtual function which creates a graphics context for the .

Typically called by derived graph objects when the graphics context is needed for the first time.

Return value: The new graphics context.

void gtk_databox_graph_draw | ( | GtkDataboxGraph * | graph,
|  | GtkDatabox * | box
| ) |  |

gtk_databox_graph_draw: : A GtkDataboxGraph object : A GtkDatabox object

Virtual function which draws the GtkDataboxGraph on the drawing area of the GtkDatabox object.

Typically this function is called by GtkDatabox objects.

GdkColor* gtk_databox_graph_get_color | ( | GtkDataboxGraph * | graph | ) |

gtk_databox_graph_get_color: : A GtkDataboxGraph object

Gets the current color of the graph elements (e.g. points).

Return value: The color of the graph.

GdkGC* gtk_databox_graph_get_gc | ( | GtkDataboxGraph * | graph | ) |

gtk_databox_graph_get_gc: : A GtkDataboxGraph object

Gets the current graphics context of the graph.

Return value: The current graphics context of the graph.

gboolean gtk_databox_graph_get_hide | ( | GtkDataboxGraph * | graph | ) |

gtk_databox_graph_get_hide: : A GtkDataboxGraph object

Gets the current "hide" status.

Return value: Whether the graph is hidden (true) or not (false).

gint gtk_databox_graph_get_size | ( | GtkDataboxGraph * | graph | ) |

gtk_databox_graph_get_size: : A GtkDataboxGraph object

Gets the size of the graph elements (e.g. the line width).

Return value: size of the graph elements

GType gtk_databox_graph_get_type | ( | void |  | ) |

void gtk_databox_graph_set_color | ( | GtkDataboxGraph * | graph,
|  | GdkColor * | color
| ) |  |

gtk_databox_graph_set_color: : A GtkDataboxGraph object : Color which is to be used by the graph object

Sets the color which the GtkDataboxGraph object is supposed to be using when drawing itself.

void gtk_databox_graph_set_gc | ( | GtkDataboxGraph * | graph,
|  | GdkGC * | gc
| ) |  |

gtk_databox_graph_set_gc: : A GtkDataboxGraph object : Graphics contex for the graph object

Sets the graphics context which the GtkDataboxGraph object is supposed to be using when drawing itself.

void gtk_databox_graph_set_hide | ( | GtkDataboxGraph * | graph,
|  | gboolean | hide
| ) |  |

gtk_databox_graph_set_hide: : A GtkDataboxGraph object : Declares whether should be hidden (true) or not (false).

Hidden graphs are not shown, when the GtkDatabox containing them is redrawn.

void gtk_databox_graph_set_size | ( | GtkDataboxGraph * | graph,
|  | gint | size
| ) |  |

gtk_databox_graph_set_size: : A GtkDataboxGraph object : Size of graph elements for the graph object

Sets the size (e.g. line width) which the GtkDataboxGraph object is supposed to be using when drawing itself.

All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines