From 9364ff6a09c65e833af3b2c4d1c48b129e02fa8e Mon Sep 17 00:00:00 2001
From: garvinhicking <garvinhicking>
Date: Thu, 9 Feb 2006 11:06:45 +0000
Subject: [PATCH] lang_direction support

---
 include/functions_entries_admin.inc.php | 6 ++++--
 templates/blue/htmlarea.css             | 1 +
 templates/default/htmlarea.css          | 1 +
 templates/moz-modern/htmlarea.css       | 1 +
 templates/mt-trendy/htmlarea.css        | 1 +
 templates/newspaper/htmlarea.css        | 1 +
 templates/wp/htmlarea.css               | 1 +
 7 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/include/functions_entries_admin.inc.php b/include/functions_entries_admin.inc.php
index fd4d1f9..151b31b 100644
--- a/include/functions_entries_admin.inc.php
+++ b/include/functions_entries_admin.inc.php
@@ -490,13 +490,15 @@ function serendipity_emit_htmlarea_code($item, $jsname, $spawnMulti = false) {
                  array(
                    "\n",
                    "'",
-                   "\r"
+                   "\r",
+                   "{LANG_DIRECTION}"
                  ),
 
                  array(
                    '\n',
                    "\'",
-                   ""
+                   "",
+                   (defined('LANG_DIRECTION') ? LANG_DIRECTION : 'ltr')
                  ),
 
                  file_get_contents(serendipity_getTemplateFile('htmlarea.css', 'serendipityPath'))
diff --git a/templates/blue/htmlarea.css b/templates/blue/htmlarea.css
index 0e0507b..4b3687f 100644
--- a/templates/blue/htmlarea.css
+++ b/templates/blue/htmlarea.css
@@ -6,6 +6,7 @@ body {
   color: #000000;
   font-family: sans-serif;
   line-height: 20px;
+  direction: {LANG_DIRECTION};
 }
 
 /** Embedded images with the s9y image manager **/
diff --git a/templates/default/htmlarea.css b/templates/default/htmlarea.css
index 9db65fb..99c3377 100644
--- a/templates/default/htmlarea.css
+++ b/templates/default/htmlarea.css
@@ -6,6 +6,7 @@ body {
     font-size: 9.5pt;
     font-weight: normal;
     font-family: verdana, arial, geneva, helvetica, sans-serif;
+    direction: {LANG_DIRECTION};
 }
 
 /** Embedded images with the s9y image manager **/
diff --git a/templates/moz-modern/htmlarea.css b/templates/moz-modern/htmlarea.css
index 93ced34..0bcdc01 100644
--- a/templates/moz-modern/htmlarea.css
+++ b/templates/moz-modern/htmlarea.css
@@ -5,6 +5,7 @@ body {
   font-size: small;
   font-weight: normal;
   padding: 10px;
+  direction: {LANG_DIRECTION};
 }
 
 /** Embedded images with the s9y image manager **/
diff --git a/templates/mt-trendy/htmlarea.css b/templates/mt-trendy/htmlarea.css
index c3a7b6f..0be3f4f 100644
--- a/templates/mt-trendy/htmlarea.css
+++ b/templates/mt-trendy/htmlarea.css
@@ -6,6 +6,7 @@ body {
   font-weight: normal;
   line-height: 140%;
   padding: 10px;
+  direction: {LANG_DIRECTION};
 }
 
 /** Embedded images with the s9y image manager **/
diff --git a/templates/newspaper/htmlarea.css b/templates/newspaper/htmlarea.css
index e045a98..95b458d 100644
--- a/templates/newspaper/htmlarea.css
+++ b/templates/newspaper/htmlarea.css
@@ -5,6 +5,7 @@ body {
     padding-left: 16px;
     font-size: 9pt;
     text-align:justify;
+    direction: {LANG_DIRECTION};
 }
 
 /** Embedded images with the s9y image manager **/
diff --git a/templates/wp/htmlarea.css b/templates/wp/htmlarea.css
index 9db65fb..99c3377 100644
--- a/templates/wp/htmlarea.css
+++ b/templates/wp/htmlarea.css
@@ -6,6 +6,7 @@ body {
     font-size: 9.5pt;
     font-weight: normal;
     font-family: verdana, arial, geneva, helvetica, sans-serif;
+    direction: {LANG_DIRECTION};
 }
 
 /** Embedded images with the s9y image manager **/
-- 
2.39.5