summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCosimo Cecchi <cosimo@endlessm.com>2013-06-18 16:37:31 -0700
committerCosimo Cecchi <cosimo@endlessm.com>2013-06-18 16:40:02 -0700
commit23f9444795d7a3115d187cd0196421c4d642a62f (patch)
tree03d35b1eb5c225bbf5218d88e8bb2027c12594c7
parentf407ddf0d8717cee0ec19f152eef117921e96197 (diff)
downloadclutter-23f9444795d7a3115d187cd0196421c4d642a62f.tar.gz
text: relayout on cursor visibility change
When the cursor visibility changes, we have to relayout the ClutterText actor instead of just redrawing it - as the cursor changes the PangoLayout size, a size request cycle is needed. https://bugzilla.gnome.org/show_bug.cgi?id=702610
-rw-r--r--clutter/clutter-text.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/clutter/clutter-text.c b/clutter/clutter-text.c
index 9b8b14da4..56061259f 100644
--- a/clutter/clutter-text.c
+++ b/clutter/clutter-text.c
@@ -4605,7 +4605,8 @@ clutter_text_set_cursor_visible (ClutterText *self,
{
priv->cursor_visible = cursor_visible;
- clutter_text_queue_redraw (CLUTTER_ACTOR (self));
+ clutter_text_dirty_cache (self);
+ clutter_actor_queue_relayout (CLUTTER_ACTOR (self));
g_object_notify_by_pspec (G_OBJECT (self), obj_props[PROP_CURSOR_VISIBLE]);
}