<?xml version="1.0"?>

<!--
   - The contents of this file are subject to the Netscape Public
   - License Version 1.1 (the "License"); you may not use this file
   - except in compliance with the License. You may obtain a copy of
   - the License at http://www.mozilla.org/NPL/
   -  
   - Software distributed under the License is distributed on an "AS
   - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
   - implied. See the License for the specific language governing
   - rights and limitations under the License.
   -  
   - The Original Code is Mozilla Communicator client code, released
   - March 31, 1998.
   - 
   - The Initial Developer of the Original Code is Netscape
   - Communications Corporation. Portions created by Netscape are
   - Copyright (C) 1998-1999 Netscape Communications Corporation. All
   - Rights Reserved.
   - 
   - Contributor(s): 
  -->

<?xml-stylesheet href="chrome://editor/skin/" type="text/css"?>
<?xml-stylesheet href="chrome://editor/skin/EditorDialog.css" type="text/css"?>

<?xul-overlay href="chrome://global/content/dialogOverlay.xul"?> 
<?xul-overlay href="chrome://editor/content/EdDialogOverlay.xul"?> 

<!DOCTYPE window SYSTEM "chrome://editor/locale/EditorColorProperties.dtd">

<window class="dialog" title="&windowTitle.label;"
    xmlns:html="http://www.w3.org/TR/REC-html40"
    xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
    onload="Startup()"
    align="vertical">

  <html:script language="JavaScript" src="chrome://editor/content/EdDialogCommon.js"/>
  <html:script language="JavaScript" src="chrome://editor/content/EdColorProps.js"/>
  <html:script language="JavaScript" src="chrome://global/content/dialogOverlay.js" />

  <broadcaster id="args" value=""/>

  <html:label>&pageColors.label;</html:label>
  <box class="margin-left-right">
    <!-- must use div else box stretches radio button size -->
    <html:div><html:input type="radio" name="ColorMode" id="DefaultColorsRadio" onclick="UseDefaultColors()"/></html:div>
    <html:label for="DefaultColorsRadio">&defaultColorsRadio.label;</html:label>
  </box>
  <box class="margin-left-right">
    <html:div><html:input type="radio" name="ColorMode" id="CustomColorsRadio" onclick="UseCustomColors()"/></html:div>
    <html:label for="CustomColorsRadio">&customColorsRadio.label;</html:label>
  </box>
  <spring class="bigspacer"/>

<!-- DON'T SHOW COLOR SCHEMES UNTIL REDESIGNED
  <html:div>
    <box flex="1">
      <html:label for="ColorScheme"> &colorScheme.label;</html:label> 
      <spring class="bigspacer"/>
      <html:select id="ColorScheme" size="1" flex="1">
        <html:option> Black on White </html:option>
        <html:option> Blue on White  </html:option>
        <html:option> White on Black </html:option>
      </html:select>
    </box>
  </html:div>
  <spring class="bigspacer"/>
-->

  <box>
    <spring class="bigspacer"/>
    <box align="vertical" flex="1">
      <box>
        <html:label class="margin-left-right"> &normalText.label; </html:label>
        <spring flex="1"/>
        <menu class="colorpicker">
    	    <box>
            <spring id="textCW" class="color-well"/>
            <image class="popup-trigger"/>
          </box>
    	    <menupopup id="normalMenuPopup">
            <colorpicker id="textCP" palettename="standard" onclick="GetColorAndUpdate('textCP','textCW',this);"/>
    	    </menupopup>
        </menu>
      </box>
      <box>
        <html:label class="margin-left-right"> &linkText.label; </html:label>
        <spring flex="1"/>
        <menu class="colorpicker">
    	    <box>
            <spring id="linkCW" class="color-well"/>
            <image class="popup-trigger"/>
          </box>
    	    <menupopup>
            <colorpicker id="linkCP" palettename="standard" onclick="GetColorAndUpdate('linkCP','linkCW',this);"/>
    	    </menupopup>
        </menu>
      </box>
      <box>
        <html:label class="margin-left-right"> &activeLinkText.label; </html:label>
        <spring flex="1"/>
        <menu class="colorpicker">
    	    <box>
            <spring id="activeCW" class="color-well"/>
            <image class="popup-trigger"/>
          </box>
    	    <menupopup>
            <colorpicker id="activeCP" palettename="standard" onclick="GetColorAndUpdate('activeCP','activeCW',this);"/>
    	    </menupopup>
        </menu>
      </box>
      <box>
        <html:label class="margin-left-right"> &visitedLinkText.label; </html:label>
        <spring flex="1"/>
        <menu class="colorpicker">
    	    <box>
            <spring id="visitedCW" class="color-well"/>
            <image class="popup-trigger"/>
          </box>
    	    <menupopup>
            <colorpicker id="visitedCP" palettename="standard" onclick="GetColorAndUpdate('visitedCP','visitedCW',this);"/>
    	    </menupopup>
        </menu>
      </box>
      <box>
        <html:label class="margin-left-right"> &background.label; </html:label>
        <spring flex="1"/>
        <menu class="colorpicker">
    	    <box>
            <spring id="backgroundCW" class="color-well"/>
            <image class="popup-trigger"/>
          </box>
    	    <menupopup>
            <colorpicker id="backgroundCP" palettename="standard" onclick="GetColorAndUpdate('backgroundCP','backgroundCW',this);"/>
    	    </menupopup>
        </menu>
      </box>
    </box>
    <spring class="bigspacer"/>
    <!-- Use table cell for preview so we can use BGCOLOR and BACKGROUND attributes -->
    <html:table><html:tr>
      <html:td id="ColorPreview" valign="top">
        <html:div id="NormalText">&normalText.label;</html:div>
        <html:div id="LinkText">&linkText.label;</html:div>
        <html:div id="ActiveLinkText">&activeLinkText.label;</html:div>
        <html:div id="VisitedLinkText">&visitedLinkText.label;</html:div>
      </html:td>
    </html:tr></html:table>
  </box>
  <html:div class="separator" align="horizontal"/>
  <box>
    <html:div><html:input type="checkbox" id="BackgroundImageCheckbox" onclick="onBackgroundImageCheckbox()"/></html:div>
    <html:label for="BackgroundImageCheckbox"> &backgroundImage.label; </html:label>
  </box>
  <box>
    <html:input type="text" class="SizeToParent" id="BackgroundImageInput" flex="1"/>
    <spring class="spacer"/>
    <titledbutton id="ChooseFile"/>
  </box>
  <box>
    <html:div id="SaveImageMsg">&saveImageMsg.label;</html:div>
    <spring class="bigspacer"/>
    <spring flex="1"/>
    <box align="vertical">
      <spring class="bigspacer"/>
      <titledbutton id="AdvancedEditButton2"/>
    </box>
  </box>
  <html:div class="separator" align="horizontal"/>
  <box id="okCancelButtons"/> 
</window>
