Index: /trunk/lang/de.js
===================================================================
--- /trunk/lang/de.js (revision 471)
+++ /trunk/lang/de.js (revision 700)
@@ -154,4 +154,10 @@
   "Register panel left": "Erzeugt linke Leiste",
   "Register panel top": "Erzeugt obere Leiste",
-  "Register panel bottom": "Erzeugt untere Leiste"
+  "Register panel bottom": "Erzeugt untere Leiste",
+  
+  // ColorPicker
+  "Click a color..." : "Farbe wÃ€hlen",
+  "Sample" : "Beispiel",
+  "Web Safe: " : "Web Safe: ",
+  "Color: " : "Farbe: "
 };
Index: /trunk/plugins/ImageManager/manager.php
===================================================================
--- /trunk/plugins/ImageManager/manager.php (revision 677)
+++ /trunk/plugins/ImageManager/manager.php (revision 700)
@@ -30,5 +30,5 @@
 <script type="text/javascript" src="../../popups/popup.js"></script>
 <script type="text/javascript" src="assets/popup.js"></script>
-<script type="text/javascript" src="../../popups/color_picker.js"></script>
+<script type="text/javascript" src="../../modules/ColorPicker/ColorPicker.js"></script>
 <script type="text/javascript" src="<?php print $IMConfig['base_url'];?>assets/dialog.js"></script>
 <script type="text/javascript">
Index: /trunk/plugins/ImageManager/assets/manager.css
===================================================================
--- /trunk/plugins/ImageManager/assets/manager.css (revision 677)
+++ /trunk/plugins/ImageManager/assets/manager.css (revision 700)
@@ -1,3 +1,3 @@
-html, body {  background-color: ButtonFace;  color: ButtonText; font: 11px Tahoma,Verdana,sans-serif; margin: 0; padding: 0;}
+html, body, .dialog {  background-color: ButtonFace;  color: ButtonText; font: 11px Tahoma,Verdana,sans-serif; margin: 0; padding: 0;}
 body { padding: 5px; }
 fieldset { padding: 0;}
@@ -22,2 +22,8 @@
 table { margin-top:10px; }
 th, td { padding-right:3px; text-align:left; font-family:small-caption,helvetica,sans-serif; }
+.buttonColor {
+  padding: 1px;
+  cursor: default;
+  border: 1px solid;
+  border-color: ButtonHighlight ButtonShadow ButtonShadow ButtonHighlight;
+}
Index: /trunk/plugins/ExtendedFileManager/extended-file-manager.js
===================================================================
--- /trunk/plugins/ExtendedFileManager/extended-file-manager.js (revision 681)
+++ /trunk/plugins/ExtendedFileManager/extended-file-manager.js (revision 700)
@@ -61,5 +61,6 @@
 
     var editor = this;  // for nested functions
