Maplets[Elements] - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Maplets : Elements : Command Elements : Maplets/Elements/RunWindow

Maplets[Elements]

  

RunWindow

  

display a window

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

RunWindow(opts)

Parameters

opts

-

equation(s) of the form window=value; specify options for the RunWindow element

Description

• 

The RunWindow command element displays a window defined in the running Maplet application. To display a window defined in a different Maplet application, use the Display function.

• 

There are separate RunDialog and RunWindow command elements because the Window element is intrinsically different from the dialog elements. A dialog has a predefined structure. A Maplet application author can specify options for a dialog, but cannot add elements. A window does not have a predefined structure. A Maplet application author specifies its structure by using elements and options. Also they behave differently. For example, a window can be minimized.

• 

To simplify specifying options in the Maplets package, certain options and contents can be set without using an equation. The following table lists elements, symbols, and types (in the left column) and the corresponding option or content (in the right column) to which inputs of this type are, by default, assigned.

Elements, Symbols, or Types

Assumed Option or Content

 

 

name or string

window option

 

 

• 

A RunWindow element cannot contain other elements.

• 

A RunWindow element can be contained in a Maplet element; in an equation for the onapprove, oncancel, onchange, onclick, ondecline, or onstartup option for an element; or wrapped in an Action element as a parameter in an element that accepts an onchange or onclick option without an equation.

• 

The following table describes the control and use of the RunWindow element options.

  

An x in the I column indicates that the option can be initialized, that is, specified in the calling sequence (element definition).

  

An x in the R column indicates that the option is required in the calling sequence.

  

An x in the G column indicates that the option can be read, that is, retrieved by using the Get tool.

  

An x in the S column indicates that the option can be written, that is, set by using the SetOption element or the Set tool.

Option

I

R

G

S

 

 

 

 

 

window

x

x

 

 

 

 

 

 

 

• 

The opts argument can contain one or more of the following equations that set Maplet application options.

  

 

  

window = reference to a Window element (name or string)

  

A reference to the window to run.

• 

Note: In the Standard Worksheet, RunWindow displays a window and sets its parent to be the window that is currently running and enabled. If there are no other windows running, then the window does not have a parent. CloseWindow closes a window and also closes its child windows. In the Classic Worksheet and Command-line interface, RunWindow displays a window, but it does not set a parent.  CloseWindow closes a window. For more information, see compatibility.

Examples

In this Maplet application, RunWindow displays a Window element defined in the same Maplet application.

withMapletsElements:

mapletMapletonstartup=A1,WindowW1title=Differentiation and Integration,layout=BL0,BoxLayoutBL0BoxColumnBoxRowSelect a method,BoxRowButtonDifferentiation,ActionCloseWindowW1,RunWindowW2,ButtonIntegration,ActionCloseWindowW1,RunWindowW3,WindowW2title=Differentiation,Enter an expression:,TextFieldTF1,ButtonDifferentiate with respect to x,EvaluateTF1=diffTF1,x,ButtonExit,ShutdownTF1,WindowW3title=Integration,Enter an integrand:,TextFieldTF2,ButtonIntegrate with respect to x,EvaluateTF2=intTF2,x,ButtonExit,ShutdownTF2,ActionA1RunWindowW1:

MapletsDisplaymaplet

In this Maplet application, Display displays Window elements defined in Maplet applications different from the running Maplet application.

withMapletsElements:

mapletMapletonstartup=A1,WindowW1title=Select Tutorial,layout=BL1,BoxLayoutBL1BoxColumnBoxRowSelect a tutorial,BoxRowButtonDifferentiation,Evaluatefunction=MapletsDisplaymaplet2,ButtonIntegration,Evaluatefunction=MapletsDisplaymaplet3,BoxRowButtonExit,Shutdown,ActionA1RunWindowW1:

maplet2MapletWindowW2title=Differentiation Practice,layout=BL2,BoxLayoutBL2BoxColumnBoxRowEnter an expression:,TextFieldTF1,BoxRow,BoxRowAfter manually calculating the derivative, check your answer by clicking the Differentiate button.,BoxRowButtonDifferentiate with respect to x,EvaluateTF1=diffTF1,x,ButtonReturn to Main Menu,Shutdown:

maplet3MapletWindowW3title=Integration Practice,layout=BL3,BoxLayoutBL3BoxColumnBoxRowEnter an integrand:,TextFieldTF2,BoxRow,BoxRowAfter manually calculating the anti-derivative, check your answer by clicking the Integrate button.,BoxRowButtonIntegrate with respect to x,EvaluateTF2=intTF2,x,ButtonReturn to Main Menu,Shutdown:

MapletsDisplaymaplet

See Also

Maplets/CommandElements

Maplets/DialogElements

Maplets[Display]

Maplets[Elements]

Maplets[Elements][Action]

Maplets[Elements][BoxColumn]

Maplets[Elements][BoxLayout]

Maplets[Elements][BoxRow]

Maplets[Elements][Button]

Maplets[Elements][Evaluate]

Maplets[Elements][Maplet]

Maplets[Elements][RunDialog]

Maplets[Elements][SetOption]

Maplets[Elements][Shutdown]

Maplets[Elements][TextField]

Maplets[Elements][Window]

Maplets[Tools][Get]

Maplets[Tools][Set]

Overview of Maplet Applications