# $style[] Columns

In case we want to change the look of the columns of the descendant fields' of a field marked as being the ascendant of other fields, we can use the options dualColumn, singleColumn, or column of the $style keyword. Please note that both singleColumn and column cannot be used on a field whose parent does not include the $style keyword with the dualColumn option.

# $style[dualColumn]

This option allows you to display in an instance the fields descending from others in two columns. In case the browser window is large enough, the fields descending from an ascending field will be displayed in pairs, side by side (left and right). Otherwise they will be displayed in a single column.

TIP

Note that fields descended from a field with the $style keyword and the dualColumn option are displayed in an instance in order of insertion into the definition.

The effect of applying the dualColumn option to the drop-down fields of Audit Info and Phases can be seen in the screenshot included below:

# $style[singleColumn]

Although the descendant fields of a field are by default displayed in a single column, this option is commonly used in a field with a parent field of type $style[dualColumn] and you wish to differentiate the appearance of this particular descendant field from the appearance of the other descendant fields. This is the example of the Phases SLA (in hours) field in the above example, which although it descends from Phases, is displayed in a single column, with no pair:

For the user, the visible result will be similar to the one in the image below:

# $style[column]

In case we want the fields descending from a field with the $style keyword and the dualColumn option to be displayed not in order of insertion into a definition but by thematic groups, we can use the $style keyword with the column option on two fields with the $group keyword. Being mere separators with no value, these fields will not be visible in an instance. Each of the descendant fields of one of the $group fields will then be presented in pairs, side by side - in a different column - with the respective descendant field of the other $group field.

In the example below, we can see that the User Info and Time Info field groups of type group are also characterized with the $style[column] keyword. Both of these field groups are descendants of the Audit Info field which is itself characterized with the $style[dualColumn] keyword. This means that the fields grouped within each of these containers will in turn be displayed within a single column.

The output of this design option will be as follows: