Home
Categories
Dictionary
Download
Project Details
Changes Log
Who We Are
FAQ
License

Convert an XML Definition File



It is possible to save one XML definition file to:
  • Change the values for the colors Index, picture index, StyleSet index, etc... in the output XML Definition File
  • And even change widget names, or widget attributes names in the output XML Definition File
This conversion is configurable through an XML configuration and is performed through the File => Convert menu.
editorconvert
Two XML files can be used to configure the conversion:
  • Graphics Configuration Conversion: Change the values for the colors Index, picture index, StyleSet index, etc... This configuration will only change the graphics configuration, so it will not prevent the output XML Definition File to be opened in the Editor or the Server, but the graphic configuration for the output XML Definition FIle will be different from the input
  • Widget Conversion Rules: Change widget names, widget parameter names, etc.. Note that these rules can change the ARINC 661 definition (because widget names or parameters will change), so it is possible that the output XML Definition File can not be opened without setting a specific J661 extension.
Each of this configuration is optional. For example, it is completely possible to only set the Graphics Configuration Conversion, or only the Widget Conversion Rules.

Graphics Configuration Conversion

The Graphics Configuration Conversion XML file allows to specify conversions for colors, pictures, fonts, and StyleSets. Basically, the file specifies for each numeric ID that must be converted the numeric ID in which it must be converted:
  • for color IDs
  • for picture IDs
  • for font IDs
  • for StyleSet IDs. These conversions are defined for each Widget type, to allow different widgets to have different converted StyleSet IDs
Note that all the conversions are specified as numeric IDs, and elements which are converted will always be serialized as a number, regardless of the value of the Save References As setting in the Editor.

Grammar

See the Graphics Configuration Conversion grammar.

Example

      <xmlExport>
         <colors>
            <color id="2" toId="10" />
            <color id="3" toId="12" />
         </colors>    
         <fonts>
            <font id="1" toId="4" />
         </fonts>  
         <styleSets>
            <widget arincId="A661_PUSH_BUTTON">
               <style id="1" toId="4" />
               <style id="2" toId="6" />
            </widget>
         </styleSets>            
      </xmlExport>

Widget Conversion Rules

TheWidget Conversion Rules XML file allows to:
  • Change widget types
  • Change widget parameter names
  • Add new widget parameters
  • Remove existing widget parameters
Note that the Editor will not chckec the validity of the resulting XML file, which means that you can define any name you want in the rules[1]
For example, you can even define a new type which does not exist

Grammar

See the Widget Conversion Rules grammar.

Example

         <widgets defaultID="WidgetID" >
            <widget type="A661_PUSH_BUTTON" toType="A661_PICTURE_PUSH_BUTTON">
               <param toName="PictureReference" value="NULL" />
               <param toName="PicturePosition" value="A661_LEFT" />      
            </widget>
            <widget type="A661_GP_TRIANGLE" >
               <param name="ColorIndex" toName="Color" />
               <param name="FillIndex" />    
            </widget>              
         </widgets>
In this example:
  • The name of the WidgetIdent attribute of widgets will be renamed to "WidgetID"
  • "A661_PUSH_BUTTON" widgets types become "A661_PICTURE_PUSH_BUTTON" types. The "PictureReference" and "PicturePosition" parameters are added. The "PictureReference" has the "NULL" value. The "PicturePosition" parameter has the "A661_LEFT" value
  • The names of "ColorIndex" parameters for "A661_GP_TRIANGLE" widgets types are changed to "Color"
  • The "FillIndex" parameters for "A661_GP_TRIANGLE" widgets types are removed

Notes

  1. ^ For example, you can even define a new type which does not exist

See also


Categories: editor | user

Copyright 2016-2017 Dassault Aviation. All Rights Reserved. Documentation and source under the LGPL v2 licence