<?xml version="1.0"?>

<!-- This Source Code Form is subject to the terms of the Mozilla Public
- License, v. 2.0. If a copy of the MPL was not distributed with this
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->

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

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

<!DOCTYPE dialog SYSTEM "chrome://editor/locale/EditorInsertMath.dtd">

<dialog title="&windowTitle.label;"
        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
        onload="Startup();"
        buttonlabelaccept="&insertButton.label;"
        buttonaccesskeyaccept="&insertButton.accesskey;"
        ondialogaccept="return onAccept();"
        ondialogcancel="return onCancel();">

  <!-- Methods common to all editor dialogs -->
  <script type="application/javascript"
          src="chrome://editor/content/editorUtilities.js"/>
  <script type="application/javascript"
          src="chrome://editor/content/EdDialogCommon.js"/>
  <script type="application/javascript"
          src="chrome://editor/content/EdInsertMath.js"/>

  <spacer id="location" offsetY="50" persist="offsetX offsetY"/>
  <broadcaster id="args" value=""/>

  <label id="srcMessage" value="&sourceEditField.label;"/>
  <textbox id="input" rows="5" multiline="true" oninput="updateMath();"
           placeholder="\sqrt{x_1} + \frac{π^3}{2}"/>
  <vbox flex="1" style="overflow: auto; width: 30em; height: 5em;">
    <description id="output"/>
  </vbox>
  <tabbox id="tabboxInsertLaTeXCommand">
    <tabs/>
    <tabpanels oncommand="insertLaTeXCommand(event.target);"/>
  </tabbox>
  <spacer class="spacer"/>
  <groupbox>
    <caption label="&options.label;"/>
    <hbox>
      <radiogroup id="optionMode" oncommand="updateMode();">
        <radio label="&optionInline.label;"
               accesskey="&optionInline.accesskey;"/>
        <radio label="&optionDisplay.label;"
               accesskey="&optionDisplay.accesskey;"/>
      </radiogroup>
      <radiogroup id="optionDirection" oncommand="updateDirection();">
        <radio label="&optionLTR.label;"
               accesskey="&optionLTR.accesskey;"/>
        <radio label="&optionRTL.label;"
               accesskey="&optionRTL.accesskey;"/>
      </radiogroup>
    </hbox>
  </groupbox>
  <spacer class="spacer"/>
  <separator class="groove"/>
</dialog>
