umbrello 2.39.0
Umbrello UML Modeller is a Unified Modelling Language (UML) diagram program based on KDE Technology
|
#include <defaultvaluewidget.h>
Classes | |
class | Private |
Public Slots | |
void | setType (UMLObject *type) |
void | setType (const QString &type) |
Public Member Functions | |
DefaultValueWidget (UMLObject *type, const QString &value, QWidget *parent=nullptr) | |
~DefaultValueWidget () | |
void | addToLayout (QGridLayout *layout, int row) |
QString | value () const |
Protected Member Functions | |
void | showEvent (QShowEvent *event) |
void | hideEvent (QHideEvent *event) |
Private Attributes | |
Private * | m_d |
Widget for showing/editing default values
Depending on the given UML data type the widget shows either a simple edit line or a list box with enum literals from which the user can select entries.
|
explicit |
DefaultValueWidget::~DefaultValueWidget | ( | ) |
void DefaultValueWidget::addToLayout | ( | QGridLayout * | layout, |
int | row ) |
Add this widget to a given grid layout. Umbrello dialogs places labels in column 0 and the editable field in column 1.
layout | The layout to which the widget should be added |
row | The row in the grid layout where the widget should be placed |
|
protected |
Reimplemented from QWidget to control widgets visible state in case addToLayout() has been called
event | hide event |
|
slot |
Update widget with data type from a text string
The method searches for a uml object with the specified name. If an object was found, the display of the selectable options depends on the type.
_type | type as text to set the widget from |
|
slot |
Update widget with new data type
type | type to set widget from |
|
protected |
Reimplemented from QWidget to control widgets visible state in case addToLayout() has been called
event | show event |
QString DefaultValueWidget::value | ( | ) | const |
return current text either from list box or from edit field
|
private |