KubiSolitaire for Windows, Android, and iOS
Schema Definition of the Game File
File Formats > Schema Definition of the Game File
<?xml version="1.0" encoding="utf-8"?>
<!-- edited with XMLSpy v2018 (x64) (http://www.altova.com) (c) by Paul Kubitscheck (KubiConsult) -->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
    <xs:element name="KubiSolitaire">
        <xs:complexType>
            <xs:sequence>
                <xs:element name="Comment" minOccurs="0" maxOccurs="1"/>
                <xs:element name="GameSettings">
                    <xs:complexType>
                        <xs:attribute name="Draw" type="drawType"/>
                        <xs:attribute name="Scoring" type="scoringType"/>
                        <xs:attribute name="PassesMaximum" type="xs:unsignedByte"/>
                        <xs:attribute name="Options" type="xs:string"/>
                    </xs:complexType>
                </xs:element>
                <xs:element name="GameState">
                    <xs:complexType>
                        <xs:attribute name="Status" type="gameStatusType"/>
                        <xs:attribute name="GameTime" type="xs:unsignedInt"/>
                        <xs:attribute name="PassesCount" type="xs:unsignedByte"/>
                        <xs:attribute name="Points" type="xs:int"/>
                        <xs:attribute name="Bankroll" type="xs:int"/>
                        <xs:attribute name="IsStatRecorded" type="xs:boolean"/>
                    </xs:complexType>
                </xs:element>
                <xs:element name="StartStack" type="cardStackType" minOccurs="1" maxOccurs="1"/>
                <xs:element name="WasteStack" type="cardStackType" minOccurs="0" maxOccurs="1"/>
                <xs:element name="FinishStack" type="cardStackType" minOccurs="0" maxOccurs="4"/>
                <xs:element name="TableauStack" type="cardStackType" minOccurs="0" maxOccurs="7"/>
                <xs:element name="UndoStack" minOccurs="0" maxOccurs="1">
                    <xs:complexType>
                        <xs:sequence>
                            <xs:element name="Command" type="commandType" minOccurs="0" maxOccurs="unbounded"/>
                        </xs:sequence>
                    </xs:complexType>
                </xs:element>
                <xs:element name="RedoStack" minOccurs="0" maxOccurs="1">
                    <xs:complexType>
                        <xs:sequence>
                            <xs:element name="Command" type="commandType" minOccurs="0" maxOccurs="unbounded"/>
                        </xs:sequence>
                    </xs:complexType>
                </xs:element>
            </xs:sequence>
        </xs:complexType>
    </xs:element>
    <xs:complexType name="cardCommandType">
        <xs:complexContent>
            <xs:extension base="cardStackType">
                <xs:attribute name="SourceStackIndex" type="indexType" use="required"/>
                <xs:attribute name="TargetStackIndex" type="indexType" use="required"/>
                <xs:attribute name="VisibleCardsCount" type="visibleCardsCountType"/>
            </xs:extension>
        </xs:complexContent>
    </xs:complexType>
    <xs:simpleType name="cardNameType">
        <xs:restriction base="xs:string">
            <xs:enumeration value="Empty"/>
            <xs:enumeration value="ClubsAce"/>
            <xs:enumeration value="ClubsTwo"/>
            <xs:enumeration value="ClubsFour"/>
            <xs:enumeration value="ClubsThree"/>
            <xs:enumeration value="ClubsFive"/>
            <xs:enumeration value="ClubsSix"/>
            <xs:enumeration value="ClubsSeven"/>
            <xs:enumeration value="ClubsEight"/>
            <xs:enumeration value="ClubsNine"/>
            <xs:enumeration value="ClubsTen"/>
            <xs:enumeration value="ClubsJack"/>
            <xs:enumeration value="ClubsQueen"/>
            <xs:enumeration value="ClubsKing"/>
            <xs:enumeration value="DiamondsAce"/>
            <xs:enumeration value="DiamondsTwo"/>
            <xs:enumeration value="DiamondsThree"/>
            <xs:enumeration value="DiamondsFour"/>
            <xs:enumeration value="DiamondsFive"/>
            <xs:enumeration value="DiamondsSix"/>
            <xs:enumeration value="DiamondsSeven"/>
            <xs:enumeration value="DiamondsEight"/>
            <xs:enumeration value="DiamondsNine"/>
            <xs:enumeration value="DiamondsTen"/>
            <xs:enumeration value="DiamondsJack"/>
            <xs:enumeration value="DiamondsQueen"/>
            <xs:enumeration value="DiamondsKing"/>
            <xs:enumeration value="HeartsAce"/>
            <xs:enumeration value="HeartsTwo"/>
            <xs:enumeration value="HeartsThree"/>
            <xs:enumeration value="HeartsFour"/>
            <xs:enumeration value="HeartsFive"/>
            <xs:enumeration value="HeartsSix"/>
            <xs:enumeration value="HeartsSeven"/>
            <xs:enumeration value="HeartsEight"/>
            <xs:enumeration value="HeartsNine"/>
            <xs:enumeration value="HeartsTen"/>
            <xs:enumeration value="HeartsJack"/>
            <xs:enumeration value="HeartsQueen"/>
            <xs:enumeration value="HeartsKing"/>
            <xs:enumeration value="SpadesAce"/>
            <xs:enumeration value="SpadesTwo"/>
            <xs:enumeration value="SpadesThree"/>
            <xs:enumeration value="SpadesFour"/>
            <xs:enumeration value="SpadesFive"/>
            <xs:enumeration value="SpadesSix"/>
            <xs:enumeration value="SpadesSeven"/>
            <xs:enumeration value="SpadesEight"/>
            <xs:enumeration value="SpadesNine"/>
            <xs:enumeration value="SpadesTen"/>
            <xs:enumeration value="SpadesJack"/>
            <xs:enumeration value="SpadesQueen"/>
            <xs:enumeration value="SpadesKing"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:complexType name="cardStackType">
        <xs:sequence>
            <xs:element name="Card" type="cardType" minOccurs="0" maxOccurs="52"/>
        </xs:sequence>
    </xs:complexType>
    <xs:complexType name="cardType">
        <xs:attribute name="Name" type="cardNameType"/>
        <xs:attribute name="FaceDown" type="xs:boolean"/>
    </xs:complexType>
    <xs:complexType name="commandType">
        <xs:choice>
            <xs:element name="TurnCommand" type="cardCommandType"/>
            <xs:element name="DrawCommand" type="cardCommandType"/>
            <xs:element name="DropCommand" type="cardCommandType"/>
            <xs:element name="FlipFaceCommand">
                <xs:complexType>
                    <xs:attribute name="SourceStackIndex" type="indexType" use="required"/>
                </xs:complexType>
            </xs:element>
            <xs:element name="ScoreCommand">
                <xs:complexType>
                    <xs:attribute name="Time" type="xs:int"/>
                    <xs:attribute name="DeltaBankroll" type="xs:int"/>
                    <xs:attribute name="DeltaPoints" type="xs:int"/>
                    <xs:attribute name="DeltaPass" type="xs:int"/>
                    <xs:attribute name="DeltaGamesCount" type="xs:int"/>
                    <xs:attribute name="DeltaWonGamesCount" type="xs:int"/>
                </xs:complexType>
            </xs:element>
        </xs:choice>
    </xs:complexType>
    <xs:simpleType name="drawType">
        <xs:restriction base="xs:string">
            <xs:enumeration value="One"/>
            <xs:enumeration value="Two"/>
            <xs:enumeration value="Three"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:simpleType name="gameStatusType">
        <xs:restriction base="xs:string">
            <xs:enumeration value="Open"/>
            <xs:enumeration value="Lost"/>
            <xs:enumeration value="Won"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:simpleType name="indexType">
        <xs:restriction base="xs:unsignedByte">
            <xs:minInclusive value="0"/>
            <xs:maxInclusive value="12"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:simpleType name="scoringType">
        <xs:restriction base="xs:string">
            <xs:enumeration value="None"/>
            <xs:enumeration value="Games"/>
            <xs:enumeration value="Standard"/>
            <xs:enumeration value="Vegas"/>
        </xs:restriction>
    </xs:simpleType>
    <xs:simpleType name="visibleCardsCountType">
        <xs:restriction base="xs:unsignedByte">
            <xs:minInclusive value="1"/>
            <xs:maxInclusive value="3"/>
        </xs:restriction>
    </xs:simpleType>
</xs:schema>