umbrello 2.34.70-5524f40e1
Umbrello UML Modeller is a Unified Modelling Language (UML) diagram program based on KDE Technology
|
A graphical version of a UML Activity. More...
#include <activitywidget.h>
Public Types | |
enum | ActivityType { Initial = 0 , Normal , End , Final , Branch , Invok , Param } |
![]() | |
enum | FontType { FT_NORMAL = 0 , FT_BOLD = 1 , FT_ITALIC = 2 , FT_UNDERLINE = 3 , FT_BOLD_ITALIC = 4 , FT_BOLD_UNDERLINE = 5 , FT_ITALIC_UNDERLINE = 6 , FT_BOLD_ITALIC_UNDERLINE = 7 , FT_INVALID = 8 } |
enum | AddWidgetOption { NoOption = 0 , SetupSize = 1 , SwitchDirection = 2 , ShowProperties = 4 , Default = SetupSize | ShowProperties } |
![]() | |
enum | WidgetType { wt_Min = 299 , wt_UMLWidget , wt_Actor , wt_UseCase , wt_Class , wt_Interface , wt_Datatype , wt_Enum , wt_Entity , wt_Package , wt_Object , wt_Note , wt_Box , wt_Message , wt_Text , wt_State , wt_Activity , wt_Component , wt_Artifact , wt_Node , wt_Association , wt_ForkJoin , wt_Precondition , wt_CombinedFragment , wt_FloatingDashLine , wt_Signal , wt_Pin , wt_ObjectNode , wt_Region , wt_Category , wt_Port , wt_Instance , wt_Max } |
Public Slots | |
virtual void | slotMenuSelection (QAction *action) |
![]() | |
virtual void | updateWidget () |
virtual void | slotMenuSelection (QAction *action) |
virtual void | slotWidgetMoved (Uml::ID::Type id) |
virtual void | slotFillColorChanged (Uml::ID::Type viewID) |
virtual void | slotLineColorChanged (Uml::ID::Type viewID) |
virtual void | slotTextColorChanged (Uml::ID::Type viewID) |
virtual void | slotLineWidthChanged (Uml::ID::Type viewID) |
void | slotSnapToGrid () |
![]() | |
virtual void | slotMenuSelection (QAction *trigger) |
Signals | |
void | sigActMoved (qreal diffX, qreal diffY) |
![]() | |
void | sigWidgetMoved (Uml::ID::Type id) |
Static Public Member Functions | |
static bool | isActivity (WorkToolBar::ToolBar_Buttons tbb, ActivityType &resultType) |
![]() | |
static QString | toString (WidgetType wt) |
static QString | toI18nString (WidgetType wt) |
static Icon_Utils::IconType | toIcon (WidgetType wt) |
static bool | widgetHasUMLObject (WidgetBase::WidgetType type) |
Protected Member Functions | |
virtual QSizeF | minimumSize () const |
virtual QSizeF | maximumSize () |
![]() | |
virtual void | contextMenuEvent (QGraphicsSceneContextMenuEvent *event) |
virtual void | mouseDoubleClickEvent (QGraphicsSceneMouseEvent *event) |
virtual void | mousePressEvent (QGraphicsSceneMouseEvent *event) |
virtual void | mouseMoveEvent (QGraphicsSceneMouseEvent *event) |
virtual void | mouseReleaseEvent (QGraphicsSceneMouseEvent *event) |
virtual void | moveEvent (QGraphicsSceneMouseEvent *event) |
virtual void | constrainMovementForAllWidgets (qreal &diffX, qreal &diffY) |
virtual bool | isInResizeArea (QGraphicsSceneMouseEvent *me) |
virtual QCursor | resizeCursor () const |
void | selectSingle (QGraphicsSceneMouseEvent *me) |
void | selectMultiple (QGraphicsSceneMouseEvent *me) |
void | deselect (QGraphicsSceneMouseEvent *me) |
void | setSelectionBounds () |
void | resize (QGraphicsSceneMouseEvent *me) |
bool | wasSizeChanged () |
bool | wasPositionChanged () |
virtual void | toForeground () |
void | addConnectedWidget (UMLWidget *widget, Uml::AssociationType::Enum type=Uml::AssociationType::Association, AddWidgetOptions options=Default) |
void | addConnectedUMLObject (UMLObject::ObjectType otype, Uml::AssociationType::Enum type) |
void | addWidget (UMLWidget *widget, bool showProperties=true) |
![]() | |
QVariant | itemChange (GraphicsItemChange change, const QVariant &value) |
![]() | |
DiagramProxyWidget & | operator= (const DiagramProxyWidget &other) |
bool | activate (IDChangeLog *changeLog=0) |
bool | loadFromXMI (QDomElement &qElement) |
void | saveToXMI (QXmlStreamWriter &writer) |
void | setupEvent (QGraphicsSceneMouseEvent &e, const QGraphicsSceneMouseEvent *event, const QPointF &pos) const |
void | setupEvent (QGraphicsSceneContextMenuEvent &e, const QGraphicsSceneContextMenuEvent *event, const QPointF &pos) const |
void | slotMenuSelection (QAction *action) |
Protected Attributes | |
ActivityType | m_activityType |
Type of activity. More... | |
QString | m_preconditionText |
QString | m_postconditionText |
![]() | |
QString | m_instanceName |
instance name (used if on a deployment diagram) More... | |
bool | m_isInstance |
holds whether this widget is a component instance (i.e. on a deployment diagram) More... | |
Uml::ShowStereoType::Enum | m_showStereotype |
if and how the stereotype should be displayed More... | |
bool | m_startMove |
QPointF | m_startMovePostion |
QSizeF | m_startResizeSize |
int | m_nPosX |
UMLDoc * | m_doc |
shortcut for UMLApp::app()->document() More... | |
bool | m_resizable |
QFontMetrics * | m_pFontMetrics [FT_INVALID] |
QSizeF | m_minimumSize |
QSizeF | m_maximumSize |
bool | m_activated |
true if the activate function has been called for this class instance More... | |
bool | m_ignoreSnapToGrid |
bool | m_ignoreSnapComponentSizeToGrid |
bool | m_fixedAspectRatio |
QString | m_oldStatusBarMsg |
The text in the status bar when the cursor was pressed. More... | |
QPointF | m_pressOffset |
QPointF | m_oldPos |
The X/Y position the widget had when the movement started. More... | |
qreal | m_oldW |
The width/height the widget had when the resize started. More... | |
qreal | m_oldH |
bool | m_shiftPressed |
If shift or control button were pressed in mouse press event. More... | |
bool | m_inMoveArea |
bool | m_inResizeArea |
bool | m_moved |
bool | m_resized |
![]() | |
UMLScene * | m_scene |
QPointer< UMLObject > | m_umlObject |
QString | m_Doc |
Only used if m_umlObject is not set. More... | |
QString | m_Text |
QRectF | m_rect |
Widget size. In this rectangle, the x and y coordinates are always 0. More... | |
Uml::ID::Type | m_nId |
Uml::ID::Type | m_nLocalID |
QColor | m_textColor |
Color of the text of the widget. Is saved to XMI. More... | |
QColor | m_lineColor |
Color of the lines of the widget. Is saved to XMI. More... | |
QColor | m_fillColor |
color of the background of the widget More... | |
QBrush | m_brush |
QFont | m_font |
uint | m_lineWidth |
Width of the lines of the widget. Is saved to XMI. More... | |
bool | m_useFillColor |
flag indicates if the UMLWidget uses the Diagram FillColour More... | |
bool | m_usesDiagramFillColor |
bool | m_usesDiagramLineColor |
bool | m_usesDiagramLineWidth |
bool | m_usesDiagramTextColor |
bool | m_usesDiagramUseFillColor |
bool | m_autoResize |
bool | m_changesShape |
The widget changes its shape when the number of connections or their positions are changed. More... | |
![]() | |
bool | m_calledFromItemChange {false} |
Additional Inherited Members | |
![]() | |
static const QSizeF | DefaultMinimumSize |
static const QSizeF | DefaultMaximumSize |
static const int | defaultMargin = 5 |
static const int | selectionMarkerSize = 4 |
static const int | resizeMarkerLineCount = 3 |
A graphical version of a UML Activity.
This class is the graphical version of a UML Activity. A ActivityWidget is created by a UMLView. An ActivityWidget belongs to only one UMLView instance. When the UMLView instance that this class belongs to, it will be automatically deleted.
The ActivityWidget class inherits from the UMLWidget class which adds most of the functionality to this class.
|
explicit |
Creates an Activity widget.
scene | The parent of the widget. |
activityType | The type of activity. |
id | The ID to assign (-1 will prompt a new ID.) |
|
virtual |
Destructor.
ActivityWidget::ActivityType ActivityWidget::activityType | ( | ) | const |
Returns the type of activity.
QString ActivityWidget::activityTypeStr | ( | ) | const |
Returns the type string of activity.
|
virtual |
|
static |
Determines whether a toolbar button represents an Activity. CHECK: currently unused - can this be removed?
tbb | The toolbar button enum input value. |
resultType | The ActivityType corresponding to tbb. This is only set if tbb is an Activity. |
|
virtual |
Loads the widget from the "activitywidget" XMI element.
Reimplemented from UMLWidget.
|
protectedvirtual |
|
protectedvirtual |
|
virtual |
Overridden from UMLWidget due to emission of signal sigActMoved()
Reimplemented from UMLWidget.
|
virtual |
Overrides the standard paint event.
Reimplemented from UMLWidget.
QString ActivityWidget::postconditionText | ( | ) | const |
This method get the name of the postText attribute.
QString ActivityWidget::preconditionText | ( | ) | const |
This method get the name of the preText attribute.
|
virtual |
Saves the widget to the "activitywidget" XMI element.
Reimplemented from UMLWidget.
void ActivityWidget::setActivityType | ( | ActivityType | activityType | ) |
Sets the type of activity.
void ActivityWidget::setPostconditionText | ( | const QString & | aPostText | ) |
This method set the name of the postText attribute
void ActivityWidget::setPreconditionText | ( | const QString & | aPreText | ) |
This method set the name of the preText attribute
|
virtual |
Reimplemented from UMLWidget::showPropertiesDialog to show a properties dialog for an ActivityWidget.
Reimplemented from UMLWidget.
|
signal |
Emitted when the activity widget is moved. Provides the delta X and delta Y amount by which the widget was moved relative to the previous position. Slots into PinWidget::slotActMoved()
diffX | The difference between previous and new X value. |
diffY | The difference between previous and new Y value. |
|
virtualslot |
Captures any popup menu signals for menus it created.
|
protected |
Type of activity.
|
protected |
|
protected |