StoredSignalSelectorWidget Class
(CDP::GraphWidgets::StoredSignalSelectorWidget)The DB Graph Signal Selector widget lists available signals (columns) from the database. More...
Header: | #include <cdp/graphwidgets/storedsignalselectorwidget.h> |
Properties
|
|
Public Functions
StoredSignalSelectorWidget(QWidget *parent = 0) | |
~StoredSignalSelectorWidget() | |
QSize | buttonMinSize() const |
QString | buttonSvgFile() |
QString | cdpLoggerRouting() |
bool | closingEnabled() const |
SignalContent::Type | contentType() const |
const QUrl & | databaseUrl() const |
int | fontSize() const |
const QSize & | itemSize() const |
void | setButtonMinSize(const QSize &size) |
void | setButtonSvgFile(const QString &svg) |
void | setCdpLoggerRouting(const QString &routing) |
void | setClosingEnabled(bool enabled) |
void | setContentType(SignalContent::Type type) |
virtual void | setCssFile(QString cssFile) |
void | setFontSize(int size) |
void | setItemSize(const QSize &size) |
void | setVirtualKeyboard(bool enabled) |
bool | virtualKeyboard() const |
Public Slots
void | hideWidget() |
void | reconnectToDatabase() |
void | setDatabaseUrl(const QUrl &url) |
void | setInCommand(bool cmd) |
void | setSmoothPixmap(bool smooth) |
void | setWidgetFont(const QString &font) |
void | setWidgetStyle(int style) |
void | setWidgetTheme(const QString &theme) |
void | showWidget() |
Signals
void | signalClose() |
void | signalSelectionChanged(const ColumnList &columns) |
Detailed Description
The DB Graph Signal Selector widget lists available signals (columns) from the database.
To use it set the databaseUrl
property to the same value as for DatabaseGraphWidget. The signalSelectionChanged signal should be connected to suitable slot of DatabaseGraphWidget.
See also DatabaseGraphConfigurationWidget.
Property Documentation
buttonMinSize : QSize
Access functions:
QSize | buttonMinSize() const |
void | setButtonMinSize(const QSize &size) |
buttonSvgFile : QString
This property holds the path to the svg file that styles the widget buttons.
The path can be either to a resource or a file on disk. Note that resources can be overridden by files on disk with identical names.
Access functions:
QString | buttonSvgFile() |
void | setButtonSvgFile(const QString &svg) |
cdpLoggerRouting : QString
This property holds routing to CDP Logger component to connect. Will override connection string set in databaseUrl.
Access functions:
QString | cdpLoggerRouting() |
void | setCdpLoggerRouting(const QString &routing) |
See also databaseUrl.
closingEnabled : bool
This property holds whether the widget will be closed after selecting the database columns to display.
This option is usually set to false
when using this widget directly on a form with DatabaseGraphWidget to prevent it from disappearing after selecting the columns to display. Usually set to true
when this widget is opened in a new window.
Access functions:
bool | closingEnabled() const |
void | setClosingEnabled(bool enabled) |
See also DatabaseGraphConfigurationWidget.
contentType : CDP::GraphWidgets::SignalContent::Type
This property specifies whether to display signal name or full path (when both are available).
Access functions:
SignalContent::Type | contentType() const |
void | setContentType(SignalContent::Type type) |
databaseUrl : QUrl
This property holds connection string to the database.
Examples:
Target | Connection string |
---|---|
CDP Logger built-in server | ip://127.0.0.1:17000 |
CDPCompactDatastore file | file:///directory-path/log.db |
SQLite database file | file:///directory-path/database-file.db |
Note: Consider using cdpLoggerRouting instead of hardcoded string when connecting to CDP Logger built-in server.
Access functions:
const QUrl & | databaseUrl() const |
void | setDatabaseUrl(const QUrl &url) |
See also cdpLoggerRouting.
fontSize : int
Access functions:
int | fontSize() const |
void | setFontSize(int size) |
itemSize : QSize
This property holds the size of one item in the list of available columns.
For example this could be used to increase the height of each item in list to make it easier to use on a touchscreen.
Access functions:
const QSize & | itemSize() const |
void | setItemSize(const QSize &size) |
virtualKeyboard : bool
This property holds whether or not to open a key pad when the filter is pressed.
Access functions:
bool | virtualKeyboard() const |
void | setVirtualKeyboard(bool enabled) |
Member Function Documentation
StoredSignalSelectorWidget::StoredSignalSelectorWidget(QWidget *parent = 0)
Constructs an instance of StoredSignalSelectorWidget with parent
StoredSignalSelectorWidget::~StoredSignalSelectorWidget()
Destroys the instance of StoredSignalSelectorWidget.
[slot]
void StoredSignalSelectorWidget::hideWidget()
[slot]
void StoredSignalSelectorWidget::reconnectToDatabase()
Tries to reconnect to database. Should be called when connection has been lost.
[virtual]
void StoredSignalSelectorWidget::setCssFile(QString cssFile)
[slot]
void StoredSignalSelectorWidget::setInCommand(bool cmd)
[slot]
void StoredSignalSelectorWidget::setSmoothPixmap(bool smooth)
[slot]
void StoredSignalSelectorWidget::setWidgetFont(const QString &font)
[slot]
void StoredSignalSelectorWidget::setWidgetStyle(int style)
[slot]
void StoredSignalSelectorWidget::setWidgetTheme(const QString &theme)
[slot]
void StoredSignalSelectorWidget::showWidget()
[signal]
void StoredSignalSelectorWidget::signalClose()
[signal]
void StoredSignalSelectorWidget::signalSelectionChanged(const ColumnList &columns)
Emits list of selected columns when Apply is clicked.
Should be connected to suitable slot of DatabaseGraphWidget.
Get started with CDP Studio today
Let us help you take your great ideas and turn them into the products your customer will love.