Index: src/yelp-gecko-utils.cpp
===================================================================
RCS file: /cvs/gnome/yelp/src/yelp-gecko-utils.cpp,v
retrieving revision 1.13
diff -u -p -r1.13 yelp-gecko-utils.cpp
--- src/yelp-gecko-utils.cpp	16 May 2005 21:02:33 -0000	1.13
+++ src/yelp-gecko-utils.cpp	25 Sep 2005 19:26:30 -0000
@@ -102,6 +102,12 @@ gecko_prefs_set_int (const gchar *key, g
 }
 
 extern "C" void
+yelp_gecko_set_direction (gboolean rtl)
+{
+	gecko_prefs_set_int ("bidi.direction", rtl ? 2 : 1);
+}
+
+extern "C" void
 yelp_gecko_set_caret (gboolean value)
 {
 	gecko_prefs_set_bool ("accessibility.browsewithcaret", value);
Index: src/yelp-gecko-utils.h
===================================================================
RCS file: /cvs/gnome/yelp/src/yelp-gecko-utils.h,v
retrieving revision 1.8
diff -u -p -r1.8 yelp-gecko-utils.h
--- src/yelp-gecko-utils.h	16 May 2005 21:02:33 -0000	1.8
+++ src/yelp-gecko-utils.h	25 Sep 2005 19:26:30 -0000
@@ -28,11 +28,12 @@
 
 G_BEGIN_DECLS
 
-void            yelp_gecko_set_caret   (gboolean       value);
-void            yelp_gecko_set_color   (YelpColorType  type,
-					const gchar   *color);
-void            yelp_gecko_set_font    (YelpFontType   font_type,
-				        const gchar   *fontname);
+void            yelp_gecko_set_direction (gboolean       rtl);
+void            yelp_gecko_set_caret     (gboolean       value);
+void            yelp_gecko_set_color     (YelpColorType  type,
+					  const gchar   *color);
+void            yelp_gecko_set_font      (YelpFontType   font_type,
+				          const gchar   *fontname);
 
 G_END_DECLS
 
Index: src/yelp-html.cpp
===================================================================
RCS file: /cvs/gnome/yelp/src/yelp-html.cpp,v
retrieving revision 1.1
diff -u -p -r1.1 yelp-html.cpp
--- src/yelp-html.cpp	16 May 2005 21:02:33 -0000	1.1
+++ src/yelp-html.cpp	25 Sep 2005 19:26:30 -0000
@@ -48,6 +48,7 @@ struct _YelpHtmlPriv {
     gchar       *anchor;
 };
 
+static void      html_set_direction      (void);
 static void      html_set_fonts          (void);
 static void      html_set_colors         (void);
 static void      html_set_a11y           (void);
@@ -154,6 +155,7 @@ html_init (YelpHtml *html)
 				      NULL);
 	html_set_a11y ();
     }
+    html_set_direction ();
 }
 
 static void
@@ -383,6 +385,14 @@ void
 yelp_html_select_all (YelpHtml *html)
 {
     html->priv->yelper->DoCommand ("cmd_selectAll");
+}
+
+static void
+html_set_direction (void)
+{
+    gboolean rtl;
+    rtl = gtk_widget_get_default_direction () == GTK_TEXT_DIR_RTL;
+    yelp_gecko_set_direction (rtl);
 }
 
 static void
