On 08/03/2010 01:38 AM, Henry Mok wrote:
> Since you didn't have a problem with the auto save, I'm playing around with
> our setup to see if I could figure out what is going wrong. 
> 
> I've customized the interface because I want the user to only get a subset
> of the available options. To do this, I took the
> doc\gui\gui\app\common.xxe_gui, renamed it to customize.xxe_gui and placed
> it in the addon directory. Then I removed all the options that I did not
> want the user to see. 

This is not the proper way to do that. Your customize.xxe_gui should
just redefine the <layout> element. There is nothing more to do.

Please find attached to this email a copy of the stock <layout> element
of applet Editor2. You need to use this file as a starting point of your
customization.




> I've attached the customize.xxe_gui.
> 
> Is this the correct way to customize the interface? When I have the
> customize.xxe_gui in the addon directory, the jnlp file that is created,
> contains the following.
> 
>     <property name="javaws.XXE.guiCustomizations"
>  
> value="addon:customize.xxe_gui;addon:mathml_config/common/customize.xxe_gui"
> />
> 
> When I change the jnlp to
> 
>     <property name="javaws.XXE.guiCustomizations"
>       value="addon:mathml_config/common/customize.xxe_gui"/>
> 
> the automatic saves work fine. Can you tell me what is wrong with my
> customization file?
> 

You seem to have removed the reference to autoSavePart. Something like this:

---
  <layout width="900" height="700">
    <menuBar name="menuBar" />
...
    <hidden>
...

...      <part name="autoSavePart" />
    </hidden>
  </layout>
---

This explains why auto-save does not work.
<?xml version='1.0' encoding='UTF-8'?>
<gui xmlns="http://www.xmlmind.com/xmleditor/schema/gui";
     xmlns:gui="http://www.xmlmind.com/xmleditor/schema/gui";>

  <layout width="800" height="600">
    <topToolBars>
      <toolBar name="toolBar" />
      <toolBar name="configSpecificToolBar" />
      <group>
        <tool name="nodePathTool" stretch="1" />
        <toolBar name="selectToolBar" />
      </group>
    </topToolBars>

    <bottomToolBars>
      <statusBar name="statusBar" />
    </bottomToolBars>

    <rightPanes width="0.33">
      <pane name="editPane" selected="true" />
      <pane name="editAttributePane" />
      <pane name="textSearchReplacePane" />
      <pane name="checkSpellingPane" />
      <pane name="insertCharacterPane" />
      <pane name="checkValidityPane" />
    </rightPanes>

    <preferencesSheets name="preferencesSheets" />

    <hidden>
      <!-- Required to be able to implement command-line arguments and 
           also to script the applet -->
      <action name="newAction" />
      <action name="openAction" />
      <action name="closeAction" /> 

      <!-- Useful when testing
      <accelerator name="newAction" />
      <accelerator name="openAction" />
      <accelerator name="closeAction" />
      -->

      <!-- Macros often use XXE.edit -->
      <action name="editInclusionAction" />

      <!-- Required to support Ctrl-Mouse Wheel -->
      <action name="setLargerTextSizeAction" />

      <!-- Useful accelerators -->
      <accelerator name="textSearchAction" />
      <accelerator name="textSearchBackwardsAction" />
      <accelerator name="textReplaceAction" />
      <accelerator name="textReplaceBackwardsAction" />
      <accelerator name="textFindNextAction" />
      <accelerator name="textFindPreviousAction" />
      <accelerator name="editAttributeAction" />
      <!-- Also required by checkValidityTool -->
      <accelerator name="checkValidityAction" />
      <accelerator name="checkSpellingAction" />

      <!-- These are required to be able to use editPane -->
      <command name="replace" />
      <command name="insert" />
      <command name="convert" />
      <command name="wrap" />
      <action name="replaceAction" />
      <action name="insertBeforeAction" />
      <action name="insertAction" />
      <action name="insertAfterAction" />
      <action name="convertAction" />
      <action name="wrapAction" />

      <part name="editOptionsPart" />
      <part name="viewOptionsPart" />
      <part name="spellOptionsPart" />
      <part name="autoSavePart" />
    </hidden>
  </layout>

  <layout>
    <rightPanes insert="ifDefined(XXE.Feature.IncludeTool) after editPane">
      <pane name="includePane" />
    </rightPanes>

    <hidden
      insert="ifDefined(XXE.Feature.IncludeTool) after spellOptionsPart">
      <command name="include" />
      <action name="includeReplaceAction" />
      <action name="includeBeforeAction" />
      <action name="includeAction" />
      <action name="includeAfterAction" />
    </hidden>
  </layout>

  <layout>
    <rightPanes insert="ifDefined(XXE.Feature.LinkTool) after editPane">
      <pane name="linkPane" />
    </rightPanes>

    <hidden
      insert="ifDefined(XXE.Feature.LinkTool) after spellOptionsPart">
      <command name="addLink" />
      <action name="addLinkAction" />
    </hidden>
  </layout>
</gui>
 
--
XMLmind XML Editor Support List
[email protected]
http://www.xmlmind.com/mailman/listinfo/xmleditor-support

Reply via email to