new function xy_plot_get_dimensions

This commit is contained in:
Cedric Roux
2016-05-11 15:34:44 +02:00
parent 029adbf368
commit 70ebbd7e19
2 changed files with 14 additions and 0 deletions
+13
View File
@@ -272,3 +272,16 @@ void xy_plot_set_points(gui *_gui, widget *_this, int plot,
gunlock(g);
}
void xy_plot_get_dimensions(gui *_gui, widget *_this, int *width, int *height)
{
struct gui *g = _gui;
struct xy_plot_widget *this = _this;
glock(g);
*width = this->common.width - this->vrule_width;
*height = this->common.height - this->label_height * 2;
gunlock(g);
}