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.
This commit is contained in:
Emmanuele Bassi 2008-12-11 11:49:14 +00:00
parent bdb0cc462d
commit c72722df8c

View File

@ -702,6 +702,10 @@ clutter_text_get_property (GObject *gobject,
clutter_value_set_color (value, &priv->cursor_color); clutter_value_set_color (value, &priv->cursor_color);
break; break;
case PROP_CURSOR_COLOR_SET:
g_value_set_boolean (value, priv->cursor_color_set);
break;
case PROP_POSITION: case PROP_POSITION:
g_value_set_int (value, CLUTTER_FIXED_TO_FLOAT (priv->position)); g_value_set_int (value, CLUTTER_FIXED_TO_FLOAT (priv->position));
break; break;
@ -1215,12 +1219,19 @@ clutter_text_class_init (ClutterTextClass *klass)
g_object_class_install_property (gobject_class, PROP_CURSOR_VISIBLE, pspec); g_object_class_install_property (gobject_class, PROP_CURSOR_VISIBLE, pspec);
pspec = clutter_param_spec_color ("cursor-color", pspec = clutter_param_spec_color ("cursor-color",
"Cursor Colour", "Cursor Color",
"Cursor Colour", "Cursor Color",
&default_cursor_color, &default_cursor_color,
CLUTTER_PARAM_READWRITE); CLUTTER_PARAM_READWRITE);
g_object_class_install_property (gobject_class, PROP_CURSOR_COLOR, pspec); 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: * ClutterText:position:
* *