Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Reverted from v. 10

The FlowPanel allows Allows the easy configuration of multiple symbols and components in a repetitive and responsive mannerway. It provides an offers a user-friendly interface that adjusts item layouts automatically adjusts the layout of items based on panel characteristics and the data sourcedatasource. This topic describes explains how to configure the FlowPanel, select its layout options (panel type), choose data source types, and understand how the control dynamically adapts to the runtime environment.

On this page:

Table of Contents
maxLevel3
styleNone


Image RemovedImage Added


Requirements

This component is Portable. It runs both on Windows and on Web Pages hosted in any platform.

Configuration

To configure a FlowPanel:

  1. Go to Displays / Draw.

  2. On the Components Panel, select Viewer, then FlowPanel.

  3. Click or drag-and-drop it on the Drawing area to use it.

  4. Double-click the component to open the configuration window.

Panel Types

The FlowPanel supports several panel types that control the layout of symbols or components. Each panel type has specific behavior, described below:

1. WrapPanel

      • Layout: Aligns items horizontally, breaking

FlowPanel Settings

Field

Description

Panel Type

Configures how items are arranged in the container. Options include WrapPanel for wrapping content, Canvas for manual positioning, DockPane for docked elements, Grid for a grid layout, StackPanelHorizontal and StackPanelVertical for stacking, and UniformGrid for uniform distribution.

WrapPanel: Aligns items horizontally and wraps them
      • to the next line when the width limit is
exceeded
      • reached.
Best suited for horizontal
      • Ideal for: Horizontal listings or galleries where the number of items can vary.
It dynamically adjusts line breaks when the window is resized.
      • Responsiveness: Line breaks adjust the items as the window resizes.

2. Canvas

      • Layout: Allows positioning of items at absolute
Canvas: Positions items at fixed
      • coordinates (x, y)
within the panel
      • .
Suitable for cases that require
      • Ideal for: Scenarios where precise control of
item placement, such as maps. The panel does not adapt easily to resizing due to fixed positions.DockPanel: Anchors items to the panel's edges or fills
      • the position is needed, like maps or complex layouts.
      • Responsiveness: Less responsive since positions are fixed and may not adapt well to resizing.

3. DockPanel

      • Layout: Items are anchored to the edges (top, bottom, left, right) or fill the remaining space in the center.
      • Ideal for
layouts that distribute content
      • : Layouts focused on distributing items around a central element
. It adapts well to resizing by adjusting items
      • or along the screen edges.
      • Responsiveness: Items resize according to the available space.

4. Grid

      • Layout: Organizes items
into
      • in rows and columns, with flexible sizing for each cell
sizing
      • .
Useful for structured layouts that require tabular
      • Ideal for: Tabular or grid-based
alignment. The grid layout adjusts proportionally as the panel resizes.
      • layouts where items need to be aligned in a structured manner.
      • Responsiveness: The layout adjusts well to resizing, maintaining the proportion between rows and columns.

5. StackPanelHorizontal

      • Layout
StackPanelHorizontal
      • : Aligns items horizontally
in a single line without wrapping. This is ideal for simple horizontal lists
      • , without line breaks.
      • Ideal for: Simple horizontal listings, like menus or toolbars.
However, the layout may require scrolling if the content exceeds the panel width.
      • Responsiveness: Horizontal alignment does not automatically adjust to screen width, which may result in scrolling.

6. StackPanelVertical

      • Layout: Aligns items vertically, one below the other.
      • Ideal for: Simple vertical listings, like
StackPanelVertical: Stacks items vertically in a column. Suitable for simple vertical lists, such as
      • task lists or side menus.
The panel
      • Responsiveness: Items remain vertically stacked, and the height of the FlowPanel may adjust
its height
      • to fit all items
within the vertical alignment
      • .

7. UniformGrid

      • Layout: Distributes items evenly in a grid where all cells have the same size.
It is ideal for layouts where uniformity is needed, such as
      • Ideal for: Displays of items with fixed size and balanced layout, like image galleries.
      • Responsiveness: The size of the cells and the number of items per row/column automatically adjust as the screen is resized.

Data Sources

The FlowPanel supports four types of data sources: Text, StringTag, Array, and Object. The choice of data source determines how items are generated and displayed in the panel.

1. Text

      • Format: #Element=<control or symbol name> #<property name1>=<property value1> #<property name2>=<property value2> etc
        • where, Element and Property Name are case sensitive.
      • Use: Manual configuration of symbols or components/controls through static text. Allows linking properties to dynamic values from SCADA tags.
      • Example:

        #element=LampSymbol #Color=red #Size=medium
        #element=PumpControl#State=on#FlowRate=Tag.Tag1

2. StringTag

      • Format: Same as Text, but linked to dynamic system tags.
      • Use: Allows linking symbols or components/controls properties to dynamic values from SCADA tags.
      • Example:

        StringTag = "#element=LampSymbol #Color=red #Size=medium #element=PumpControl#State=on#FlowRate=Tag.Tag1"


3. Array

      • Format: String array, where each entry follows the same format as Text or StringTag.
      • Use: Configures multiple items at once, offering flexibility for scenarios where several items need to be dynamically generated.
      • Example:

        StringTag1[0] = #Element=ValveSymbol #Status="Open" 
        StringTag1[1] = #Element=ConveyorBelt #Speed=100 #State=Tag.State

        ["#element=ValveSymbol #status=open", "#element=ConveyorBelt #speed=fast"]

4. Object

        • Format:
          • DataTable, where each row represents an item (element), and each column defines the properties of the item.
          • Data Template, where each member represents a properties of the item.  The tag of this template type can be an array.
        • Use: Advanced configuration where data comes from tables, such as query results from a database.
        • Example DataTable:

          elementcolorstate
          LampSymbolredon
          MotorSymbolgreenoff


        • Example Template: Tag array of 2 position with datatype of a template 

          memberindex 0index 1
          LampSymbolredon
          MotorSymbolgreenoff



Configuration

To configure a FlowPanel:

  1. Go to Displays / Draw.

  2. On the Components Panel, select Viewer, then FlowPanel.

  3. Click or drag-and-drop it on the Drawing area to use it.

  4. Double-click the component to open the configuration window.

FlowPanel Settings

Field

Description

Panel Type


Sets the Panel mode for the component. Options are:

WrapPanel:  Positions child elements in sequential position from left to right, breaking content to the next line at the edge of the containing box.

Canvas:arrange the items using the standard Canvas container.

DockPanel: arrange the items using the standard Dock container.

Grid: Defines a flexible grid area consisting of columns and rows.

StackPanelHorizontal: Arranges child elements into a single line oriented horizontally.

StackPanelVertical: Arranges child elements into a single line oriented vertically.

UniformGrid: Used to arrange children in a grid with all equal cell sizes.


Panel Settings


Allows configure panel setting properties following the same format of data source. Example: #Background=Green, where Background is a property of the panel. 


Items Source

Determines the source of the items displayed in the FlowPanel. Can be bound to a list or collection, and users can specify the type of data, such as text or objects. Options are:

Text: Allows the FlowPanel to display a list of simple text items. Useful for representing straightforward string values such as machine states or operational modes.

StringTag: Enables the FlowPanel to display a list of items generated from a pre-existing Tag of the Text type. This feature is particularly useful when multiple FlowPanels across different displays need to present the same information consistently.

Array: Allows the FlowPanel to display items from an array. Suitable for predefined sets of options, such as lists of sensor IDs or operational steps, enabling efficient management of uniform data.

Object: Allows the FlowPanel to display items from a collection of objects. Ideal for complex data representation where each item has multiple attributes, such as equipment lists with properties like name, ID, and status.

The object can be Databases Queries, or any realtime Tag, AssetPath, or property from the system namespaces

Max Items

Specifies the maximum number of items that the FlowPanel can display or hold. Limits the number of items to prevent overload and improve performance.

Reload

Specifies a command or function that reloads the items in the FlowPanel. Ensures that the FlowPanel displays the most current data, useful for dynamic or real-time data sources.

Quantity

Defines how many items will be sourced in the design preview. (not applied to runtime)

Width

Defines the width of each panel, ensuring that each panel is properly sized according to the user's preferences and fits seamlessly within the FlowPanel.

Height

Defines the height of each panel, ensuring that each panel is properly sized according to the user's preferences and fits seamlessly within the FlowPanel.

Margin

Specifies the margin for each panel, ensuring sufficient spacing to avoid a cramped layout

The layout dynamically adjusts based on screen size changes.

Panel Settings

Sets specific configurations for the panel, allowing adjustments to layout parameters like width, height, and margin. An Apply button finalizes the changes, ensuring the panel reflects the new settings.

Width

Specifies the width of items within the container. Users input a value, and the system automatically applies the specified width across all items.

Height

Defines the height of items inside the panel. The height value applies uniformly across all components, ensuring consistency in vertical size.

Margin

Adjusts the spacing around items within the container. The margin creates space between items and the container’s borders or other items, based on the value entered.

Source

Determines the data source for the items displayed within the panel. Options include Text for static text input, StringTag for tagged text elements, Array for data lists, and Object for structured data types.

Text: Allows manual configuration of items using static text. Items and their properties are defined with case-sensitive element and property names. Suitable for defining symbols or controls, with properties linked to static or dynamic values.

StringTag: Similar to the Text source but links item properties to dynamic SCADA tags. This allows the configuration of items that respond to real-time data changes. Used for dynamically updating symbols based on tag values.

Array: Uses a string array where each entry defines an item and its properties. This enables dynamic generation of multiple items at once, useful for scenarios with several items. Each item follows the same format as Text or StringTag.

Object: Uses a DataTable or DataTemplate for advanced configurations. Each row in the table represents an item, and each column defines the item's properties. Ideal for configurations that source data from databases or templates.

Max Items

Sets the maximum number of items displayed in the panel. The system enforces this limit, ensuring that no more than the defined number of items appear, regardless of the data source size.

Reload

Reloads the data source, updating the items shown within the container. This action pulls the latest data, ensuring that the displayed items match the current state of the source.

Preview

Displays a real-time preview of how items will appear within the panel. The system generates this preview based on the current data and configuration settings, allowing users to see changes before applying them.

Count

Provides the total number of items available from the data source. The count helps users understand the number of items accessible, though not all may be displayed depending on the Max Items setting.

Click on Image to Add

Allows users to click on an image to add it as an item to the panel. This interaction simplifies item selection by letting users visually select elements from a predefined set of images

.



Runtime Execution

Responsive Behavior

The FlowPanel is a responsive control, meaning it adjusts the arrangement of items based on the screen size and the size and type of panel used. When the window or browser is resized, the FlowPanel automatically reorganizes items to optimize the available space. (if the display is configured as Responsive)

    • In panels like WrapPanel and UniformGrid, items may shift between rows/columns as the screen size changes.
    • In the Canvas panel, as positions are fixed, the layout does not dynamically adapt to resizing.
    • DockPanel and Grid panels offer great flexibility, dynamically distributing items to better utilize the available space.

Dynamic DataSource Updates

The FlowPanel’s data source can be updated dynamically. To do this, simply trigger a reload on the control, and it will refresh with the new data source. This feature is useful in systems where data or conditions change frequently

. InfoSee FlowPanel Dynamic Symbols for an example of this control in action

.

 



In this section:

Page Tree
root@parent
spacesV10