diff --git a/lib/exe/spellcheck.php b/lib/exe/spellcheck.php
index 2dea154655ffb0c122ea71a84000e8f604c71f07..daddebe471f9cd8d0a8d013fb706fd0e5c0f6995 100644
--- a/lib/exe/spellcheck.php
+++ b/lib/exe/spellcheck.php
@@ -117,7 +117,8 @@ function spell_check() {
   $string = preg_replace("/(\015\012)|(\015)/","\012",$string);
   $string = htmlspecialchars($string);
 
-  // make sure multiple spaces are kept
+  // make sure multiple spaces and leading are kept
+  $string = preg_replace('/^ /m',' ',$string);
   $string = preg_replace('/  /','  ',$string);
 
   // we need the text as array later
diff --git a/lib/scripts/spellcheck.js b/lib/scripts/spellcheck.js
index e00512010d3f672c36b51861ab411136e25865b1..73b392f5ba6e1dbf75db65364e9fdf88ae7b7fb8 100644
--- a/lib/scripts/spellcheck.js
+++ b/lib/scripts/spellcheck.js
@@ -120,6 +120,21 @@ function ajax_spell_class(){
     this.showboxObj = document.getElementById('spell__result');
     this.suggestObj = document.getElementById('spell__suggest');
 
+
+    // set wordwrap style with browser propritary attributes
+    if(is_gecko){
+      this.showboxObj.style.whiteSpace = '-moz-pre-wrap'; // Mozilla, since 1999
+    }else if(is_opera_preseven){
+      this.showboxObj.style.whiteSpace = '-pre-wrap';     // Opera 4-6
+    }else if(is_opera_seven){
+      this.showboxObj.style.whiteSpace = '-o-pre-wrap';   // Opera 7
+    }else{
+      this.showboxObj.style['word-wrap']   = 'break-word';    //Internet Explorer 5.5+
+    }
+    // Which browser supports this?
+    // this.showboxObj.style.whiteSpace = 'pre-wrap';      // css-3
+
+
     // set Translation Strings
     this.txtStart = txtStart;
     this.txtStop  = txtStop;
diff --git a/lib/styles/spellcheck.css b/lib/styles/spellcheck.css
index c2d43e0cd36dcc2431b9d27f0306c6a6603129e3..51106f95a27e2f8d1dec58f3cf49c73ed824c92b 100644
--- a/lib/styles/spellcheck.css
+++ b/lib/styles/spellcheck.css
@@ -1,5 +1,5 @@
 /**
- * Basic styles for the spellchecker. Only included when the spellchek option
+ * Basic styles for the spellchecker. Only included when the spellcheck option
  * is enabled. These styles are the absolute minimum to make the spellchecker
  * work. Templates should add addional styles for making it look nice.
  */
@@ -17,11 +17,5 @@ div.dokuwiki div#spell__result {
   font-family:monospace;
   overflow: auto;
   z-index: 1;
-
-  white-space: pre-wrap;       /* css-3 */
-  white-space: -moz-pre-wrap;  /* Mozilla, since 1999 */
-  white-space: -pre-wrap;      /* Opera 4-6 */
-  white-space: -o-pre-wrap;    /* Opera 7 */
-  word-wrap: break-word;       /* Internet Explorer 5.5+ */
 }