diff options
author | Jonathan Blandford <jrb@gnome.org> | 2003-03-03 04:51:42 +0000 |
---|---|---|
committer | Jonathan Blandford <jrb@src.gnome.org> | 2003-03-03 04:51:42 +0000 |
commit | 0d93b6432dde93cd3294de90ad250de65cb27a91 (patch) | |
tree | 4b4b8d1e59f96d48c13257a3ceff1357c4910479 /gtk/gtkcellrendererpixbuf.c | |
parent | 770996f94989940311617a58d2c36604081a4e6f (diff) | |
download | gdk-pixbuf-0d93b6432dde93cd3294de90ad250de65cb27a91.tar.gz |
handle rtl code.
Sun Mar 2 23:35:57 2003 Jonathan Blandford <jrb@gnome.org>
* gtk/gtkcellrenderertoggle.c (gtk_cell_renderer_toggle_get_size):
handle rtl code.
* gtk/gtkcellrendererpixbuf.c (gtk_cell_renderer_pixbuf_get_size): ditto
* gtk/gtkcellrenderertext.c (gtk_cell_renderer_text_get_size): ditto
* gtk/gtktreeview.c: (invalidate_column),
(invalidate_last_column),
(gtk_tree_view_get_real_requested_width_from_column),
(gtk_tree_view_size_allocate_columns),
(gtk_tree_view_size_allocate), (gtk_tree_view_button_press),
(gtk_tree_view_button_release_drag_column),
(gtk_tree_view_update_current_reorder),
(gtk_tree_view_motion_drag_column), (gtk_tree_view_bin_expose),
(gtk_tree_view_key_press), (gtk_tree_view_header_focus),
(gtk_tree_view_get_background_xrange),
(gtk_tree_view_get_arrow_xrange),
(gtk_tree_view_is_expander_column),
(gtk_tree_view_set_column_drag_info),
(gtk_tree_view_move_cursor_left_right):
Add RTL support.
* gtk/gtktreeviewcolumn.h (struct _GtkTreeViewColumn): add an
expand flag.
* gtk/gtktreeviewcolumn.c:
(gtk_tree_view_column_class_init),
(gtk_tree_view_column_set_property),
(gtk_tree_view_column_get_property),
(gtk_tree_view_column_set_expand),
(gtk_tree_view_column_get_expand),
(gtk_tree_view_column_cell_process_action):
Add support for expand flag
Diffstat (limited to 'gtk/gtkcellrendererpixbuf.c')
-rw-r--r-- | gtk/gtkcellrendererpixbuf.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk/gtkcellrendererpixbuf.c b/gtk/gtkcellrendererpixbuf.c index d05907bf0..5c4f792cf 100644 --- a/gtk/gtkcellrendererpixbuf.c +++ b/gtk/gtkcellrendererpixbuf.c @@ -382,7 +382,8 @@ gtk_cell_renderer_pixbuf_get_size (GtkCellRenderer *cell, { if (x_offset) { - *x_offset = GTK_CELL_RENDERER (cellpixbuf)->xalign * (cell_area->width - calc_width - (2 * GTK_CELL_RENDERER (cellpixbuf)->xpad)); + *x_offset = ((gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL) ? + (1.0 - GTK_CELL_RENDERER (cellpixbuf)->xalign) : GTK_CELL_RENDERER (cellpixbuf)->xalign) * (cell_area->width - calc_width - (2 * GTK_CELL_RENDERER (cellpixbuf)->xpad)); *x_offset = MAX (*x_offset, 0) + GTK_CELL_RENDERER (cellpixbuf)->xpad; } if (y_offset) |