dia r4246 - in trunk: . objects/Misc
- From: hans svn gnome org
- To: svn-commits-list gnome org
- Subject: dia r4246 - in trunk: . objects/Misc
- Date: Sat, 31 Jan 2009 21:29:39 +0000 (UTC)
Author: hans
Date: Sat Jan 31 21:29:39 2009
New Revision: 4246
URL: http://svn.gnome.org/viewvc/dia?rev=4246&view=rev
Log:
2009-01-31 Hans Breuer <hans breuer org>
* objects/Misc/grid_object.c : give ranges to rows/columns properties
to avoid crashing on negative numbers, similar for line_width
Modified:
trunk/ChangeLog
trunk/objects/Misc/grid_object.c
Modified: trunk/objects/Misc/grid_object.c
==============================================================================
--- trunk/objects/Misc/grid_object.c (original)
+++ trunk/objects/Misc/grid_object.c Sat Jan 31 21:29:39 2009
@@ -127,6 +127,8 @@
(ApplyPropertiesListFunc) object_apply_props,
};
+static PropNumData rows_columns_range = { 1, G_MAXINT, 1 };
+
static PropDescription grid_object_props[] = {
ELEMENT_COMMON_PROPERTIES,
PROP_STD_LINE_WIDTH,
@@ -135,13 +137,13 @@
PROP_STD_SHOW_BACKGROUND,
{ "grid_rows", PROP_TYPE_INT, PROP_FLAG_VISIBLE,
- N_("Rows"), NULL, NULL },
+ N_("Rows"), NULL, &rows_columns_range },
{ "grid_cols", PROP_TYPE_INT, PROP_FLAG_VISIBLE,
- N_("Columns"), NULL, NULL },
+ N_("Columns"), NULL, &rows_columns_range },
{ "gridline_colour", PROP_TYPE_COLOUR, PROP_FLAG_VISIBLE,
N_("Gridline color"), NULL, NULL },
{ "gridline_width", PROP_TYPE_REAL, PROP_FLAG_VISIBLE,
- N_("Gridline width"), NULL,NULL },
+ N_("Gridline width"), NULL, &prop_std_line_width_data },
{NULL}
};
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]