x-align property
* clutter/clutter-entry.c (clutter_entry_paint): When calculating
the position to draw the cursor at, take into account the
alignment of the text. Queue a redraw when the x-align property is
changed.
+2008-08-18 Neil Roberts <neil@o-hand.com>
+
+ Bug 1085 - Cursor is in wrong position on ClutterEntry if set
+ x-align property
+
+ * clutter/clutter-entry.c (clutter_entry_paint): When calculating
+ the position to draw the cursor at, take into account the
+ alignment of the text. Queue a redraw when the x-align property is
+ changed.
+
2008-08-07 Neil Roberts <neil@o-hand.com>
Bug 1091 - WM_MOUSEWHEEL (scroll-event) not handled correctlly
break;
case PROP_X_ALIGN:
entry->priv->x_align = g_value_get_double (value);
+ clutter_actor_queue_redraw (CLUTTER_ACTOR (object));
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
else
{
priv->text_x = (actor_width - text_width) * priv->x_align;
- priv->cursor_pos.x += priv->entry_padding;
+ priv->cursor_pos.x += priv->text_x + priv->entry_padding;
}
memcpy (&color, &priv->fgcol, sizeof (ClutterColor));