Tobago Demo

Menu

Sheet

The sheet control is a simple solution for displaying table based information. The essential features are:
  • Sorting
  • Paging
  • Tree table
  • Inline editing
  • Column resizing
  • Inline-Editing
  • Styling
  • Header customization
This example shows an application specific sorter, which sorts the sun to the top every time.

A <tc:sheet/> tag can contain any number of <tc:column/> tags. The <tc:column/> tag is a container, which may contain output fields, labels, progress bars or even tab groups.

Tag Library Documentation: <tc:sheet/> | <tc:column/>

Basics

Two attributes should be recognized in a sheet. The data of the sheet is set in the value attribute. The variablename of a single entry is set by the var attribute, which can be used in the <tc:column/> tags. In this example, also the rows attribute is set. So only four rows are shown at a time.

In most cases, you should set labelLayout="skip" for components which have usually a label. Otherwise those components have a negative affect on the proportion of the sheet.
For components with a label the attribute margin-bottom is set. The margin is add to the height of a row.

<tc:sheet value="#{sheetController.solarList}" var="solarobject" rows="4"> <tc:column label="Name"> <tc:out value="#{solarobject.name}" labelLayout="skip"/> ...
Name Orbit Period (Days) Discoverer Year
Sun - 0.0 -
Mercury Sun 87.97 -
Venus Sun 224.7 -
Earth Sun 365.26 -
  • Rows 1 to 4 of 88
  • Page 1 of 22
© 2005-2023 Apache Software Foundation, Licensed under the Apache License, Version 2.0.