LayoutDefinition Class TIBCO Spotfire 7.6 API Reference
Defines the layout structure and content to be applied within a Page.
Inheritance Hierarchy

SystemObject
  Spotfire.Dxp.Application.LayoutLayoutDefinition

Namespace: Spotfire.Dxp.Application.Layout
Assembly: Spotfire.Dxp.Application (in Spotfire.Dxp.Application.dll) Version: 25.11.10401.3615 (25.11.10401.3615)
Syntax

C#
public sealed class LayoutDefinition

The LayoutDefinition type exposes the following members.

Constructors

  NameDescription
Public methodLayoutDefinition
Initializes a new instance of the LayoutDefinition class.
Top
Methods

  NameDescription
Public methodAdd
Public methodBeginSideBySideSection
Creates a side-by-side (vertical) section that will be used for subsequent calls to Add(Visual). The section should be ended by calling EndSection.
Public methodBeginStackedSection
Creates a stacked (horizontal) section that will be used for subsequent calls to Add(Visual). The section should be closed by calling EndSection.
Public methodEndSection
Ends the current section. All sections must be ended.
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Top
Remarks

Each BeginStackedSection/BeginSideBySideSection call splits the space available into two sections either vertically or horizontally. Space within a section is divided amongst the visuals that are actually added so if we make five subsections and only add a visual to one of them it will take the entire space of all the sections.
Examples

C#
public void TwoLevelsStartingHorizontally()
{
    // + - + - + - +
    // | 1 | 2 | 3 |
    // + - + - + - +
    // |     4     |
    // + - - - - - +

    Visual v1 = new VisualMock();
    Visual v2 = new VisualMock();
    Visual v3 = new VisualMock();
    Visual v4 = new VisualMock();

    LayoutDefinition ld = new LayoutDefinition();
    ld.BeginStackedSection();
        ld.BeginSideBySideSection();
            ld.Add(v1);
            ld.Add(v2);
            ld.Add(v3);
        ld.EndSection();
        ld.Add(v4);
    ld.EndSection();
}
public void ThreeLevelsStartingVertically()
{
    // + - - - + - + - +
    // |       |   2   |
    // |       + - + - +
    // |   1   |   3   |
    // |       + - + - +
    // |       | 4 | 5 |
    // + - - - + - + - +

    Visual v1 = new VisualMock();
    Visual v2 = new VisualMock();
    Visual v3 = new VisualMock();
    Visual v4 = new VisualMock();
    Visual v5 = new VisualMock();

    LayoutDefinition ld = new LayoutDefinition();
    ld.BeginSideBySideSection();
        ld.Add(v1);
        ld.BeginStackedSection();
            ld.Add(v2);
            ld.Add(v3);
            ld.BeginSideBySideSection();
                ld.Add(v4);
                ld.Add(v5);
            ld.EndSection();
        ld.EndSection();
    ld.EndSection();
}
Version Information

Supported in: 7.6, 7.5, 7.0, 6.5, 6.0, 5.5, 5.0
See Also

Reference