-    var outparam = null;
+    var outparam = {"editor" : this, param : null};
+    
     if (typeof image == "undefined") {
         image = this.getParentElement();
@@ -69,5 +70,5 @@
 
     if (image) {
-        outparam = {
+        outparam.param = {
             f_url    : Xinha.is_ie ? image.src : image.getAttribute("src"),
             f_alt    : image.alt,
@@ -85,11 +86,11 @@
 
         // compress 'top right bottom left' syntax into one value if possible
-        outparam.f_border = shortSize(outparam.f_border);
-        outparam.f_padding = shortSize(outparam.f_padding);
-        outparam.f_margin = shortSize(outparam.f_margin);
+        outparam.param.f_border = shortSize(outparam.f_border);
+        outparam.param.f_padding = shortSize(outparam.f_padding);
+        outparam.param.f_margin = shortSize(outparam.f_margin);
 
         // convert rgb() calls to rgb hex
-        outparam.f_backgroundColor = convertToHex(outparam.f_backgroundColor);
-        outparam.f_borderColor = convertToHex(outparam.f_borderColor);
+        outparam.param.f_backgroundColor = convertToHex(outparam.f_backgroundColor);
+        outparam.param.f_borderColor = convertToHex(outparam.f_borderColor);
 
     }
Index: /trunk/plugins/ExtendedFileManager/manager.php
===================================================================
--- /trunk/plugins/ExtendedFileManager/manager.php (revision 681)
+++ /trunk/plugins/ExtendedFileManager/manager.php (revision 700)
@@ -81,5 +81,5 @@
 <script type="text/javascript" src="<?php print $IMConfig['base_url'];?>assets/popup.js"></script>
 <script type="text/javascript" src="<?php print $IMConfig['base_url'];?>assets/dialog.js"></script>
-<?php if (!empty($IMConfig['use_color_pickers'])) { ?><script type="text/javascript" src="../../popups/color_picker.js"></script><?php } ?>
+<?php if (!empty($IMConfig['use_color_pickers'])) { ?><script type="text/javascript" src="../../modules/ColorPicker/ColorPicker.js"></script><?php } ?>
 <script type="text/javascript">
 /* <![CDATA[ */
Index: /trunk/plugins/ExtendedFileManager/assets/manager.css
===================================================================
--- /trunk/plugins/ExtendedFileManager/assets/manager.css (revision 677)
+++ /trunk/plugins/ExtendedFileManager/assets/manager.css (revision 700)
@@ -1,3 +1,3 @@
-html, body {  background-color: ButtonFace;  color: ButtonText; font: 11px Tahoma,Verdana,sans-serif; margin: 0; padding: 0;}
+html, body, .dialog {  background-color: ButtonFace;  color: ButtonText; font: 11px Tahoma,Verdana,sans-serif; margin: 0; padding: 0;}
 body { padding: 5px; }
 fieldset { padding: 0;}
@@ -25,2 +25,9 @@
 th, td { padding-right:3px; text-align:left; font-family:small-caption,helvetica,sans-serif; }
 .dirWidth {width: 59%}
+
+.buttonColor {
+  padding: 1px;
+  cursor: default;
+  border: 1px solid;
+  border-color: ButtonHighlight ButtonShadow ButtonShadow ButtonHighlight;
+}
Index: /trunk/plugins/FullPage/popups/docprop.html
===================================================================
--- /trunk/plugins/FullPage/popups/docprop.html (revision 419)
+++ /trunk/plugins/FullPage/popups/docprop.html (revision 700)
@@ -3,5 +3,5 @@
 <title>Document properties</title>
 <script type="text/javascript" src="../../../popups/popup.js"></script>
-<script type="text/javascript" src="../../../popups/color_picker.js"></script>
+<script type="text/javascript" src="../../../modules/ColorPicker/ColorPicker.js"></script>
 <link rel="stylesheet" type="text/css" href="../../../popups/popup.css" />
 <script type="text/javascript">
Index: /trunk/popups/popup.css
===================================================================
--- /trunk/popups/popup.css (revision 677)
+++ /trunk/popups/popup.css (revision 700)
@@ -1,3 +1,3 @@
-html, body {
+html, body, .dialog {
   background: ButtonFace;
   color: ButtonText;
@@ -26,5 +26,10 @@
 border-bottom: 1px solid black; letter-spacing: 2px;
 }
-
+.buttonColor {
+  padding: 1px;
+  cursor: default;
+  border: 1px solid;
+  border-color: ButtonHighlight ButtonShadow ButtonShadow ButtonHighlight;
+}
 #buttons {
       margin-top: 1em; border-top: 1px solid #999;
Index: /trunk/modules/FullScreen/full-screen.js
===================================================================
--- /trunk/modules/FullScreen/full-screen.js (revision 695)
+++ /trunk/modules/FullScreen/full-screen.js (revision 700)
@@ -40,5 +40,5 @@
 
 FullScreen.prototype._lc = function(string) {
-    return HTMLArea._lc(string, {url : _editor_url + 'modules/FullScreen/lang/'});
+    return HTMLArea._lc(string, {url : _editor_url + 'modules/FullScreen/lang/',context:"FullScreen"});
 };
 
Index: /trunk/modules/ColorPicker/ColorPicker.js
===================================================================
--- /trunk/modules/ColorPicker/ColorPicker.js (revision 694)
+++ /trunk/modules/ColorPicker/ColorPicker.js (revision 700)
@@ -77,5 +77,20 @@
    * }}}
    */
-
+  ColorPicker._pluginInfo =
+  {
+    name     : "colorPicker",
+    version  : "1.0",
+    developer: "James Sleeman",
+    developer_url: "http://www.gogo.co.nz/",
+    c_owner      : "Gogo Internet Services",
+    license      : "htmlArea",
+    sponsor      : "Gogo Internet Services",
+    sponsor_url  : "http://www.gogo.co.nz/"
+  };
+  function ColorPicker() 
+  {
+	// dummy function for Xinha plugin api, note the different names
+  }
+  //the actual function is below
   function colorPicker(params)
   {
@@ -102,4 +117,5 @@
     this.saved_cells = null;
     this.table = document.createElement('table');
+    this.table.className = "dialog";
     this.table.cellSpacing = this.table.cellPadding = 0;
     this.table.onmouseup = function()
@@ -111,5 +127,4 @@
     this.table.appendChild(this.tbody);
     this.table.style.border = '1px solid WindowFrame';
-    this.table.style.backgroundColor = '#fff';
     this.table.style.zIndex = '1000';
     // Add a title bar and close button
@@ -118,9 +133,8 @@
     var td = document.createElement('td');
     td.colSpan = this.side;
-    td.style.backgroundColor = '#ccc';
-    td.style.color = '#000';
+    td.className= "title";
     td.style.fontFamily = 'small-caption,caption,sans-serif';
     td.style.fontSize = 'x-small';
-    td.appendChild(document.createTextNode('Click a color...'));
+    td.appendChild(document.createTextNode(Xinha._lc('Click a color...')));
     td.style.borderBottom = '1px solid WindowFrame';
     tr.appendChild(td);
@@ -128,13 +142,17 @@
 
     var td = document.createElement('td');
+    td.className= "title";
     td.colSpan = 2;
-    td.style.backgroundColor = '#ccc'; //'ActiveCaption';
+    td.style.fontFamily = 'Tahoma,Verdana,sans-serif';
     td.style.borderBottom = '1px solid WindowFrame';
+    td.style.paddingRight = '0';
     tr.appendChild(td);
+    
 
     var but = document.createElement('div');
-    but.style.height = '12px';
-    but.style.width = '12px';
-    but.style.border = '2px outset';
+    but.title = Xinha._lc("Close");
+    but.className= 'buttonColor';
+    but.style.height = '11px';
+    but.style.width = '11px';
     but.style.cursor = 'pointer';
     but.onclick = function() { picker.close(); };
@@ -145,5 +163,12 @@
     but.style.cssFloat = 'right';
     but.style.styleFloat = 'right';
-    but.style.backgroundColor = '#eee';
+    but.style.padding = '0';
+    but.style.margin = '2px';
+    but.style.backgroundColor = 'transparent';
+    but.style.fontSize= '11px';
+    if ( !Xinha.is_ie) but.style.lineHeight= '9px'; // line-height:9px is better for centering the x, but IE cuts it off at the bottom :(
+    but.style.letterSpacing= '0';
+    
+        
     td.appendChild(but);
 
@@ -157,5 +182,7 @@
     this.chosenColor.type = 'text';
     this.chosenColor.maxLength = 7;
-    this.chosenColor.style.width = '56px';
+    this.chosenColor.style.width = '50px';
+    this.chosenColor.style.fontSize = '11px';
+    
     this.chosenColor.onchange = function()
       {
@@ -174,5 +201,5 @@
 
     this.foreSample = document.createElement('div');
-    this.foreSample.appendChild(document.createTextNode('Sample'));
+    this.foreSample.appendChild(document.createTextNode(Xinha._lc('Sample')));
     this.foreSample.style.fontWeight = 'bold';
     this.foreSample.style.fontFamily = 'small-caption,caption,sans-serif';
@@ -609,5 +636,5 @@
         var div = document.createElement('div');
         var label = document.createElement('label');
-        label.appendChild(document.createTextNode('Web Safe: '));
+        label.appendChild(document.createTextNode(Xinha._lc('Web Safe: ')));
 
         this.constrain_cb.onclick = function() { picker.pick_color(); };
@@ -624,13 +651,13 @@
         label.style.fontFamily = 'small-caption,caption,sans-serif';
         label.style.fontSize = 'x-small';
-        label.appendChild(document.createTextNode('Color: '));
+        label.appendChild(document.createTextNode(Xinha._lc('Color: ')));
         label.appendChild(this.chosenColor);
         div.appendChild(label);
         var but = document.createElement('span');
-        but.style.height = '12px';
+        but.className = "buttonColor ";
+        but.style.fontSize = '13px';
         but.style.width = '24px';
-        but.style.border = '2px outset';
-        but.style.backgroundColor = '#eee';
-        but.style.marginLeft = '6px';
+        but.style.marginLeft = '2px';
+        but.style.padding = '0px 4px';
         but.style.cursor = 'pointer';
         but.onclick = function() { colorPicker.remember(picker.chosenColor.value, picker.savecolors); picker.callback(picker.chosenColor.value); picker.close(); };
@@ -751,5 +778,4 @@
       @*/
     };
-
   }
 
@@ -794,2 +820,6 @@
   }
 };
