Text Input and Output
The WizardEngine utilizes the System.TextBox method, with which you can output multi-line text for instructions.
To collect information from the operator, you can use any of the standard input widgets, particularly members of the PTools library. With suitable code, you can also display a tab from a tag's ConfigFolder. Remember to use and check the input trigger for any fields before changing states. Because the trigger values for the standard input widgets are all set in script, you only need one trigger variable, and you can test it for simply being valid.
A good guideline to follow for laying out Wizards is to set the input controls extending 40 pixels to the right of the mid-point, and placing helper text in a TextBox that starts 48 pixels to the right of the mid-point.
The code for this example follows the image. This state also illustrates input validation, where the user must provide an answer for the field, Your Name before they may press Next.
The code for this state follows:
AskDetails [ WTitle = "Enter your details."; Msg = "Please enter your name and, optionally, a few words about yourself."; System.TextBox(Split + 8, BOT - 10, RHS, TOP + 17, Msg, \_DialogFont, 5); GUITransform(0, 1, 1, 0, 1 - LHS, TOP + 55, Split, 1 - (TOP + 10), 1 { Scale whole }, 0, 0, 1, 0 { No movement; visible; reserved }, 0, 0, 0 { Not selectable }, \DialogLibrary.PEditField(#Area, "Your Name", 4 { Text }, 1 { ID }, Trig { trigger }, 1 { view }, 1 { Bevel }, 0 { VAlign }, 1 { AlignTitle }, Invalid {Min}, Invalid {Max}, 1 {PrivNotReqd})); GUITransform(0, 1, 1, 0, 1 - LHS, TOP + 110, Split, 1 - (TOP + 65), 1 { Scale whole }, 0, 0, 1, 0 { No movement; visible; reserved }, 0, 0, 0 { Not selectable }, \DialogLibrary.PEditField(#Description, "Describe yourself", 4 { Text }, 2 { ID }, Trig { trigger }, 1 { view }, 1 { Bevel }, 0 { VAlign }, 1 { AlignTitle }, Invalid {Min}, Invalid {Max}, 1 {PrivNotReqd})); If Move && PickValid(Trig != 0, 1); [ IfThen(Move == Forward, Engine\Trim(&Parms[#Area]); Emsg = Invalid; IfThen(PickValid(Parms[#Area] == "", 1), Emsg = "I do need to know your name."; ); Engine\Error(Emsg); ); Move = 0; ForceState(NextState); ] ]