OpenSCADAWiki: Home Page En/Doc/ Vision ...

Home | Каталог | | | | Регистрация |  :  
 
Ukrainian (1 ) ?
Russian (1 )

Module "Vision" of the subsystem "User Interfaces"

Module: Vision
Name: Operation user interface (Qt)
Type: User interfaces
Source: ui_Vision.so
Version: 4.6
Author: Roman Savochenko, Maxim Lysenko (2007-2012), Ksenia Yashina (2007-2008)
Description: Visual operation user interface, based on Qt library - front-end to VCA engine.
License: GPL

Introduction

Vision module provides a mechanism of the final visualization control area (VCA) into the OpenSCADA. The module is based on the multi-platform library of graphical user interface (GUI) of firm TrollTech Qt (http://www.trolltech.com/qt ). In its work, the module uses the data of the VCA engine (module VCAEngine).


Visual control area (VCA) is an integral part of the SCADA system. It applies to the client stations with a view to providing accessible information about the object and to for the the issuance of the control actions to the object. In various practical situations and conditions the VCA, based on different principles of visualization may by applied. For example, this may be the library of widgets Qt, GTK+, ~ wxWidgets or hypertext mechanisms based technologies HTML, XHTML, XML, CSS, and JavaScript, or third-party applications of visualization, realized in various programming languages Java, Python, etc. Any of these principles has its advantages and disadvantages, the combination of which could become an insurmountable obstacle to the use of VCA in a practical case. For example, technologies like the Qt library can create highly-reactive VCA, which will undoubtedly important for the operator station for control of technological processes (TP). However, the need for installation of that client software in some cases may make using of it impossible. On the other hand, Web-technology does not require installation on client systems and is extremely multi-platform (it is enough to create a link to the Web-server at any Web-browser) that is most important for various engineering and administrative stations, but the responsiveness and reliability of such interfaces is lower that actually eliminates the using of them at the operator of the TP stations.


OpenSCADA system has extremely flexible architecture that allows you to create external interfaces, including user and in any manner and for any taste. For example, the system configuration OpenSCADA as now available as by means of the Qt library, and also the Web-based.


At the same time creation of an independent implementation of the VCA in different basis may cause the inability to use the configuration of one VCA into another one. That is inconvenient and limited from the user side, as well as costly in terms of implementation and follow-up support. In order to avoid these problems, as well as to create as soon as possible the full spectrum of different types of VCA is established. The result of this project the direct visualization module (based on the library Qt), direct visualization module WebVision and VCA engine VCAEngine.

1. Purpose

This module of the direct visualization of the VCA is designed for the formation and execution of VCA interfaces among the graphic library Qt. The VCA module provide:

2. Tool of the graphical formation of the VCA interface

Development of the VCA interface is performed in a single window, realizing many documents interface (MDI) interface (Fig. 2.a). This approach allows you to simultaneously open multiple frames of various sizes. The following mechanisms for managing the development are used: toolbars, menus and context menus. Most actions are duplicated by different mechanisms, that allows you to quickly find the tool by the preferred method. Navigational interfaces are implemented by the attached windows. Configuration if the toolbars and attached windows is saved on exit and restored at startup that lets you to customize the interface for yourself.


Developing window of the VCA interfaces (140 )
Fig.2.a. The window of the VCA interface development.

Access to major components of the VCA is made by attached windows, in the Figure 2.a these windows are shown on the left side. These windows contain:


In the main space of the working window the pages of projects, frames of the widgets' libraries, user elements and elements of primitives at the time of their visual editing are placed.


At the top of the working window there is the menu. All the tools needed for development the VCA interfaces are placed in the menu. Menu has the following structure:


Above, under menu, or on the sides, there are the toolbars. Toolbars can be hidden or located, which is controlled in the menu item "View". The following toolbars are present:


At the bottom of the development window of the VCA there is the status line. On the right side of the status line there are indicators of the visual scale of the edited frame, of the mode of changing of the size of the elements, of the mode of the current page of the of the VCA engine station and the user on whose behalf the development of the VCA interface is done. By double-clicking on the indicator of the user it can be changed the current user, enter the new username and password. In the main field of the status line it is displayed various information and assistance messages.


To edit the properties of the visual elements there are two dialogues. The first dialogue allows you to edit the properties of containers of visual elements (widget libraries and projects), figure 2.b. The second dialogue serves to edit the properties of the visual elements, Fig. 2.d. Changes, made in the dialogues, at once, get to the VCA engine. To save these changes to the database or restore from the database it is necessary to use the appropriate tools of the main development window.


Dialogue of the editing the properties of the containers of visual elements. (42 )
Fig.2.b. Dialogue of the editing the properties of the containers of visual elements.

With the help of the main tab of that dialog you can set:


The tab "Diagnostics" of the projects. (57 )
Fig.2.c. The tab "Diagnostics" of the projects.

From this tab you can select time, or refresh to current, and size for diagnostic messages obtain.


Dialogue of the properties editing of the visual elements (31 )
Fig.2.d. Dialogue of editing the properties of visual elements.

With the help of the main tab of that dialog you can set:


Dialogue of editing the properties of the containers of visual elements contains two tabs: configuration tab of the the main parameters (Fig.2.b) and the configuration tab of the mime-data of the container (Fig. 2.e).


Editing tab of the data of the container of the visual elements (38 )
Fig.2.e. Editing tab of the mime-data of the container of visual elements.

Dialogue of the editing the properties of the visual elements contains four tabs: configuration tab of the main parameters (Fig.2.b), the tab of attributes of the element (Fig. 2.f), the tab of the processing of the element (Fig. 2.g) and the tab of links of the elements (Fig.2.h). At different levels of the hierarchy of visual elements any tabs can be available, but some are not.


Attributes of the editing dialogue of the properties of the visual element tab. (44 )
Fig.2.f. Attributes of the editing dialogue of the properties of the visual element tab.

Processing tab of the dialogue of the editing the properties of the visual element. (62 )
Fig.2.g. Processing tab of the dialogue of the editing the properties of the visual element.

Links tab of the dialogue of changing properties of the visual element (58 )
Fig.2.g. Tab of links of the editing dialog of the properties of visual element.

2.1. Styles


It is known that people can have individual characteristics in the perception of graphical information. If these features are not taken into account it is possible to get the rejection and exclusion of the user to the VC interface. Such rejection and exclusion can lead to fatal errors in the management of TP, as well as traumatize the human by the permanent working with the such interface. In SCADA systems it is accepted the agreement, which regulate the requirements for establishing a unified VC interface which is normally perceived by most of people. The people with some deviations are not taken into account.


To take this into account, and provide the ability to centrally and easily change the visual properties of the interface, the project provides the implementation of visualization interface styles manager.


User can create many styles, each of which will hold the color, font and other properties of the elements of the frame. A simple change of style will quickly transform the VC interface, and the possibility of appointing an individual style to the user will take into account his individual characteristics.


To realize this opportunity, when you create a frame, it is necessary for the properties of color, font and others set the Config ( of the table if the process tab) in the value of From style. And in the parameter Config template to specify the identifier of the style field. Further, this field will automatically appear in the Style Manager and will be there to change. Style Manager is available on the project configuration page in the tab Styles (Figure next). On this tab you can create new styles, delete old ones, change the field of the style and delete unnecessary.


Tab "Styles" of the configuration page of the project (19 )

In general the styles are available from the project level. At the level of libraries of widgets you can only define styles fields of widgets. At the project level, at the choice of style it is started the work with styles, which includes access to the fields of styles instead of direct attribute values. In fact, this means that when reading or writing a widget attribute these operations will be carried out with the corresponding field of the chosen style.


When you run the project execution it will be used the set in the project style. Subsequently, the user can select a style from the list of available ones. The user's style will be saved and used next time you run the project.

2.2. Linkage with the dynamics

To provide relevant data in the visualization interface the data of subsystems "Data acquisition (DAQ)" must be used. The nature of these data as follows:

  1. parameters that contain some number of attributes;
  2. attributes of the parameter can provide information of four types: Boolean, Integer, Real and String;
  3. attributes of the parameter can have their history (archive);
  4. attributes of the parameter can be set to read, write, and with full access.

Considering the first paragraph it is necessary to allow the possibility of the group of destination links. To do this we use the conception of of the logic level.


In accordance with paragraph 2, links provide transparent conversion of connection types and do not require special configuration.


To satisfy the opportunities for access to archives, in accordance with paragraph 3, links make check of the type of the attribute, and in the case of connection to the "Address", the address of linkage is put into the value.


In terms of the VCA, the dynamic links and configuration of the dynamics are the one process, to describe a configuration of which the tab "Processing" of the widgets is provided (Fig.2.f). The tab contains a table of configuration of the properties of the attributes of the widget and the text of calculation procedure of the widget.


In addition to configuration fields of the attributes the column "Processing" in the table is provided, for selective using of the attributes of the widgets in the computational procedure of the widget, and the columns "Configuration" and "Configuration template", to describe the configuration of links.


The column "Configuration" allows you to specify the linkage type for the attribute of the widget:


The column "Configuration template" makes it possible to describe the groups of dynamic attributes. For example, it may be different types of parameters of subsystem "DAQ" and other widgets of the interface. Furthermore, in the case of correct formation of this field, the mechanism of automatically assign of the attributes with the only indication of the parameter of subsystem "DAQ" or the widget is working, which simplifies and accelerates the configuration process. The value of this column has the following format:


Installation of the links may be of several types, which are determined by the prefix:


Processing of the links occurs at a frequency of calculating the widget in the following order:


Fig. 2.g presents the tab with the possibility of group and individual assignment of attributes.


When the widget that contains the configuration of links is placed to the container of widgets, all links of the source widget is added to the list of resulting links of the widgets' container.


The above shows that the links are set by the user in the configuration interface. However, for the possibility of creation of the frames for general use, with the function of providing detailed data of various sources of the same type, a dynamic linkage mechanism is necessary. Such mechanism is provided through a reserved key identifier "<page>" of the group of attributes of links in the frames of general purpose and dynamic linkage with the identifier "<page>" in the process of opening of the frame of general purpose by means of the signal from another widget.


Lets examine the example when we have the frame of general-purpose "Control panel of graph" and a lot of "Graphs" in different tabs. "Control panel of graph" has links with the templates:


At the same time, each widget "Graph" has the attributes tSek, tSize, trcPer and valArch. In the case of a calling of the opening signal of "Control panel of graph" from any widget "Graph" it is happening the linkage of the attributes of the "Control panel of graph" in accordance with the attribute specified in the template with the attribute of the widget "Graph". As a result, all changes in the "Control panel of graph" will be displayed on the graph by means of the link.


In the case of presence of external links to the parameters of subsystem "Data acquisition" in the widget "Graph", the links of "Control panel of graph" will be set on an external source. In addition, if in the "Control panel of graph" will be declared the links to the missing attributes directly in the widget "Graph", it will be made the search for the availability of such attributes from the external source, the first to which the link is directed, performing, thus, the addition of missing links.


To visualize this mechanism the table is cited.


Table. The mechanism of the dynamic linkage.

Attributes of the "Control panel of graph" (the template of dynamic linkage) "Graph" attributes Attributes of an external "Parameter" The resulting link or an value of the linking attribute
tSek (<page>|tSek) tSek - "Graph".tSek
tSize (<page>|tSize) tSize - "Graph".tSize
trcPer (<page>|trcPer) trcPer - "Graph".trcPer
valArch (<page>|valArch) valArch - "Graph".valArch
var (<page>|var) var var "Parameter".var
ed (<page>|ed) - ed "Parameter".ed
max (<page>|max) - - EVAL
min (<page>|min) - - EVAL

3. Execution of the VCA interfaces

Execution of the VCA interface is to run a new project session or connect to the existing one on the level of VCA engine. Then the module of direct visualization represents and manages the data of the session. The main window mode of execution mode of this module has the form presented at Fig.3.


Update of the contents of the open pages of the visualization interface with the frequency of the project session execution. In the updating process it is performed:


At the closure of "Run-time" window closing of the session of the project is done in the VCA engine.


The mechanism of the request of the only modified data is based on an absolute counter of the session execution. If you want to make real changes in the attributes of widgets the memorizing of the value of this counter is done, which allows the identification of modified attributes. This approach can increase productivity and reduce the load on network sharing in the case of access to the VCA engine via network.


Hierarchically the module provides an opportunity to accommodate the project pages in the main execution window (Fig.3), as well as putting them inside of the container widgets, as well as by the opening of additional windows over the main.


When you expand the main execution window, or when moving to the full-screen mode the scaling of the page content of the VCA interface is done, filling the entire space of the window and allowing to execute the projects, developed on one screen resolution, at different resolutions.


The main window consists of menu (top) status line (bottom), and the executable contents of the session between them. Menu in the execution mode is positioned as the OpenSCADA administrator tool, containing the self-system functions and it is available only to privileged users, occupying the group "root". Menu has the following structure:


On the right side of the status line the indicators of the time, the current VCA engine station and users on whose behalf the VCA interface is executed, as well as the panel with the alarm quittance buttons, print and export. By double-clicking on the indicator of the user it can be changed by the typing of the new username and password, and by clicking on the quittance button to quit alarms completely or only the desired notification. In the main field of the status line various messages and assistance messages are displayed.


The Run-time mode mostly supports multi-language depended from user language from which the window executed or selected, that is if you change the user you will get the Run-time interface at other language of the user. This function enabled for dynamic messages translation of OpenSCADA.


The main window if the execution mode. (107 )
Fig.3. The main window if the execution mode.

4. Conception of basic elements (primitives)

In this version of that module not all the primitives' images of this project are implemented. In general the project provides the following primitives:

Id Name Function
ElFigure Elementary graphic figures

Primitive is the basis for drawing basic graphic shapes with their possible combinations in a single object. The support of the following basic figures is provided:

  • Line.
  • Arc.
  • Bézier curve.
  • Fill of the enclosed space.

For all the figures contained in the widget it is set the common properties of thickness, color, etc., but this does not exclude the possibility of indicating the above attributes for each figure separately.

FormEl Elements of the form

Includes support for standard form components:

  • Line edit.
  • Text edit.
  • Check box.
  • Button.
  • Combo box.
  • List.
  • Tree.
  • Table.
  • Slider.
  • Scroll bar.
Text Text Text element (labels). Characterized by the type of font, color, orientation and alignment.
Media Media Element of visualization of raster and vector images of various formats, playback of animated images, audio segments and video fragments.
Diagram Diagram Element of the diagram with the support of the visualization of the flow of several trends, the spectrum, XY diagrams of real-time data, ... .
Protocol Protocol Element of the protocol, visualizer of the system messages, with support for multiple operating modes.
Document Document The element of generating the reports, journals and other documentation on the basis of available in the system data.
Box Container Contains the mechanism for other widgets placement-including with the purpose of creation of new, more complex, widgets and pages of end visualization.
Function, in plane Function of API of the object model of OpenSCADA Not visual, on the side of execution, widget which allows to include a computing function of the object model of OpenSCADA in the VCA.

 (2 ) For all listed and implemented primitives except "FormEl" the module supports events conditional generating from transparency of the pointed pixel, more then zero (not full transparency).


The module of visualizer provides and uses set of specific attributes of the generic means, its information are into next table. Theses attributes create by the visualizer, on its lack, at a first start.

Id (space) Name Appointment
statLine (main page) Status line items

Text field with description of the status line item in form "{Id}:{Label}:{ToolTip}:{Color}:{Img}", where:

  • "Id" identifier, uses also for form events from the widget "stIt_{Id}".
  • "Label" visual label of the status element.
  • "ToolTip" context help about the element.
  • "Color" label color.
  • "Img" image of the status element, instead the label.
runWin (main page) Run window

Main window execution mode setting:

  • "Original size (0)".
  • "Maximize (1)".
  • "Full screen (2)".
keepAspectRatio (main page) Keep aspect ratio on scale Pages aspect ration save at the scaling.
stBarNoShow (main page) No show status bar Main window status line hide.
winPosCntrSave (main page) Windows position control and save Enabling of the windows position control and save.
userSetVis (main page, created manually of the type String) Set user

Change user or call dialog for it selection. Value variants:

  • "*" call for the user selection dialog;
  • "$" change user to default one;
  • "{user}" direct change to user if it is allowed.

Lets examine the implementation of each primitive.

4.1. Elementary figure primitive (ElFigure)


Support of the following elementary figures is provided: lines, elliptical arcs, Bézier curves and fill of the closed circuit with the color and/or image. For the elementary figures the following operations are provided:

Figure shows a part of the screen with a frame containing the elementary figures.


Realization of the basic elementary figures in Vision (10 )

The figures underlying this widget, containing the points (the start and end ones) that can be connected with the according points of other figures; and the points with the help of which the geometry of the figure can be changed.


It is possible to add the figure using the mouse:

  1. Select the desired figure from the context menu.
  2. Set with the left mouse-button start and end points (for line with the SHIFT key hold its orthogonal drawing is made).

The deleting of the figure(s) it is possible by pressing "Del", having selected figure(s).


The copying of the figure(s) it is possible by pressing keys "Ctrl"+"C", having selected figure(s).


Moving/resizing of the figure it is possible by using the mouse or keyboard:

  1. Select the figure, by clicking on it with the left mouse button.
  2. Drag (with the help of mouse or control keys) the figure or one of its control points in the desired location and release the mouse button (key).

It is possible to move several figures, selected by means of holding "Ctrl" and clicking on the desired figures (this option works when the button Connections (Connections) is disabled) or by mouse selection.


The connection of the figures with each other it is possible by the following way:

  1. Press the Connections button.
  2. Select one of the figures and move its start or end point to the desired start or end point of the other figure so that it will get to the appeared circle, release the left mouse button. Connected figures are moving as well as the individual, the general point is moved for all connected figures, to which it refers(priority is given to the arc, two arcs can't be connected directly with each other ).

To fill the closed circuit from the figures it is possible with the following way:

  1. Press the Connections button.
  2. Create the closed circuit.
  3. Make the double-click of the left mouse button inside of it.

To delete the fill of the closed circuit it is possible from the context menu of the widget; by braking the closed circuit or by double-click of the left mouse button on the already existing filled space.


Rotation of the figure is made around the center of the widget.

4.2. Text primitive (Text)


Support of the text element with the following properties is provided:


Figure 4.2 represents a part of the screen with the frame containing the text examples using various parameters.


Realization of the text elements in the Vision (10 )

4.3. Primitive of the form element (FormEl)


Support of the form elements on the VCA frames is provided. The following form elements are included:


The following modes are realized: Enable and Active, as well as transfer of changes and events to the data model of the VCA (engine).


Figure represents a part of the screen with the frame containing the above-listed elements of the form.


Realization of the form elements in the Vision (18 )

4.4. Primitive of the displaying the media materials (Media)


Support of the element of the displaying of media materials with the following properties is provided:


Figure represents a part of the screen with the frame containing examples of viewing/playback of media data.


Realization of the media elements in the Vision (17 )

4.5. Primitive of the construction of diagrams/graphs (Diagram)


The diagrams construction element releases for types "Graph", "Spectrum" and "XY" with properties:


The module of visualizer provides and uses set of specific attributes of the generic means, its information are into next table. Theses attributes create by the visualizer, on its lack, at a first start.

Id Name Appointment
sclWin Scaling of a window selected part, by the mouse. It is logical type attribute created by the user manually at needs. The "true" value enables the scaling of a window selected part, by the mouse.

Figure represents a part of the screen with the frame containing examples of the diagrams: "Graph", "Spectrum" and "XY".


Realization of the basic element of a diagram-trend displaying in the Vision. (10 )

4.6. Primitive of the protocol formation (Protocol)


Support of the element of the formation of the protocol with the following properties is provided:


Figure represents a part of the screen with the frame containing an example of the protocol.


Realization of the basic element of visualization of the protocol in Vision (34 )

4.7. Primitive of the report formation (Document)


Support element of the report formation with the following properties is provided:


The basis of any document is XHTML-template. XHTML-template is the tag "body" of the WEB-page which contains the document's static in the standard XHTML 1.0 and elements of the executable instructions in one of the languages of the user programming of OpenSCADA in the form of <?dp {procedure} ?>. The resulting document is formed by the execution of procedures and insert of their result into the document.


The source for values of the executable instructions are the attributes of the widget of the primitive, as well as all the mechanisms of the user programming language. Attributes may be added by the user and they can be linked to the actual attributes or parameters or they can be autonomous, values of which will be formed in the script of the widget. In the case of linked attributes the values can be extracted from the history, archive.


Figure shows the frame containing a sample of the document.


Realization of the document element in the Vision (59 )

4.8. Primitive of the box container (Box)


Support of the primitive of the container concurrently serves as the project pages is provided. This primitive is the only element-container, which may include links to frames from the library, thereby creating the user elements of desired configuration. Primitive implements the provided by the project properties. The properties of this primitive are:


Example of editing of the frame, based on the primitive, is shown in Fig. 2.a, and Fig. 3 shows a page containing the container of the pages, built on the basis of the primitive.


5. Vector graphics editor.

5.1. Purpose

The presence of own vector graphics editor is an integral part of self-respecting SCADA system. Experience shows that the most informative form of technological process presentation is a mnemonic schemes a set of alarm devices, images of the equipment, and internal connections of the controlled object, running on a PC (operator's station). To create them, you can use any of the existing graphical editors. However, thus obtained the mnemonic schemes are static and do not reflect the dynamics of changes in the characteristics of the process and, consequently, they are inadequate and uncomfortable for perception. Thus, one of the tasks facing the developers of SCADA systems is the creation of a graphical editor for creation (painting) the objects, whose characteristics can be dynamically changed.

5.2. Principles and functions of the graphic editor

The basis of the described editor are three graphic primitives: line, arc, Bézier curve. The dynamically changing the characteristics of these primitives are:


   ElFigure (2 )
Fig. 5.2.a. Control points of the line, arcs and Bézier curve.

Examples of primitives of different colors, widths, styles with borders or without ones are shown in Fig. 5.2.b.


   (4 )
Fig. 5.2.b. Examples of primitives: line, arc and Bézier curve from left to right.

It is possible to connect the various graphic primitives for creation of complex graphic objects. If the connected primitives make the closed circuit, it can be filled with color and/or image (Fig. 5.2.c).


    /  (6 )
Fig. 5.2.c. Fills of the closed circuit with the colors and/or images.

Graphics editor allows you to zoom and rotate the figures (primitives and complex graphic objects) (Fig. 5.2.d).


The features of the editor also include the selection, moving, copying and deleting the figures.


   . (6 )
Fig. 5.2.d. Zoom and rotate the figures.

5.3. Basic principles of operation in the graphic editor

To get to work with a graphical editor after the OpenSCADA is started it is necessary to call "Operation user interface". The "Widgets" tab contains a list of existing graphic libraries and their elements.


Lets suppose that we need to add a graphic element to the one of the existing libraries. To do this, select the name of the library, and click the (     (2 )) on the toolbar. In the appeared window enter the ID and name of the new graphic element. After that lets select the created item and click (    (2 )) button. The drawing area will appear on the right. By double-clicking on that field or either using the context menu lets enter the editing mode the mode of the graphical editor that allows you to perform all provided manipulations with the figures. At a time when we have the created graphic element in focus, the "Attributes" tab takes the form, shown in Fig. 5.3.a.


Attributes of elementary figure. (24 )
Fig. 5.3.a. Attributes of elementary figure.

With the help of mouse or the "Geometry " field of the "Attributes" tab lets define the drawing area size and scale coefficients.


Using the "Line" field of the "Attributes" tab, lets define the width, color, lines' style of the figures which we'll draw. With the "Border" field lets define the width and color of the border. The "Fill" field allows you to specify color, and image for the fills. "Elements' list" contains a list of primitives used to create the graphic object. Elements of all fields of the "Attributes" tab can be dynamically changed in the scripts (programs) of the user.


Graphics primitives can be drawn with the mouse or by specifying the list of graphical primitives ("Elements' list"). In the first case, the coordinates of control points of the primitive are computed automatically, width, color, style of the line, width and color of the border are set by defaults from the "Attributes" tab. In the second case, the primitive must be described in the "Elements' list" as follows:

line:(x1|y1):(x2|y2):width:color:border_width:border_color:style (1)
arc:(x1|y1):(x2|y2):(x3|y3):(x4|y4):(x5|y5):width:color:border_width:border_color:style (2)
bezier:(x1|y1):(x2|y2):(x3|y3):(x4|y4):width:color:border_width:border_color:style, (3)

Where:

(x1|y1) first control point's coordinates of the primitive;
(x2|y2) second control point's coordinates of the primitive;
(x3|y3) third control point's coordinates of the primitive;
(x4|y4) fourth control point's coordinates of the primitive;
(x5|y5) fifth control point's coordinates of the primitive;
width line width, with which the primitive will be drawn;
color line color, with which the primitive will be drawn;
border_width border width;
border_color border color;
style line style ("0" solid, "1" dashed, "2" dotted).

The priority values are the width, color, style of the line, width and color of the border, specified in the "Elements' list". If you want to use any of the properties that are set in the fields "Line" or "Border" of the "Attributes" tab, then during the description of the primitive they should be skipped. For example, we want to create a line with a width of 3, red color, solid and without border. At the same time in the "Line" field the following properties are set: the line width 3, black color of the line, solid line style, and in the "Border" field the width of the border 5, border's color green. Then the description of the primitive in the "Elements' list " will be as follows:

line:(x1|y1):(x2|y2)::red:0:: (4)

Expressions (1) - (4) define the static properties of the primitives that can not be changed by user's program. To specify the dynamic properties it is necessary to use the following expression:

line:1:2:w1:c1:w2:c2:s1 (5)

Then the "Attributes" tab will be appended by the fields: Point 1 (1), Point 2 (2), Width 1(w1), Width 2(w2), Color 1(c1), Color 2(c2), Style 1 (s1) (Fig. 5.3.b), values of these fields can be changed programmatically, by using a programming language of the OpenSCADA project. It is obvious that if desired not all properties of the primitive can be declared dynamic, but one or several, besides one dynamic property can be used repeatedly.


Editing the coordinates of control points is made either with the mouse or through changes in the "Elements' list " for static points, or directly in the "Attributes" tab, having the dynamic ones ("Point 1"...). Editing the other properties is made by means of changing the contents of the fields "Line", "Border", "Fill" of the "Attributes" tab or the "Elements' list".


Dynamic attributes of elementary figure. (26 )
Fig. 5.3.b. Dynamic attributes of elementary figure.

There is the possibility of selection (left click on the figure) the primitive, the joint selection of primitives (left mouse button + "Ctrl" key pressed having disabled the "Connections" button), a joint selection by the frame, drawn by holding down the left mouse button; moving them (keyboard/mouse); copy and paste (Ctrl + C, Ctrl + V or from the popup menu); delete (Del).


To connect the primitives with each other it is necessary:


To fill the closed circuit it is necessary to make double click of the left mouse button inside it or you can specify a fill in the "Elements' list" as follows:

fill:(x1:y1):(x2:y2):...:(xn:yn):color:image (statics);
fill:1:2:3:...:c1:i1 (dynamics).

Where:

(x1:y1):(x2:y2):...:(xn:yn) coordinates of the start/end points of the primitives that form a closed circuit;
color fill color;
image fill image.

The priority values are the color and image of the fill, set in the "Elements' list. " If you want to use the properties set in the "Fill" field of the "Attributes" tab, then they should be skipped in the description of the primitive.


To scale the figures it is necessary in the "Geometry" field to set the scale the for the "X" and "Y" axes. In addition, there is the ability to visually zoom in/out the widget without changing the scale in the "Geometry" field. You must exit the editing mode by the right click on the widget field, select in the popup menu "Zoom in (+10%)"/"Zoom out (-10%)", or rotate the mouse wheel while holding the "Ctrl" key pressed. Exit the editing mode is made either by pressing the "Esc", or using the popup menu of the widget.


It is possible to rotate the contents of the widget. To rotate the created objects you should set the "Orientation angle" from -360 to 360 in the "Attributes" tab.


Graphical editor supports color transparency, defined as follows: color-t, where the color the color itself, and t transparency from 0 (fully transparent) to 255 (opaque).

5.4. Popup menu of the graphic editor

The popup menu by the right-clicking in the editable widget is provided. Depending on what an object is under the mouse popup menu can take several different forms. Below, in Figure 5.4, there are examples of the popup menu.


The popup menu for the lines (line, arc, B`zier curve). (23 ) The popup menu for the fill (24 )
Fig. 5.4. The popup menu for the lines (line, arc, Bézier curve) and for the fill from left to right.

The popup menu includes the following sections (from top to bottom):

5.5. Properties dialog of the elementary figure

Dialog, versions of which are shown in Figures 5.5.a, 5.5.b, 5.5.c, is implemented for interactive and comfortable user control of the properties of the figure(s).


Elementary figure's properties dialog for single figure (line, arc or a B&#233;zier curve). (40 )
Fig. 5.5.a. Elementary figure's properties dialog for single figure (line, arc or a Bézier curve).

Elementary figure's properties dialog for the group of selected figures. (33 ) Elementary figure's properties dialog for the group of selected figures with disabled properties. (30 )
Fig. 5.5.b. Elementary figure's properties dialog for the group of selected figures.

Elementary figure's properties dialog for the fill. (19 )
Fig. 5.5.c. Elementary figure's properties dialog for the fill.

As can be seen from the figures above, the dialog can be of three different forms, depending on the object for which it is called. In the title of the dialog there are the numbers of figures, for which it is called. These numbers correspond to the positions of figures in the "Elements' list", starting from the top.


If the dialog called for a single figure (line, arc or a Bézier curve), then it is possible to edit the points' coordinates of the figure (Fig. 5.5.a). If the point is connected to the point of another figure or figures, and "bindings" ("Connections") are enabled, then entered coordinates will be applied to all connected figures and fills, which involved the figure, will be redrawn accordingly.


If the dialog is called for the group of selected figures (Fig. 5.5.b), properties (attributes) listed in the dialog will be applied to all figures listed in the title of the dialog. When you call the dialog in the fields of the properties will be shown the data of the figure from the group of selected ones, for which it was called the popup menu. There is the possibility to include/exclude certain properties of the dialog. For this the ( /  (2 )) button is provided. In the case of exclusion of individual properties, they will not be processed upon acceptation of the dialog ("Ok" button). After the acceptation of the dialog, all of the data of the included properties will be applied to the whole group of figures.


Dialog for the fill's properties (Fig. 5.5.c) allows you to manage the properties of the specific fill.


When selecting a check box to the right of a property, it (the property) after the acceptation of the dialog is set to the default value, which is listed in the "Attributes" tab. The "Dyn/Stat" buttons make the appropriate properties dynamic or static.

6. The overall configuration of the module

To adjust your own behavior in not obvious situations the module provides the ability to customize individual settings through the management interface of the OpenSCADA (Fig. 6). These settings are:

 (2 ) The display selection function possible for non virtual and non repeating desktop, i.e. with using Xinerma or NVidia into proper modes. Technical the function Qt screen() must return different display's widgets to it's number.

The configuration page of the module. (101 )
Fig.6. The configuration page of the module.

 
(20).[ /]
. [ /]