+
+colorPicker._lc = function(string) {
+  return Xinha._lc(string);
+}
Index: /trunk/XinhaCore.js
===================================================================
--- /trunk/XinhaCore.js (revision 699)
+++ /trunk/XinhaCore.js (revision 700)
@@ -1526,4 +1526,14 @@
           else if ( typeof InsertTable != 'undefined') editor.registerPlugin('InsertTable');
         break;
+        case "hilitecolor":
+        case "forecolor":
+          if ( typeof ColorPicker == 'undefined')
+          {
+            Xinha.loadPlugin("ColorPicker", function() { editor.generate(); } , _editor_url + 'modules/ColorPicker/ColorPicker.js');
+            return false;
+          }
+          else if ( typeof ColorPicker != 'undefined') editor.registerPlugin('ColorPicker');
+        break;
+        
       }
     }
@@ -3683,10 +3693,4 @@
 {
   var editor = this;	// for nested functions
-  
-  if ( typeof colorPicker == 'undefined' )
-  {
-    Xinha._loadback(_editor_url + 'modules/ColorPicker/ColorPicker.js', function () {editor._colorSelector(cmdID)});
-    return false;
-  }
 
   // backcolor only works with useCSS/styleWithCSS (see mozilla bug #279330 & Midas doc)
@@ -5058,12 +5062,8 @@
  * @param context Case sensitive context name, eg 'Xinha', 'TableOperations', ...
  */
-Xinha._loadlang = function(context)
-{
-  var url, lang;
-  if (typeof context == 'object' && context.url)
-  {
-    url = context.url + _editor_lang + ".js";
-    context = context.context;
-  }
+Xinha._loadlang = function(context,url)
+{
+  var lang;
+  
   if ( typeof _editor_lcbackend == "string" )
   {
@@ -5115,5 +5115,11 @@
 Xinha._lc = function(string, context, replace)
 {
-  var ret;
+  var url,ret;
+  if (typeof context == 'object' && context.url && context.context)
+  {
+    url = context.url + _editor_lang + ".js";
+    context = context.context;
+  }
+
   var m = null;
   if (typeof string == 'string') m = string.match(/\$(.*?)=(.*?)\$/g);
@@ -5153,5 +5159,5 @@
     if ( typeof Xinha._lc_catalog[context] == 'undefined' )
     {
-      Xinha._lc_catalog[context] = Xinha._loadlang(context);
+      Xinha._lc_catalog[context] = Xinha._loadlang(context,url);
     }
 
