The matrix layout arranges the UI elements in a table-like manner in a grid structure. It uses predefined cell classes that guarantee appropriate distances between cells in the grid. The vGutter property lets you specify additional horizontal distances easily. You can set these additional distances (known as gutters) with or without separators. In addition, the MatrixLayout can include horizontal separators to separate the rows further, represented by the HorizontalGutter UI element. This type of layout is preferable to the GridLayout, since it makes the layout structure in a container more consistent. Using the interface MatrixHeadData, you can specify the UI element that appears at the start of each new line.
You should avoid using nested matrix layouts. Instead, use RowLayouts wherever possible. The RowLlayout differs from the MatrixLayout in that the content is not organized in table cells – that is, the individual elements are not aligned vertically with each other. Whenever the RowLayout is implemented in an application, performance is better than if a MatrixLayout were used, but the layout flexibility is not compromised. For this reason, you should structure the view and container in horizontal areas as early as possible, using the RowLayout. You should only use the MatrixLayout if you need to display a table and align the elements vertically.
Runtime Class |
CL_WD_MATRIX_LAYOUT |
Properties in the View Designer
Name |
Type |
Initial Value |
Bindable |
ID |
STRING |
(automatic) |
No |
WDY_BOOLEAN |
true |
No |
|
WDY_BOOLEAN |
true |
No |
Layout data is not bindable.
Further properties that can be inherited are defined in the associated higher-level class. The associated interface elements are:
· Layout
For dynamic programming the same properties, events, and aggregations are provided in the View Designer. Bear in mind the different spellings.
Dynamic Programming of Properties
View Designer Name |
Runtime Name |
Type |
STRETCHED_HORIZONTALLY |
WDY_BOOLEAN |
|
STRETCHED_VERTICALLY |
WDY_BOOLEAN |