Skip to Main Content Skip to Search
Product Documentation

Working with Property Table Components

About Property Table Components

Property Table components display property name/property value pairs for objects in tables. This appears in the following example table from the figloop-tutorial report.

Many types of Property Table components are available, including:

The component used in this example represents MATLAB Report Generator Property Table components, all of which exhibit similar behavior.

Opening the Example Report Template

This example uses the figloop-tutorial report template. To open the figure loop tutorial report template, enter the following at the MATLAB command line:

setedit figloop-tutorial

Examining the Property Table Output

Property pages for all Property Table components are similar in form. In the Outline pane, select the Figure Prop Table component. To modify table settings, in the Handle Graphics Property Table dialog box, click the Edit... button.

Selecting Object Types

Property Table components offer multiple object types on which to report. For example, the Handle Graphics Property table lets you report on a figure, an axes object, or a Handle Graphics object.

You can select a different object type on which to report in the Object type list in the component's Properties pane.

Displaying Property Name/Property Value Pairs

Splitting Property/Value Cells

  1. In the Properties pane for the Handle Graphics Property Table component, clear the Split property/value cells check box.

  2. Click Edit. The table is now in nonsplit mode. Nonsplit mode supports more than one property name/property value pair per cell and text.

  3. For the property name and property value to appear in adjacent horizontal cells in the table, select the Split property/value cells check box. The table is now in split mode. Split mode supports only one property name/property value pair per cell. If more than one property pair appears in a cell, only the first pair appears in the report; all subsequent pairs are ignored.

Display Options

Property name/property value pairs can appear in cells in several ways. To specify how a given property name/property value pair appears in a cell, select that field in the table (for this tutorial, select the Name property). Choose Value from the display options drop-down list at the bottom of the dialog box. In the selected table row, only the value appears.

Formatting Options

To specify alignment for text in a given cell, use the four justification buttons in the toolbar at the bottom of the dialog box.

Select the HandleVisibility table row. Then select the double-justify button (the last button to the right).

Editing Table Titles

Table titles can contain properties and text. By default, the title of a table is the same as the value of the %<Name> property. You can modify this property to modify the table title.

Entering Text into Table Cells

For the text to be visible, the table must be in nonsplit mode. Clear Split property/value cells.

To enter text into the HandleVisibility table cell, double-click the cell. A gray box appears with the label for the cell property.

If you type text outside the angle brackets, the text appears as is in the report. Text inside the table brackets must specify a valid property name. If you enter an invalid property name, the property name appears in the report without a property value.

Adding, Replacing, and Deleting Properties in Tables

Adding Table Properties

To add a Handle Graphics property to a table:

  1. In the Figure Prop Table window, select a table row above which you want add a new property.

  2. Click the Add Row Above Current Cell button

    A new row appears above the current row.

  3. Add the property to the new table row.

    1. Select the new table row.

    2. In the Properties Type drop-down list at the upper-right of the dialog box, select a property type.

    3. In the Properties list, select the property you want to add.

    4. Click the << Add button, or double-click the property name. The property appears in the table row.

    Alternatively, if you know the name of the property you want to add, enter the property name directly into the cell as described in Entering Text into Table Cells. For information about adding new table rows, see Adding and Deleting Columns and Rows.

Replacing Table Properties

To replace a property in a cell of a table in split mode, follow the instructions in Adding Table Properties.

Deleting Table Properties

Delete a property by backspacing over it or using the Delete key.

Displaying or Hiding Cell Borders

To toggle cell borders on and off:

  1. Place your cursor in a cell and right-click to invoke its context menu.

  2. Choose Cell borders > Top, Bottom, Right, or Left to toggle the specified border on or off.

Adding and Deleting Columns and Rows

To add or delete a column or row, select a cell and then click one of the buttons described in the following table.

Button 

Action

Add column (added to the left of the selected column)

Delete selected column

Add row (added above the selected row)

Delete selected row

Resizing Columns

To resize the width of a column, click and drag its vertical borders as needed.

Merging and Splitting Cells

To merge or split table cells, select a row and then click one of the buttons described in the following table.

Button 

Action

Merge cells downward

Merge cells to the right

Split cells

Zooming and Scrolling

Zooming

You can zoom in and out of the table with the zoom buttons, which are located to the left of the horizontal scroll bar.

Button

Action

Zoom in

Zoom out

Scrolling

You can scroll vertically and horizontally using the table's scroll bars.

Selecting Tables

To display property name/property value pairs, you can select a preset table or use a custom table.

  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS