Logo Search packages:      
Sourcecode: ygraph version File versions  Download package

GArray* axis_tick_append ( GArray *  ticks,
gdouble  val,
Axis axis,
gboolean  exp_notation 

Add a Tick to an array.

ticks Array of *Ticks.
val The value of the tick mark along the axis.
exp_notation TRUE if the value should be expressed in exponential notation.
The original array with the new tick mark appended.
The tick should be freed when the axis is destroyed.

Definition at line 181 of file axis.c.

References double_to_str(), _Tick::str, and _Tick::val.

Referenced by axis_calc_ticks().

  Tick* tick;
  tick = g_malloc(sizeof(Tick));
  tick->val = axis_transformation_back(val, axis);
  tick->str = double_to_str(tick->val, exp_notation);
  return g_array_append_val(ticks, tick);

Generated by  Doxygen 1.6.0   Back to index