summaryrefslogtreecommitdiff
path: root/gtk
diff options
context:
space:
mode:
authorDaniel Boles <dboles@src.gnome.org>2017-02-19 08:37:51 +0000
committerDaniel Boles <dboles@src.gnome.org>2017-02-19 08:39:31 +0000
commitebca0c6ebfc46c687c4fa084d4d5a7f49ea4bffe (patch)
tree7f19427cb6cbe80b40d3562b7e5e78ce3f37bf55 /gtk
parent97fe47bbd91b0999e1a10a967d17e39381df2c36 (diff)
downloadgtk+-ebca0c6ebfc46c687c4fa084d4d5a7f49ea4bffe.tar.gz
Scale: Improve docs of prop digits in other places
There were places still implying that it was only used for display.
Diffstat (limited to 'gtk')
-rw-r--r--gtk/gtkscale.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/gtk/gtkscale.c b/gtk/gtkscale.c
index b2e4e19da6..45e51c1691 100644
--- a/gtk/gtkscale.c
+++ b/gtk/gtkscale.c
@@ -759,10 +759,17 @@ gtk_scale_class_init (GtkScaleClass *class)
G_TYPE_STRING, 1,
G_TYPE_DOUBLE);
+ /**
+ * GtkScale:digits:
+ *
+ * The number of decimal places to which the value is rounded when it is
+ * changed. This also sets the number of digits shown in the displayed value
+ * when using the default handler for the #GtkScale:format-value signal.
+ */
properties[PROP_DIGITS] =
g_param_spec_int ("digits",
P_("Digits"),
- P_("The number of decimal places that are displayed in the value"),
+ P_("The number of decimal places to which the value is rounded"),
-1, MAX_DIGITS,
1,
GTK_PARAM_READWRITE|G_PARAM_EXPLICIT_NOTIFY);
@@ -1118,9 +1125,10 @@ gtk_scale_set_digits (GtkScale *scale,
* gtk_scale_get_digits:
* @scale: a #GtkScale
*
- * Gets the number of decimal places that are displayed in the value.
+ * Gets the number of decimal places to which the value is rounded on change.
+ * This number is also used by the default #GtkScale:format-value handler.
*
- * Returns: the number of decimal places that are displayed
+ * Returns: the number of decimal places
*/
gint
gtk_scale_get_digits (GtkScale *scale)