From c72722df8ce3d3c91a26b8fc41cb7af9c6b6d864 Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Thu, 11 Dec 2008 11:49:14 +0000 Subject: [PATCH] Add :cursor-color-set property declaration The :cursor-color-set property is a read-only property that reflects whether the ClutterText actor is going to use the color set inside the :cursor-color property when painting the cursor. --- clutter/clutter-text.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/clutter/clutter-text.c b/clutter/clutter-text.c index 43ab3a2d1..8395266eb 100644 --- a/clutter/clutter-text.c +++ b/clutter/clutter-text.c @@ -702,6 +702,10 @@ clutter_text_get_property (GObject *gobject, clutter_value_set_color (value, &priv->cursor_color); break; + case PROP_CURSOR_COLOR_SET: + g_value_set_boolean (value, priv->cursor_color_set); + break; + case PROP_POSITION: g_value_set_int (value, CLUTTER_FIXED_TO_FLOAT (priv->position)); break; @@ -1215,12 +1219,19 @@ clutter_text_class_init (ClutterTextClass *klass) g_object_class_install_property (gobject_class, PROP_CURSOR_VISIBLE, pspec); pspec = clutter_param_spec_color ("cursor-color", - "Cursor Colour", - "Cursor Colour", + "Cursor Color", + "Cursor Color", &default_cursor_color, CLUTTER_PARAM_READWRITE); g_object_class_install_property (gobject_class, PROP_CURSOR_COLOR, pspec); + pspec = g_param_spec_boolean ("cursor-color-set", + "Cursor Color Set", + "Whether the cursor color has been set", + FALSE, + CLUTTER_PARAM_READABLE); + g_object_class_install_property (gobject_class, PROP_CURSOR_COLOR_SET, pspec); + /** * ClutterText:position: *