FloatingTextWidgetController Class Reference
Controller for FloatingTextWidget. More...
#include <floatingtextwidgetcontroller.h>
Inheritance diagram for FloatingTextWidgetController:

Public Member Functions | |
| FloatingTextWidgetController (FloatingTextWidget *floatingTextWidget) | |
| Constructor for FloatingTextWidgetController. | |
| ~FloatingTextWidgetController () | |
| Destructor for MessageWidgetController. | |
Protected Member Functions | |
| virtual void | saveWidgetValues (QMouseEvent *me) |
| Overridden from UMLWidgetController. | |
| virtual bool | isInResizeArea (QMouseEvent *me) |
| Overridden from UMLWidgetController. | |
| virtual void | moveWidgetBy (int diffX, int diffY) |
| Overridden from UMLWidgetController. | |
| virtual void | constrainMovementForAllWidgets (int &diffX, int &diffY) |
| Overridden from UMLWidgetController. | |
Detailed Description
Controller for FloatingTextWidget.When moving a FloatingTextWidget, it is constrained using constrainTextPos method from the LinkWidget, if any. This applies both when moving as part of a selection and when constraining the move of the selection because it's the receiver of mouse move events. The only exception to this is that when moving the widget, if it's a sequence message and the message widget is selected, the floating text widget isn't moved itself, but automatically by the message widget. If the sequence message wasn't part of the selection, the floating text widget moves it. When moving the floating text as part of a selection, if the position of the floating text is constrained, it's kept at that position until it can be moved to another valid position. No resize is allowed for FloatingTextWidget.
- Author:
- Umbrello UML Modeller Authors <uml-devel@lists.sourceforge.net>
Definition at line 38 of file floatingtextwidgetcontroller.h.
Constructor & Destructor Documentation
|
|
Constructor for FloatingTextWidgetController.
Definition at line 21 of file floatingtextwidgetcontroller.cpp. |
|
|
Destructor for MessageWidgetController.
Definition at line 30 of file floatingtextwidgetcontroller.cpp. |
Member Function Documentation
|
|
Overridden from UMLWidgetController. Saves the values of the widget needed for move/resize. Calls parent method and then saves the value of m_unconstrainedPositionX/Y and m_movementDirectionX/Y.
Reimplemented from UMLWidgetController. Definition at line 33 of file floatingtextwidgetcontroller.cpp. References UMLWidget::getX(), UMLWidget::getY(), and UMLWidgetController::saveWidgetValues(). |
|
|
Overridden from UMLWidgetController. FloatingTextWidgets can't be resized, so this method always returns false. Cursor isn't changed.
Reimplemented from UMLWidgetController. Definition at line 42 of file floatingtextwidgetcontroller.cpp. |
|
||||||||||||
|
Overridden from UMLWidgetController. Moves the widget to a new position using the difference between the current position and the new position. If the floating text widget is part of a sequence message, and the message widget is selected, it does nothing: the message widget will update the text position when it's moved. In any other case, the floating text widget constrains its move using constrainPosition. When the position of the floating text is constrained, it's kept at that position until it can be moved to another valid position (m_unconstrainedPositionX/Y and m_movementDirectionX/Y are used for that). Moreover, if is part of a sequence message (and the message widget isn't selected), it updates the position of the message widget.
Reimplemented from UMLWidgetController. Definition at line 46 of file floatingtextwidgetcontroller.cpp. References LinkWidget::calculateNameTextSegment(), UMLWidget::getHeight(), UMLWidget::getSelected(), MessageWidget::getSequenceMessageType(), MessageWidget::getWidget(), UMLWidget::getX(), UMLWidget::getY(), FloatingTextWidget::m_pLink, FloatingTextWidget::m_Role, UMLWidget::setX(), and UMLWidget::setY(). |
|
||||||||||||
|
Overridden from UMLWidgetController. Modifies the value of the diffX and diffY variables used to move the widgets. The values are constrained using constrainPosition.
Reimplemented from UMLWidgetController. Definition at line 100 of file floatingtextwidgetcontroller.cpp. References UMLWidget::getX(), and UMLWidget::getY(). |
The documentation for this class was generated from the following files:
