Maplets[Elements] - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Maplets : Elements : Window Body Elements : Maplets/Elements/Table

Maplets[Elements]

  

Table

  

encapsulate a table definition

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

Table(opts, element_content)

Table[refID](opts, element_content)

Parameters

opts

-

equation(s) of the form option=value where option is one of background, font, foreground, height, reference, tooltip, visible, or width; specify options for the Table element

element_content

-

exactly one TableHeader element and any number of TableRow elements

refID

-

name or string; reference to the element

Description

• 

The Table window body element encapsulates a Maplet application table definition.

  

 

  

Note: The table header is displayed only if the table is specified in a scroll pane, that is, a BoxCell or GridCell element with the 'vscroll' = 'as_needed' option. Otherwise, the header is not displayed. To construct a table with no header, specify a header, but do not place the table in a scroll pane.

• 

The Table element features can be modified by using options.  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

 

 

list of lists

content of table body

list

content of the table header

range of positive integers

height and width options, respectively

refID

reference option

• 

A Table element must contain exactly one TableHeader element and any number of TableRow elements. A Table element can contain a Font element to specify the font option.

• 

A Table element can be contained in a Maplet, BoxCell, or GridCell element, or Maplet element in a nested list representing a box layout.

• 

The following table describes the control and use of the Table 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

 

 

 

 

 

background

x

 

x

x

font

x

 

 

x

foreground

x

 

x

x

height

x

 

x

x

reference

x

 

 

 

tooltip

x

 

 

x

visible

x

 

x

x

width

x

 

x

x

 

 

 

 

 

• 

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

  

 

  

background = color

  

The default background color of the table body. This can be a recognized color name, an RGB color structure, or a string of the form "#RRGGBB" where each pair is a two-digit hexadecimal number. For selected rows, the background color is always light blue. For the table header, the background color is always gray.

  

 

  

font = Font element or reference to a Font element (name or string)

  

The font of the table text.

  

 

  

foreground = color

  

The text color for the contents in the table body. For selected rows and the table header, the foreground color is always black.

  

 

  

height = posint

  

The table height in pixels.  By default, this depends upon the entries in the table.

  

 

  

reference = name or string

  

A reference to the Table element.

  

If the reference is specified by both an index, for example, Table[refID], and a reference in the calling sequence, the index reference takes precedence.

  

 

  

tooltip = string or symbol

  

The text that appears in the tooltip window.

  

 

  

visible = true or false

  

Whether the table is visible to the user.  By default, the value is true.

  

 

  

width = posint

  

The table width in pixels.  By default, this depends upon the entries in the table.

Examples

withMaplets[Elements]:

maplet1MapletBoxCellTableA,B,1,2,3,4,'as_needed',ButtonOK,Shutdown:

Maplets[Display]maplet1

maplet2MapletGridLayoutGridRowGridCellTableA,B,1,2,3,4,'as_needed',GridRowGridCellButtonOK,Shutdown:

Maplets[Display]maplet2

See Also

Maplets/WindowBodyElements

Maplets[Display]

Maplets[Elements]

Maplets[Elements][BoxCell]

Maplets[Elements][Button]

Maplets[Elements][Font]

Maplets[Elements][GridCell]

Maplets[Elements][GridLayout]

Maplets[Elements][GridRow]

Maplets[Elements][Maplet]

Maplets[Elements][SetOption]

Maplets[Elements][TableHeader]

Maplets[Elements][TableItem]

Maplets[Elements][TableRow]

Maplets[Tools][Get]

Maplets[Tools][Set]

Overview of Maplet Applications

 


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