<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet href="../schema2xhtml.xsl" type="text/xsl"?>

<!-- $Id: editors.xsd 19978 2012-02-13 13:50:46Z kevin-dickerson $ -->

<!-- This schema is part of JMRI. Copyright 2009, 2010.                           -->
<!--                                                                        -->
<!-- JMRI is free software; you can redistribute it and/or modify it under  -->
<!-- the terms of version 2 of the GNU General Public License as published  -->
<!-- by the Free Software Foundation. See the "COPYING" file for a copy     -->
<!-- of this license.                                                       -->
<!--                                                                        -->
<!-- JMRI is distributed in the hope that it will be useful, but WITHOUT    -->
<!-- ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or  -->
<!-- FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License  -->
<!-- for more details.                                                      -->


<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
           xmlns:xsi ="http://www.w3.org/2001/XMLSchema-instance"
           xmlns:docbook="http://docbook.org/ns/docbook"
           xmlns:jmri="http://jmri.org/xml/schema/JMRIschema"
           xsi:schemaLocation="
                http://jmri.org/xml/schema/JMRIschema http://jmri.org/xml/schema/JMRIschema.xsd
                http://docbook.org/ns/docbook http://jmri.org/xml/schema/docbook/DocBook.xsd
            "
        >
  <xs:annotation>
    <xs:documentation>
      Defines XML stuctures common to Layout Editor and Panel Editor
    </xs:documentation>
  </xs:annotation>

    <xs:complexType name="EditorIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing an icon reference
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.PositionableLabelXml#storeIcon
        </xs:appinfo>
      </xs:annotation>
      <xs:sequence>
        <xs:element name="rotation" type="xs:integer" minOccurs="0" maxOccurs="1" >
          <xs:annotation><xs:documentation>
            Rotation in 90-degree steps, including scaled icons;
            added in JMRI 2.9.4 as replacement for &amp;rotate&amp; attribute
          </xs:documentation></xs:annotation>
        </xs:element>
      </xs:sequence>
      <xs:attribute name="url" type="xs:string" />
      <xs:attribute name="rotate" type="xs:string" >
        <xs:annotation><xs:documentation>        
          Deprecated in JMRI 2.9.4 in favor of &amp;rotation&amp; element;
          was rotation in 90-degree steps, but skipped rotating scaled icons.
        </xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="degrees" type="xs:float" />
      <xs:attribute name="scale" type="xs:float" />
    </xs:complexType>

    <xs:complexType name="EditorTextInfoType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing text information
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.PositionableLabelXml#storeTextInfo
        </xs:appinfo>
      </xs:annotation>
      <xs:attribute name="text" type="xs:string" />
      <xs:attribute name="red" type="xs:int" />
      <xs:attribute name="green" type="xs:int" />
      <xs:attribute name="blue" type="xs:int" />
      <xs:attribute name="redBack" type="xs:int" />
      <xs:attribute name="greenBack" type="xs:int" />
      <xs:attribute name="blueBack" type="xs:int" />
      <!-- following are in code, not in 2.9.4 DTD -->
      <xs:attribute name="size" type="xs:int" />
      <xs:attribute name="style" type="xs:string" />
      <xs:attribute name="margin" type="xs:int" />
      <xs:attribute name="borderSize" type="xs:int" />
      <xs:attribute name="redBorder" type="xs:int" />
      <xs:attribute name="greenBorder" type="xs:int" />
      <xs:attribute name="blueBorder" type="xs:int" />
      <xs:attribute name="fixedWidth" type="xs:string" />
      <xs:attribute name="fixedHeight" type="xs:string" />
      
    </xs:complexType>

  
    <xs:attributeGroup name="EditorCommonAttributesGroup">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing common PositionableLabel child attributes
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.PositionableLabelXml#storeCommonAttributes
        </xs:appinfo>
      </xs:annotation>
      <xs:attribute name="x" type="xs:int" use="required" />
      <xs:attribute name="y" type="xs:int" use="required" />
      <xs:attribute name="level" type="xs:int" />
      <xs:attribute name="forcecontroloff" type="trueFalseType" default="false" />
      <xs:attribute name="hidden" type="yesNoType" default="no" />
      <xs:attribute name="positionable" type="trueFalseType" />
      <xs:attribute name="showtooltip" type="trueFalseType" default="true" />
      <xs:attribute name="editable" type="trueFalseType" default="true" />
    </xs:attributeGroup>

    <xs:complexType name="EditorPositionableLabelType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a PositionableLabel
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.PositionableLabelXml
        </xs:appinfo>
      </xs:annotation>
      <xs:sequence>
        <xs:element name="toolTip" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="icon" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="fixedWidth" type="xs:string" />
      <xs:attribute name="fixedHeight" type="xs:string" />
      <xs:attribute name="rotate" type="xs:string" />
      <xs:attribute name="icon" type="xs:string" />
      <xs:attribute name="text" type="xs:string" />
      <xs:attribute name="size" type="xs:string" />
      <xs:attribute name="style" type="xs:string" />
      <xs:attribute name="margin" type="xs:int" />
      <xs:attribute name="red" type="xs:int" />
      <xs:attribute name="green" type="xs:int" />
      <xs:attribute name="blue" type="xs:int" />
      <xs:attribute name="redBack" type="xs:int" />
      <xs:attribute name="greenBack" type="xs:int" />
      <xs:attribute name="blueBack" type="xs:int" />
      <xs:attribute name="borderSize" type="xs:int" />
      <xs:attribute name="redBorder" type="xs:int" />
      <xs:attribute name="greenBorder" type="xs:int" />
      <xs:attribute name="blueBorder" type="xs:int" />
      <xs:attribute name="justification" default="left" >
        <xs:simpleType>
          <xs:restriction base="xs:token">
            <xs:enumeration value="left"/>
            <xs:enumeration value="centre"/>
            <xs:enumeration value="right"/>
          </xs:restriction>
        </xs:simpleType>
      </xs:attribute>
      <xs:attribute name="fixed" type="trueFalseType" />

      <xs:attribute name="height" type="xs:integer" >
        <xs:annotation><xs:documentation>
          Deprecated since JMRI 2.2
        </xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="width" type="xs:integer" >
        <xs:annotation><xs:documentation>
          Deprecated since JMRI 2.2
        </xs:documentation></xs:annotation>
      </xs:attribute>

    </xs:complexType>
    
    <xs:complexType name="EditorPositionablePointType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a PositionablePoint
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.PositionablePointXml
        </xs:appinfo>
      </xs:annotation>

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="ident" type="xs:string" use="required" />
      <xs:attribute name="type" type="xs:string" use="required" />
      <xs:attribute name="x" type="xs:float" use="required" />
      <xs:attribute name="y" type="xs:float" use="required" />
      <xs:attribute name="connect1name" type="xs:string" />
      <xs:attribute name="connect2name" type="xs:string" />
      <xs:attribute name="eastboundsignal" type="xs:string" />
      <xs:attribute name="westboundsignal" type="xs:string" />
      <xs:attribute name="eastboundsignalmast" type="xs:string" />
      <xs:attribute name="westboundsignalmast" type="xs:string" />
      <xs:attribute name="eastboundsensor" type="xs:string" />
      <xs:attribute name="westboundsensor" type="xs:string" />

    </xs:complexType>
    
    <xs:complexType name="EditorSensorIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a SensorIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.SensorIconXml
        </xs:appinfo>
      </xs:annotation>
      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="toolTip" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="icon" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="active" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="inactive" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="inconsistent" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="unknown" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="iconmaps" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="activeText" type="EditorTextInfoType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="inactiveText" type="EditorTextInfoType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="unknownText" type="EditorTextInfoType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="inconsistentText" type="EditorTextInfoType" minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="sensor" type="beanNameType" />
      <xs:attribute name="momentary" type="trueFalseType" />
      <xs:attribute name="icon" type="xs:string" />
      <xs:attribute name="text" type="xs:string" />
      <xs:attribute name="rotate" type="xs:string" />
      <xs:attribute name="sxscale" type="xs:string" />
      <xs:attribute name="sxorigin" type="xs:string" />
      <xs:attribute name="syscale" type="xs:string" />
      <xs:attribute name="syorigin" type="xs:string" />
      <xs:attribute name="filter" type="xs:string" />
      <xs:attribute name="showid" type="trueFalseType" />
      <xs:attribute name="fixed" type="trueFalseType" />
      <xs:attribute name="borderSize" type="xs:string" />
      <xs:attribute name="redBorder" type="xs:int" />
      <xs:attribute name="greenBorder" type="xs:int" />
      <xs:attribute name="blueBorder" type="xs:int" />
      <xs:attribute name="size" type="xs:string" />
      <xs:attribute name="style" type="xs:string" />
      <xs:attribute name="margin" type="xs:int" />
      <xs:attribute name="fixedWidth" type="xs:string" />
      <xs:attribute name="fixedHeight" type="xs:string" />
      <xs:attribute name="selectable" type="xs:string" />
      <xs:attribute name="defaulticon" type="xs:string" />
      
      <xs:attribute name="justification" default="left" >
        <xs:simpleType>
          <xs:restriction base="xs:token">
            <xs:enumeration value="left"/>
            <xs:enumeration value="centre"/>
            <xs:enumeration value="right"/>
          </xs:restriction>
        </xs:simpleType>
      </xs:attribute>
      
      <xs:attribute name="red" type="xs:int" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="green" type="xs:int" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blue" type="xs:int" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>

      <xs:attribute name="height" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="width" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="active" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="inactive" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="unknown" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="inconsistent" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="activeText" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="inactiveText" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="unknownText" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="inconsistentText" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>

      <xs:attribute name="redBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redActiveBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenActiveBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueActiveBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redInActiveBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenInActiveBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueInActiveBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redUnknownBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenUnknownBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueUnknownBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redInconsistentBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenInconsistentBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueInconsistentBack" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redActive" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenActive" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueActive" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redInActive" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenInActive" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueInActive" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redUnknown" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenUnknown" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueUnknown" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
        
      <xs:attribute name="redInconsistent" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="greenInconsistent" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="blueInconsistent" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>        

    </xs:complexType>

    <xs:complexType name="EditorReporterIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a ReporterIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.ReporterIconXml
        </xs:appinfo>
      </xs:annotation>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      
      <xs:attribute name="rotate" type="xs:string" />
      <xs:attribute name="text" type="xs:string" />
      <xs:attribute name="size" type="xs:string" />
      <xs:attribute name="style" type="xs:string" />
      <xs:attribute name="red" type="xs:int" />
      <xs:attribute name="green" type="xs:int" />
      <xs:attribute name="blue" type="xs:int" />
      <xs:attribute name="reporter" type="beanNameType" />

      <xs:attribute name="height" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="width" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>

    </xs:complexType>

    <xs:complexType name="EditorMemoryIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a ReporterIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.ReporterIconXml
        </xs:appinfo>
      </xs:annotation>

      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="toolTip" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="memorystate" minOccurs="0" maxOccurs="unbounded">
          <xs:complexType>
            <xs:attribute name="value" type="xs:string" use="required" />
            <xs:attribute name="icon" type="xs:string" use="required" />
          </xs:complexType>
        </xs:element>
      </xs:sequence>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="size" type="xs:string" />
      <xs:attribute name="style" type="xs:string" />
      <xs:attribute name="red" type="xs:int" />
      <xs:attribute name="green" type="xs:int" />
      <xs:attribute name="blue" type="xs:int" />
      <xs:attribute name="rotate" type="xs:string" />
      <xs:attribute name="memory" type="beanNameType" />
      <xs:attribute name="defaulticon" type="xs:string" />
      <xs:attribute name="selectable" type="yesNoType" />
      <xs:attribute name="fixedHeight" type="xs:string" />
      <xs:attribute name="fixedWidth" type="xs:string" />
      <xs:attribute name="margin" type="xs:int" />
      <xs:attribute name="redBack" type="xs:int" />
      <xs:attribute name="greenBack" type="xs:int" />
      <xs:attribute name="blueBack" type="xs:int" />
      <xs:attribute name="borderSize" type="xs:string" />
      <xs:attribute name="redBorder" type="xs:int" />
      <xs:attribute name="greenBorder" type="xs:int" />
      <xs:attribute name="blueBorder" type="xs:int" />
      <xs:attribute name="justification" default="left" >
        <xs:simpleType>
          <xs:restriction base="xs:token">
            <xs:enumeration value="left"/>
            <xs:enumeration value="centre"/>
            <xs:enumeration value="right"/>
          </xs:restriction>
        </xs:simpleType>
      </xs:attribute>

      <xs:attribute name="height" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="width" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>

    </xs:complexType>

    <xs:complexType name="EditorFastClockIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a FastClock
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.FastClockXml
        </xs:appinfo>
      </xs:annotation>

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="x" type="xs:int" use="required" />
      <xs:attribute name="y" type="xs:int" use="required" />
      <xs:attribute name="scale" type="xs:float" use="required" />
 
    </xs:complexType>

    <xs:complexType name="EditorMultiSensorIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a MultiSensorIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.MultiSensorIconXml
        </xs:appinfo>
      </xs:annotation>

      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="multisensoriconentry" minOccurs="0" maxOccurs="unbounded" >
          <xs:complexType>
            <xs:attribute name="sensor" type="beanNameType" use="required" />
            <xs:attribute name="icon" type="xs:string" use="required" />
          </xs:complexType>
        </xs:element>
        <xs:element name="active" minOccurs="0" maxOccurs="unbounded" >
          <xs:complexType>
          <xs:complexContent>
            <xs:extension base="EditorIconType">
              <xs:attribute name="sensor" type="beanNameType" />
            </xs:extension>
          </xs:complexContent>
          </xs:complexType>
        </xs:element>
        <xs:element name="inactive" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="inconsistent" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="unknown" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="updown" type="xs:string" />

      <xs:attribute name="active" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="inactive" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="unknown" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="inconsistent" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="rotate" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
    </xs:complexType>

    <xs:complexType name="EditorSignalHeadIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a SignalHeadIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.SignalHeadIconXml
        </xs:appinfo>
      </xs:annotation>

      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="toolTip" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="icons" minOccurs="0" maxOccurs="1" >
          <xs:complexType>
            <xs:all>
                <xs:element name="held" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="dark" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="red" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="yellow" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="green" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="lunar" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="flashred" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="flashyellow" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="flashgreen" type="EditorIconType" minOccurs="0" maxOccurs="1" />
                <xs:element name="flashlunar" type="EditorIconType" minOccurs="0" maxOccurs="1" />
            </xs:all>
           </xs:complexType>
        </xs:element>
        <xs:element name="iconmaps" type="xs:string" minOccurs="0" maxOccurs="1"/>
        <xs:element name="held" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="dark" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" >
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="red" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="yellow" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="green" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="lunar" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="flashred" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="flashyellow" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="flashgreen" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
        <xs:element name="flashlunar" type="EditorIconType" minOccurs="0" maxOccurs="unbounded">
            <xs:annotation><xs:documentation>Deprecated</xs:documentation></xs:annotation>
        </xs:element>
      </xs:sequence>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="rotate" type="xs:string" />
      <xs:attribute name="signalhead" type="beanNameType" />
      <xs:attribute name="clickmode" type="xs:string" />
      <xs:attribute name="litmode" type="xs:string" />

      <xs:attribute name="held" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="dark" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="red" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="flashred" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="yellow" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="flashyellow" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="green" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="flashgreen" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="lunar" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="flashlunar" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="heldicon" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>

      <xs:attribute name="height" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="width" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
    </xs:complexType>

    <xs:complexType name="EditorSignalMastIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a SignalMastIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.SignalMastIconXml
        </xs:appinfo>
      </xs:annotation>

      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="toolTip" type="xs:string" minOccurs="0" maxOccurs="1" />
      </xs:sequence>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="signalmast" type="xs:string" />
      <xs:attribute name="rotate" type="xs:string" />
      <xs:attribute name="degrees" type="xs:string" />
      <xs:attribute name="scale" type="xs:string" />
      <xs:attribute name="clickmode" type="xs:string" />
      <xs:attribute name="litmode" type="xs:string" />
      <xs:attribute name="imageset" type="xs:string" />

    </xs:complexType>
    
    <xs:complexType name="EditorTurnoutIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a TurnoutIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.TurnoutIconXml
        </xs:appinfo>
      </xs:annotation>

      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="toolTip" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="icons" minOccurs="0" maxOccurs="unbounded" >
          <xs:complexType>
            <xs:sequence>
              <xs:element name="closed" minOccurs="0" maxOccurs="1">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="rotation" type="xs:string" />
                  </xs:sequence>
                  <xs:attribute name="url" type="xs:string"/>
                  <xs:attribute name="degrees" type="xs:string"/>
                  <xs:attribute name="scale" type="xs:string"/>
                </xs:complexType>
              </xs:element>
              <xs:element name="thrown" minOccurs="0" maxOccurs="1">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="rotation" type="xs:string" />
                  </xs:sequence>
                  <xs:attribute name="url" type="xs:string"/>
                  <xs:attribute name="degrees" type="xs:string"/>
                  <xs:attribute name="scale" type="xs:string"/>
                </xs:complexType>
              </xs:element>
              <xs:element name="unknown" minOccurs="0" maxOccurs="1">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="rotation" type="xs:string" />
                  </xs:sequence>
                  <xs:attribute name="url" type="xs:string"/>
                  <xs:attribute name="degrees" type="xs:string"/>
                  <xs:attribute name="scale" type="xs:string"/>
                </xs:complexType>
              </xs:element>
              <xs:element name="inconsistent" minOccurs="0" maxOccurs="1">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="rotation" type="xs:string" />
                  </xs:sequence>
                  <xs:attribute name="url" type="xs:string"/>
                  <xs:attribute name="degrees" type="xs:string"/>
                  <xs:attribute name="scale" type="xs:string"/>
                </xs:complexType>
              </xs:element>
            </xs:sequence>
          </xs:complexType>
        </xs:element>
        <xs:element name="iconmaps" minOccurs="0" maxOccurs="1">
          <xs:complexType>
          </xs:complexType>
        </xs:element>
        <xs:element name="closed" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="thrown" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="unknown" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
        <xs:element name="inconsistent" type="EditorIconType" minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="turnout" type="beanNameType" />
      <xs:attribute name="rotate" type="xs:string" />
      <xs:attribute name="tristate" type="trueFalseType" />

      <xs:attribute name="height" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="width" type="xs:integer" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="closed" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="thrown" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="unknown" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>
      <xs:attribute name="inconsistent" type="xs:string" >
        <xs:annotation><xs:documentation>Deprecated since JMRI 2.8</xs:documentation></xs:annotation>
      </xs:attribute>

    </xs:complexType>

    <xs:complexType name="EditorLayoutTurnoutType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a LayoutTurnout
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.LayoutTurnoutXml
        </xs:appinfo>
      </xs:annotation>
      
      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="signalAMast" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="signalBMast" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="signalCMast" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="sensorA" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="sensorB" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="sensorC" type="xs:string" minOccurs="0" maxOccurs="1" />
      </xs:sequence>

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="ident" type="xs:string" use="required" />
      <xs:attribute name="type" type="xs:string" use="required" />
      <xs:attribute name="continuing" type="xs:string" use="required" />

      <xs:attribute name="xb" type="xs:float" use="required" />
      <xs:attribute name="xc" type="xs:float" use="required" />
      <xs:attribute name="xcen" type="xs:float" use="required" />
      <xs:attribute name="yb" type="xs:float" use="required" />
      <xs:attribute name="yc" type="xs:float" use="required" />
      <xs:attribute name="ycen" type="xs:float" use="required" />

      <xs:attribute name="disabled" type="yesNoType" />
      <xs:attribute name="disableWhenOccupied" type="yesNoType" />

      <xs:attribute name="turnoutname" type="beanNameType" />
      <xs:attribute name="blockname" type="beanNameType" />
      <xs:attribute name="blockbname" type="beanNameType" />
      <xs:attribute name="blockcname" type="beanNameType" />
      <xs:attribute name="blockdname" type="beanNameType" />
      <xs:attribute name="connectaname" type="beanNameType" />
      <xs:attribute name="connectbname" type="beanNameType" />
      <xs:attribute name="connectcname" type="beanNameType" />
      <xs:attribute name="connectdname" type="beanNameType" />
      <xs:attribute name="signala1name" type="beanNameType" />
      <xs:attribute name="signala2name" type="beanNameType" />
      <xs:attribute name="signala3name" type="beanNameType" />
      <xs:attribute name="signalb1name" type="beanNameType" />
      <xs:attribute name="signalb2name" type="beanNameType" />
      <xs:attribute name="signalc1name" type="beanNameType" />
      <xs:attribute name="signalc2name" type="beanNameType" />
      <xs:attribute name="signald1name" type="beanNameType" />
      <xs:attribute name="signald2name" type="beanNameType" />
      <xs:attribute name="linkedturnoutname" type="beanNameType" />
      <xs:attribute name="linktype" type="xs:string" />

    </xs:complexType>

    <xs:complexType name="EditorLocoIconType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a LocoIcon
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.LocoIconXML??
        </xs:appinfo>
      </xs:annotation>

      <xs:attributeGroup ref="EditorCommonAttributesGroup" />

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="icon" type="xs:string" />
      <xs:attribute name="text" type="xs:string" />
      <xs:attribute name="size" type="xs:string" />
      <xs:attribute name="style" type="xs:string" />
      <xs:attribute name="red" type="xs:int" />
      <xs:attribute name="green" type="xs:int" />
      <xs:attribute name="blue" type="xs:int" />

    </xs:complexType>

    <xs:complexType name="EditorTrackSegmentType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a TrackSegment
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.TrackSegmentXml
        </xs:appinfo>
      </xs:annotation>

      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="ident" type="xs:string" use="required" />
      <xs:attribute name="blockname" type="beanNameType"/>  <!-- required in DTD, missing from some files -->
      <xs:attribute name="connect1name" type="beanNameType" use="required" />
      <xs:attribute name="type1" type="xs:string" use="required" />
      <xs:attribute name="connect2name" type="beanNameType" use="required" />
      <xs:attribute name="type2" type="xs:string" use="required" />
      <xs:attribute name="dashed" type="yesNoType" />
      <xs:attribute name="mainline" type="yesNoType" />
      <xs:attribute name="hidden" type="yesNoType" />
      <xs:attribute name="arc" type="yesNoType" />
      <xs:attribute name="flip" type="yesNoType" />
      <xs:attribute name="circle" type="yesNoType" />
      <xs:attribute name="angle" type="xs:float" />

    </xs:complexType>

    <xs:complexType name="EditorLevelXingType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a LevelXing
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.LevelXingXml
        </xs:appinfo>
      </xs:annotation>

      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="signalAMast" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="signalBMast" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="signalCMast" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="signalDMast" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="sensorA" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="sensorB" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="sensorC" type="xs:string" minOccurs="0" maxOccurs="1" />
        <xs:element name="sensorD" type="xs:string" minOccurs="0" maxOccurs="1" />
      </xs:sequence>
      <xs:attribute name="class" type="classType" use="required" />
      <xs:attribute name="ident" type="xs:string" use="required" />

      <xs:attribute name="blocknameac" type="beanNameType" />
      <xs:attribute name="blocknamebd" type="beanNameType" />
      <xs:attribute name="signal1aname" type="beanNameType" />
      <xs:attribute name="signal1bname" type="beanNameType" />
      <xs:attribute name="signal1cname" type="beanNameType" />
      <xs:attribute name="signal1dname" type="beanNameType" />
      <xs:attribute name="connectaname" type="beanNameType" />
      <xs:attribute name="connectbname" type="beanNameType" />
      <xs:attribute name="connectcname" type="beanNameType" />
      <xs:attribute name="connectdname" type="beanNameType" />
      <xs:attribute name="xb" type="xs:float" use="required" />
      <xs:attribute name="xc" type="xs:float" />    <!-- required in DTD, missing from some files -->
      <xs:attribute name="xcen" type="xs:float" use="required" />
      <xs:attribute name="yb" type="xs:float" use="required" />
      <xs:attribute name="yc" type="xs:float" />    <!-- required in DTD, missing from some files -->
      <xs:attribute name="ycen" type="xs:float" use="required" />

      <xs:attribute name="signalaname" type="beanNameType" /> <!-- not in DTD, found in files -->
      <xs:attribute name="signalbname" type="beanNameType" /> <!-- not in DTD, found in files -->
      <xs:attribute name="signalcname" type="beanNameType" /> <!-- not in DTD, found in files -->
      <xs:attribute name="signaldname" type="beanNameType" /> <!-- not in DTD, found in files -->
      <xs:attribute name="xa" type="xs:float" />              <!-- not in DTD, found in files -->
      <xs:attribute name="ya" type="xs:float" />              <!-- not in DTD, found in files -->

    </xs:complexType>

    <xs:complexType name="EditorLayoutTurntableType">
      <xs:annotation>
        <xs:documentation>
          Define the XML stucture for storing a LayoutTurntable.
          (Not present in 2.9.3 DTD, done by observation)
        </xs:documentation>
        <xs:appinfo>
          jmri.jmrit.display.configurexml.??
        </xs:appinfo>
      </xs:annotation>

      <xs:sequence minOccurs="0" maxOccurs="unbounded">
        <xs:element name="raytrack" minOccurs="0" maxOccurs="unbounded">
          <xs:complexType>
            <xs:attribute name="connectname" type="xs:string" />
            <xs:attribute name="angle" type="xs:string" />
            <xs:attribute name="index" type="xs:string" />
          </xs:complexType>
        </xs:element>
      </xs:sequence>

      <xs:attribute name="class" type="xs:string" use="required" />
      <xs:attribute name="ident" type="xs:string" use="required" />
      <xs:attribute name="radius" type="xs:float" use="required" />
      <xs:attribute name="xcen" type="xs:float" use="required" />
      <xs:attribute name="ycen" type="xs:float" use="required" />

    </xs:complexType>

</xs:schema>

