Index: evolution/widgets/misc/e-calendar-item.c
===================================================================
RCS file: /cvs/gnome/evolution/widgets/misc/e-calendar-item.c,v
retrieving revision 1.50
diff -u -p -r1.50 e-calendar-item.c
--- evolution/widgets/misc/e-calendar-item.c	4 May 2006 15:25:13 -0000	1.50
+++ evolution/widgets/misc/e-calendar-item.c	12 Jun 2006 17:39:31 -0000
@@ -1693,7 +1693,8 @@ e_calendar_item_draw_month	(ECalendarIte
 
 	/* Calculate the top-left position of the entire month display. */
 	month_x = item->x1 + xthickness + calitem->x_offset
-		+ col * calitem->month_width - x;
+		+ ( (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+		? (calitem->cols-1 - col) : col ) * calitem->month_width - x;
 	month_w = item->x2 - item->x1 - xthickness * 2;
 	month_w = MIN (month_w, calitem->month_width);
 	month_y = item->y1 + ythickness + row * calitem->month_height - y;
@@ -1809,6 +1810,8 @@ e_calendar_item_draw_month	(ECalendarIte
 
 	day_index = calitem->week_start_day;
 	pango_layout_set_font_description (layout, font_desc);
+	if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+		text_x += (7-1) * calitem->cell_width;
 	gdk_gc_set_foreground (fg_gc, &style->text[GTK_STATE_ACTIVE]);
 	for (day = 0; day < 7; day++) {
 		layout_set_day_text (calitem, layout, day_index);
@@ -1816,7 +1819,8 @@ e_calendar_item_draw_month	(ECalendarIte
 				 text_x - calitem->day_widths [day_index],
 				 text_y,
 				 layout);
-		text_x += calitem->cell_width;
+		text_x += (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+				? -calitem->cell_width : calitem->cell_width;
 		day_index++;
 		if (day_index == 7)
 			day_index = 0;
@@ -2001,7 +2005,10 @@ e_calendar_item_draw_day_numbers (ECalen
 
 		for (dcol = 0; dcol < 7; dcol++) {
 			if (draw_day) {
-				day_x = cells_x + dcol * calitem->cell_width;
+				day_x = cells_x +
+					( (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+					? 7-1 - dcol : dcol ) * calitem->cell_width;
+
 				day_y = cells_y + drow * calitem->cell_height;
 
 				today = years[mon] == today_year
@@ -2868,6 +2875,8 @@ e_calendar_item_convert_position_to_day	
 
 	if (row >= calitem->rows || col >= calitem->cols)
 		return FALSE;
+	if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+		col = calitem->cols-1 - col;
 
 	*month_offset = row * calitem->cols + col;
 
@@ -2912,6 +2921,8 @@ e_calendar_item_convert_position_to_day	
 		if (x < 0)
 			return FALSE;
 		day_col = x / calitem->cell_width;
+		if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+			day_col = E_CALENDAR_COLS_PER_MONTH-1 - day_col;
 		if (day_col >= E_CALENDAR_COLS_PER_MONTH)
 			return FALSE;
 	}
Index: evolution/widgets/misc/e-calendar.c
===================================================================
RCS file: /cvs/gnome/evolution/widgets/misc/e-calendar.c,v
retrieving revision 1.29
diff -u -p -r1.29 e-calendar.c
--- evolution/widgets/misc/e-calendar.c	27 Apr 2006 09:47:01 -0000	1.29
+++ evolution/widgets/misc/e-calendar.c	12 Jun 2006 17:39:32 -0000
@@ -355,8 +355,10 @@ e_calendar_size_allocate	(GtkWidget	*wid
 		- E_CALENDAR_ARROW_BUTTON_Y_PAD * 2;
 
 	gnome_canvas_item_set (cal->prev_item,
-			       "x", xthickness * 2
-			       + E_CALENDAR_ARROW_BUTTON_X_PAD,
+			       "x", (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+			       ? new_x2 + 1 - xthickness * 2 - E_CALENDAR_ARROW_BUTTON_X_PAD
+			         - arrow_button_size
+			       : xthickness * 2 + E_CALENDAR_ARROW_BUTTON_X_PAD,
 			       "y", ythickness * 2
 			       + E_CALENDAR_ARROW_BUTTON_Y_PAD,
 			       "width", arrow_button_size,
@@ -364,9 +366,10 @@ e_calendar_size_allocate	(GtkWidget	*wid
 			       NULL);
 
 	gnome_canvas_item_set (cal->next_item,
-			       "x", new_x2 + 1 - xthickness * 2
-			       - E_CALENDAR_ARROW_BUTTON_X_PAD
-			       - arrow_button_size,
+			       "x", (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL)
+			       ? xthickness * 2 + E_CALENDAR_ARROW_BUTTON_X_PAD
+			       : new_x2 + 1 - xthickness * 2 - E_CALENDAR_ARROW_BUTTON_X_PAD
+			         - arrow_button_size,
 			       "y", ythickness * 2
 			       + E_CALENDAR_ARROW_BUTTON_Y_PAD,
 			       "width", arrow_button_size,
