4. Development Stack

The design of the UI toolkit can be found in [RD11]. The UI toolkit is based in Qt, Taurus, and the MVC pattern. It provides an all-purpose API in Python that targets different expertise levels of ELT Software Developers. Only for performance demanding scenarios a C++ API is offered.

../_images/Control_UI_Toolkit_Layers.png

Control UI Toolkit design

Both set of API (Python and C++) have a common set of classes, which are widgets, models, and auxiliary classes, but the Python API is extended through Taurus. It allows to quickly design UI with data access.

Specialized widgets developed for the ELT project needs are included as well. Tooling and debugging capabilities for GUI are also present in the packages. For more details, please refer to [RD11].

The construction and commissioning period of an observatory will include many user interfaces not intended for final users. But these are necessary, as many of the product are being produced for the first time ever. The complete set of UIs in the ELT falls into two broad categories: End User UI versus Engineering UI.

End User UI

Is a complete product; It provides complete and proper feedback; The User is always in control of the system; It does not require complete understanding of the underlying system.

Engineering UI

It allows to manipulate the underlying system with ample capabilities. Can trigger operations only available for maintenance operations. It cannot be used during science observation periods.

In case of doubt, it is most likely an Engineering UI.

4.1. Toolkit and Language

Control GUIs are developed using Python language and Taurus [RD15] and Qt [RD1] libraries.

Taurus and Qt libraries are pre-installed in the DevEnv machines [RD12].

Control GUIs are written using PySide2 [RD14] python bindings, which is the supported library from Qt.

C++ is required for a GUI component if any of the following applies:

  • It has extraordinary performance needs.

  • It is a custom widget. Note that a python binding should then be implemented, too.

Integration with WAF build system is provided by wtools. Please refer to [RD13].

When 3D acceleration capabilities are needed, please keep the use restricted to OpenGL ES 2.0 standard [RD8].

4.2. Communication Middleware and External Libraries

Clients in ELT software communicate with nodes through the CommunicationMiddleware. The UI toolkit provides under Python API a declarative manner to express connection to datapoints.

For automated tests, use the testing framework of the ELT Dev Env and QtTest.

Usage of Qt Quick Controls 2 (since Qt 5.7) or Qt Labs Controls (since Qt 5.6) is currently not encouraged. This may change in a later version of this document. Qt Quick Controls v1 must not be used.

4.3. Tooling

For designing the static parts of your application’s GUI, we recommend use of the graphical GUI builder Qt Designer. It comes integrated in the development editor Qt Creator.

By using the Qt Designer, you produce declarative GUI descriptions. The Qt Designer stores them as XML files with “.ui” file extension. The “.ui” file can either be converted to code, or an application can load it at run-time to dynamically create the GUI from it. Good documentation on this topic is available at: https://doc.qt.io/qt/designer-using-a-ui-file.html

All ELT-specific widgets also provide a Qt Designer Plugin, in order to allow that these widgets can be used from the Qt Designer.