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

void range_entry_value_set ( Plot plot  ) 

Put values in the range dialog entry boxes.

Parameters:
plot The Plot for which the ranges are to be set.

Definition at line 761 of file axis.c.

References axis_type_set_toggle(), _Plot::x_axis, _Plot::x_range, _Plot::y_axis, and _Plot::y_range.

Referenced by axis_set_from_dialog(), and range_dialog_create().

{
  gchar xmin_str[RANGE_VAL_SIZE];
  gchar xmax_str[RANGE_VAL_SIZE];
  gchar ymin_str[RANGE_VAL_SIZE];
  gchar ymax_str[RANGE_VAL_SIZE];

  g_snprintf(xmin_str, RANGE_VAL_SIZE, "%f", plot->x_range[0]);
  gtk_entry_set_text(GTK_ENTRY(entry_xmin), xmin_str);

  g_snprintf(xmax_str, RANGE_VAL_SIZE, "%f", plot->x_range[1]);
  gtk_entry_set_text(GTK_ENTRY(entry_xmax), xmax_str);

  g_snprintf(ymin_str, RANGE_VAL_SIZE, "%f", plot->y_range[0]);
  gtk_entry_set_text(GTK_ENTRY(entry_ymin), ymin_str);

  g_snprintf(ymax_str, RANGE_VAL_SIZE, "%f", plot->y_range[1]);
  gtk_entry_set_text(GTK_ENTRY(entry_ymax), ymax_str);

  axis_type_set_toggle(plot->x_axis, GTK_TOGGLE_BUTTON(radio_xtype_linear),
                       GTK_TOGGLE_BUTTON(radio_xtype_log));
  axis_type_set_toggle(plot->y_axis, GTK_TOGGLE_BUTTON(radio_ytype_linear),
                       GTK_TOGGLE_BUTTON(radio_ytype_log));
}


Generated by  Doxygen 1.6.0   Back to index