Maplet Application Style Guide - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Applications and Example Worksheets : Maplet applications : examples/MapletsStyleGuide

Maplet Application Style Guide

This document provides recommendations for structuring Maplet application code.  Structuring improves readability of the Maplet application code both by yourself and future Maplet application authors who must maintain or understand the Maplet application.

In writing Maplet applications, follow these guidelines:

1.  Use one element definition per line. If the element definition is short, more than one definition can be used.

2.  Indent each subsequent element or nested list.

3.  Place closing parentheses, brackets of elements, or nested lists at the same level of indentation as the opening line.

4.  Informational elements, such as Fonts and Image, can be defined anywhere. The Maplet application code, however, is easier to read if the information elements are defined first in the Maplet application.

5.  Keep attributes separate from the content of an element.

6.  Place unevaluation quotation marks around any symbols or names being used as option names or references.  Otherwise, if any of the symbols or names are ever assigned, your Maplet application definition will break.

7.  Within a procedure, use the use statement and not the with statement.  If another user runs your code, the with command affects that user's environment, while use does not.

 

Return to Index for Example Worksheets


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam