• about
  • features
  • examples
  • requirements
  • download
  • installation
  • contact
  • SourceForge

  • SourceForge Logo

    example :: wizard-like dialog

    I assume that you have already taken a look at the simple dialog example, so I won't bore you with the details of assembling a test frame and compiling again. Here is the source of our wizard example:

    Xorph source code

    <?xml version="1.0" encoding="UTF-8"?>
    <xorph:environment name="SimpleWizardEnvironment" 
            <group label="Player Information" name="PlayerInfo">
                <option label="Player Name" name="Name">
                    <text case="any" defaultValue="Player 1"/>
                    <description>Enter the name of your in-game character here.</description>
                <option label="Real Name" name="RealName">
                    <text case="any" defaultValue="Your Real Name Here"/>
                    <description>Enter your real name here.</description>
                <option label="Password" name="Password">
                    <text case="any" password="true"/>
                    <description>Please enter your game password here.</description>
            <group label="Game Settings" name="GameSettings">
                <option label="Skill Level" name="SkillLevel">
                    <selectNumeric standardDisplay="radiobuttons" defaultValue="2">
                            <value label="Beginner" value="1"/>
                            <value label="Intermediate" value="2"/>
                            <value label="Expert" value="3"/>
                    <description>Select your experience level.</description>
                <option label="Start Level" name="StartLevel">
                	<numeric minValue="1" maxValue="50" />
                	<description>Select the level you'd like the game to start with.</description>
        <interface name="SetupWizard" title="Game Setup Wizard">
                <page name="WizPlayer" label="Player Information">
                    <text>Please enter the following information in order to start the game.</text>
                    <includeGroup name="PlayerInfo" withFrame="false"/>
                <page name="WizGame" label="Game Settings">
                    <text>Now select your preferred game settings.</text>
                    <includeOption name="StartLevel" />
                    <includeOption name="SkillLevel" display="listbox" />
                <page name="WizFinal" label="Game Setup Completed">
                    <text>Good luck!</text>


    The generated wizard consists of three pages that look like this:

    first page
    second page
    third page

    © 2005 Volker Wegert