taurus.qt.qtgui.application

This module provides the base taurus.qt.qtgui.application.TaurusApplication class.

Classes

class TaurusApplication(*args, **kwargs)[source]

A QApplication that performs some taurus-specific initializations and (optionally but deprecated) also parses the command line for taurus options.

The optional keyword parameters:
  • app_name: (str) application name

  • app_version: (str) application version

  • org_name: (str) organization name

  • org_domain: (str) organization domain

  • cmd_line_parser (None [or DEPRECATED optparse.OptionParser])

If cmd_line_parser is explicitly set to None, no parsing will be done at all. If a optparse.OptionParser instance is passed as cmd_line_parser (deprecated), it will be used for parsing the command line arguments. If cmd_line_parser is not explicitly passed, the behaviour will depend on the value of tauruscustomsettings.IMPLICIT_OPTPARSE (which by default is False, indicating that no parsing is done).

Simple example:

import sys
from taurus.qt.qtgui.application import TaurusApplication
import taurus.qt.qtgui.display

app = TaurusApplication(cmd_line_parser=None)

w = taurus.qt.qtgui.display.TaurusLabel()
w.model = 'sys/tg_test/1/double_scalar'
w.show()

sys.exit(app.exec_())

(more info)