diff options
author | Matthias Clasen <matthiasc@src.gnome.org> | 2002-11-08 22:38:13 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2002-11-08 22:38:13 +0000 |
commit | 8f5c388b976e98dfff62c6332a3582dc9688b93f (patch) | |
tree | 0649904a2d5ea0cc5cba508bd371782a3517e813 /gtk/gtkcheckmenuitem.c | |
parent | 2d1ce5a4fb9da6f0f26bd658310cf057eb08bf8b (diff) | |
download | gtk+-8f5c388b976e98dfff62c6332a3582dc9688b93f.tar.gz |
RTL flipping for check menu items.
* gtk/gtkcheckmenuitem.c
(gtk_real_check_menu_item_draw_indicator): RTL flipping for check
menu items.
Diffstat (limited to 'gtk/gtkcheckmenuitem.c')
-rw-r--r-- | gtk/gtkcheckmenuitem.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/gtk/gtkcheckmenuitem.c b/gtk/gtkcheckmenuitem.c index 7c1ee30a71..daf6a37259 100644 --- a/gtk/gtkcheckmenuitem.c +++ b/gtk/gtkcheckmenuitem.c @@ -348,6 +348,7 @@ gtk_real_check_menu_item_draw_indicator (GtkCheckMenuItem *check_menu_item, GtkShadowType shadow_type; gint width, height; gint x, y; + gint offset; if (GTK_WIDGET_DRAWABLE (check_menu_item)) { @@ -355,8 +356,12 @@ gtk_real_check_menu_item_draw_indicator (GtkCheckMenuItem *check_menu_item, width = 8; height = 8; - x = widget->allocation.x + (GTK_CONTAINER (check_menu_item)->border_width + - widget->style->xthickness + 2); + offset = GTK_CONTAINER (check_menu_item)->border_width + + widget->style->xthickness + 2; + if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR) + x = widget->allocation.x + offset; + else + x = widget->allocation.x + widget->allocation.width - width - offset; y = widget->allocation.y + (widget->allocation.height - height) / 2; if (check_menu_item->active || |