Embedded Component Enhancements - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : System : Information : Updates : Maple 18 : Embedded Component Enhancements

Interactive Embedded Components

 

• 

New Shortcut Component

• 

Code Edit Region

• 

Ease of Programming with Embedded Components

• 

Text Area Component

• 

Math Expression Component

• 

Toggle Button Component

• 

Video Player Component

• 

Border Control for Components

Embedded Components are the key building pieces for interactive documents in Maple. In Maple 18, many of the core components have been enhanced with new options such as border control, auto-fit of text, and more. With the new password option, text areas can even be turned into a password entry field.

In addition to these updates, there have been a number of enhancements that make authoring interactive documents or Math Apps easier, including major updates to the Explore command and new routines and tools for creating gradeable apps. There is also added support for other languages in the code editor and audio file formats in the video component.

 

New Shortcut Component

Code Edit Region

Ease of Programming with Embedded Components

Text Area Component

Math Expression Component

Toggle Button Component

Video Player Component

Border Control for Components

New Shortcut Component

With the new shortcut component, you can link to new types of content, including MapleCloud documents. You can set this component to display both a caption and an image. Since it is an embedded component, you can use DocumentTools to access or change the properties of the shortcut component.

For more information, see ShortcutComponent.

Code Edit Region

The following options for the Code Edit Region are new:

• 

A show line numbers option.

• 

An automatic text wrapping option.

• 

Use the value property to programmatically retrieve or set the contents of a code edit region.

• 

 Modelica Code Editing: With MapleSim installed, you can specify code language to be either "Maple" or "Modelica".  When this is set to "Modelica", Maple will automatically adapt the keyword highlighting and code layout to match Modelica's conventions.

For more information, see CodeEditRegion.

Ease of Programming with Embedded Components

When programming an interactive document or Math App, you frequently need to refer to a component by name. In the past, if you did not know or could not remember the name, you had to check the component’s properties to find it. Now, in Maple 18, there are much faster ways to insert a component’s name into your code.

• 

Use command completion. Type % into the code editor and then invoke command completion. Maple populates the list with the names of all components in your document, and you can select the one you want.

• 

Copy the component itself and paste it into a code region. Instead of pasting the component, Maple inserts the component’s name.

These new features are available in all code editing environments: the component properties, code edit regions, and in the startup code editor. For more information, see CodeEditRegion.

Text Area Component

The improvements to the text area components include:

• 

You now have the ability to hide the input in a text entry box using the new password property. When this property is set, anything that is typed into the text edit box is displayed as a sequence of black circles, similar to what happens when you enter a password. The actual entered text is still available to Maple, so that when you query the contents of that edit region, Maple will return the string containing what the user actually entered.

• 

In a single-line text area (the default), Enter now runs this component's Action code.

For more information, see TextAreaComponent.

Math Expression Component

There is a new auto-fit option for the contents of a math expression component that resizes the component to fit its contents. For more information, see MathExpressionComponent.

To obtain the unsimplified contents from a math expression component, use InertForm[FromMathContainer].  For more information and examples, see Capture, Manipulate, and Display Precise Mathematical Notation.

Toggle Button Component

You can now programmatically customize the two images used by the toggle button component. For more information, see ToggleButtonComponent.

Video Player Component

The video player component now plays audio files. For more information, see VideoComponent.

Border Control for Components

For a math expression component, text area component, or plot component, a new option allows you to hide the component's border.

For more information, see MathExpressionComponent, TextAreaComponent, and PlotComponent.

See Also

CodeEditRegion

EmbeddedComponents

What's New in Maple 18

Creating Grading Applications

Updates to the Explore command in Maple 18