[umbrello] [Bug 123633] new diagram type: object diagram

2022-12-04 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

Oliver Kellogg  changed:

   What|Removed |Added

   Assignee|okellogg@users.sourceforge. |umbrello-de...@kde.org
   |net |

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2022-02-15 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

Oliver Kellogg  changed:

   What|Removed |Added

 Status|ASSIGNED|CONFIRMED

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-07 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #18 from Oliver Kellogg  ---
Git commit c80e77755dfb457363000c4deacae0633b41073b by Oliver Kellogg.
Committed on 07/01/2021 at 18:28.
Pushed by okellogg into branch 'master'.

Followup to commit 3203b16a - Clean up ClassifierWidget construction:
- The constructor which had originally taken a UMLClassifier* argument
  had been changed to take UMLObject* in order to be usable also for
  UMLInstance.  Changing the argument type to UMLObject* introduced an
  error in runtime method selection due to overlap with the constructor
  taking UMLPackage* argument.  Solution:

umbrello/umlwidgets/classifierwidget.{h,cpp}
- At constructor taking UMLObject* argument revert argument type to
  UMLClassifier*.
- Add new constructor taking UMLInstance* argument.

M  +28   -7umbrello/umlwidgets/classifierwidget.cpp
M  +2-1umbrello/umlwidgets/classifierwidget.h

https://invent.kde.org/sdk/umbrello/commit/c80e77755dfb457363000c4deacae0633b41073b

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-07 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #17 from Oliver Kellogg  ---
Git commit 9cd1e80cabc347a3dd07e9de3e68d13cc040fd57 by Oliver Kellogg.
Committed on 07/01/2021 at 11:34.
Pushed by okellogg into branch 'master'.

Create listview item for untyped UMLInstance after loading from XMI:

umbrello/uml1model/instance.cpp
- In function resolveRef add calls to maybeSignalObjectCreated().

M  +5-4umbrello/uml1model/instance.cpp

https://invent.kde.org/sdk/umbrello/commit/9cd1e80cabc347a3dd07e9de3e68d13cc040fd57

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-06 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #16 from Oliver Kellogg  ---
Git commit 3337da29ac1b938a6a5bb704620ee226332d8171 by Oliver Kellogg.
Committed on 07/01/2021 at 06:54.
Pushed by okellogg into branch 'master'.

Followup to commit 3203b16a work on UML Instances,
> Inheritance cleanup:
> - UMLInstance is derived from UMLObject (this might be changed to
>   UMLCanvasObject in future).

umbrello/uml1model/instance.{h,cpp}
- Derive UMLInstance from UMLCanvasObject.
- Remove function findChildObjectById, use inherited function.
- Remove type AttributeValues and function getAttrValues, use function
  subordinates() of superclass.
- Remove member m_attrValues, it is obsoleted by UMLCanvasObject member
  m_List.

umbrello/umlwidgets/classifierwidget.cpp
- Synchronize function drawMembers with the above changes.

umbrello/umllistview.cpp
- In function connectNewObjectsSlots fix indentation of switch cases.
- Synchronize functions addNewItem and loadChildrenFromXMI with the
  changes in class UMLInstance.

M  +14   -34   umbrello/uml1model/instance.cpp
M  +4-20   umbrello/uml1model/instance.h
M  +53   -46   umbrello/umllistview.cpp
M  +10   -4umbrello/umlwidgets/classifierwidget.cpp

https://invent.kde.org/sdk/umbrello/commit/3337da29ac1b938a6a5bb704620ee226332d8171

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-06 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #15 from Oliver Kellogg  ---
Git commit 3203b16acd7adfbed909bdfe7be40eb5c302dad0 by Oliver Kellogg.
Committed on 06/01/2021 at 14:26.
Pushed by okellogg into branch 'master'.

Further work on UML Instances. Main changes:

- Design cleanup: UMLInstance is slaved to UMLClassifier.
  Prominently, UMLInstance does not duplicate the UML attributes but
  holds references to the UML attributes.  The only additional item
  stored in UMLInstanceAttribute is the concrete attribute value.
- Inheritance cleanup:
  - UMLInstanceAttribute is derived from UMLObject.
  - UMLInstance is derived from UMLObject (this might be changed to
UMLCanvasObject in future).
- Improvements in ClassifierWidget for handling instances.
- In list view,
  - in the menu popping up on right click on a class there is an
additional choice "Instance". When selected, the attributes of
the class are automatically transformed into the instance attributes
of the new instance;
  - when a classifier derived instance has been created, an instance
attribute value can be modified by double clicking on the instance
attribute. Note that attribute _name_ change is not possible here;
name change shall be done only using the master classifier.
- Improved XMI format for saving UMLInstanceAttribute.

Detailed changes:

umbrello/uml1model/instance.h
- Extend class documentation.  Distinguish standalone instance from
  instance slaved to classifier.
- Inherit from UMLObject instead of from UMLClassifier.
- Add Q_OBJECT declaration.
- At constructor add optional argument UMLClassifier *classifier
  defaulting to nullptr.
- Remove setter/getter for classifier name.
- At function setClassifierCmd add optional argument bool emitSignal
  defaulting to true.
- Remove function createAttribute (attribute creation and removal is
  done only via UMLClassifier; instance attributes are strictly slaved
  to the classifier attributes).
- Add function findChildObjectById(Uml::ID::Type) returning pointer to
  UMLInstanceAttribute.
- New type AttributeValues is a typedef of QList.
  It contains the attribute values in case this UMLInstance is slaved
  to a classifier.
- Add function getAttrValues returning AttributeValues&.
- Remove member m_classifier.
  The related classifier is now stored in UMLObject::m_pSecondary.
- Add member m_attrValues of type AttributeValues.
- Add public slots attributeAdded(UMLClassifierListItem*) and
  attributeRemoved(UMLClassifierListItem*).  In case the instance is
  slaved to a classifier they are connected to the corresponding signals
  of m_classifier.

umbrello/uml1model/instance.cpp
- In constructor,
  - remove call to Object_Factory::createUMLObject for creating the
master class;
  - assign m_classifier from argument `c';
  - call setClassifierCmd(c, false).
- Adapt functions setClassifier and setClassifierCmd to replacement of
  m_classifier by UMLObject::m_pSecondary.
- In function setClassifierCmd, if classifier is non null then
  - create a UMLInstanceAttribute for each of the classifier's
attributes and fill m_attrValues;
  - connect the classifier's attributeAdded/attributeRemoved signals to
the instance's corresponding slots.
- Adjust function classifier() to m_pSecondary possibly being null (in
  case of an untyped instance).
- New function findChildObjectById seeks the given ID in the XMI IDs of
  m_attrValues and returns pointer to the UMLInstanceAttribute if found.
- New function getAttrValues returns m_attrValues.
- Adjust function saveToXMI1 to use of m_pSecondary for the classifier.
- Adjust function load1 to load the instance attributes from XML tag
  "slot" instead of "UML:InstanceAttribute".
- Adjust function resolveRef to the possibility of m_pSecondary
  legitimately being nullptr.
- In new slot function attributeAdded, add UMLInstanceAttribute
  corresponding to the UMLAttribute into m_attrValues.
- In new slot function attributeRemoved, iterate over m_attrValues and
  test whether the given item is equal to one of the InstanceAttribute's
  parent. Remove the matching instance attribute from m_attrValues.

umbrello/uml1model/instanceattribute.{h,cpp}
- Extend class documentation mentioning that the UMLInstanceAttribute is
  strictly slaved to its corresponding classifier's UMLAttribute.
- Inherit from UMLObject instead of from UMLAttribute.
- At constructor,
  - change type of `parent' to UMLInstance* to more precisely express
the expected parent type;
  - replace arguments `name', `id', `s', `type' by argument umlAttr of
type UMLAttribute*.
UMLObject::m_pSecondary is used for saving the master attribute.
- Remove explicit constructor with single argument `parent'.
- Add accessors setAttribute, getAttribute.
- Remove accessors setAttributes, getAttributes.
- New function toString returns the textual notation for the instance
  attribute.
- Remove member m_attributes.
- Add member m_value.

umbrello/uml1model/instan

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-05 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #14 from Oliver Kellogg  ---
Git commit ef4241900e0f65b2c9e4b3b902baefca3a8468fb by Oliver Kellogg.
Committed on 05/01/2021 at 20:59.
Pushed by okellogg into branch 'master'.

umbrello/menus/listpopupmenu.cpp
- In function insertContainerItems(KMenu*, bool, bool, bool) add call to
  insert(mt_Instance, menu).

M  +2-1umbrello/menus/listpopupmenu.cpp

https://invent.kde.org/sdk/umbrello/commit/ef4241900e0f65b2c9e4b3b902baefca3a8468fb

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-05 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #13 from Oliver Kellogg  ---
Git commit 5015ce47e0a547428668c3243aa933abdbf0c6d2 by Oliver Kellogg.
Committed on 05/01/2021 at 21:18.
Pushed by okellogg into branch 'master'.

umbrello/umlwidgets/associationwidget.cpp
- In function setUMLObject add TODO note on case ot_InstanceAttribute
  and comment this case out.

M  +4-1umbrello/umlwidgets/associationwidget.cpp

https://invent.kde.org/sdk/umbrello/commit/5015ce47e0a547428668c3243aa933abdbf0c6d2

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-05 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #12 from Oliver Kellogg  ---
Git commit e491e53a40413183c8ba2177d1228debca493e02 by Oliver Kellogg.
Committed on 05/01/2021 at 20:32.
Pushed by okellogg into branch 'master'.

umbrello/uml1model/umlcanvasobject.cpp
- In function uniqChildName change case UMLObject::ot_InstanceAttribute
  to UMLObject::ot_Instance.

M  +2-2umbrello/uml1model/umlcanvasobject.cpp

https://invent.kde.org/sdk/umbrello/commit/e491e53a40413183c8ba2177d1228debca493e02

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-05 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #11 from Oliver Kellogg  ---
(In reply to Ralf Habacker from comment #6)
> [...]
> Remaining issues:
> Implementation does not follow UML 1.4 standard because of using umbrello
> specific XMI tag UML:InstanceAttribute.

In the upcoming commit I change  to ,
I believe this is more in line with UML 1.4.
Furthermore, a slot does not replicate the UMLAttribute but instead has an XML
attribute named "attribute" referencing the xmi.id of the corresponding
. The slot only adds the XML attribute "value" giving the
concrete value for the UMLAttribute.

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2021-01-05 Thread Oliver Kellogg
https://bugs.kde.org/show_bug.cgi?id=123633

Oliver Kellogg  changed:

   What|Removed |Added

 CC||okellogg@users.sourceforge.
   ||net
   Assignee|laysrodriguessi...@gmail.co |okellogg@users.sourceforge.
   |m   |net

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-03-06 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #10 from Ralf Habacker  ---
Created attachment 104421
  --> https://bugs.kde.org/attachment.cgi?id=104421&action=edit
related xmi model file

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-03-06 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

Ralf Habacker  changed:

   What|Removed |Added

 Attachment #104418|0   |1
is obsolete||

--- Comment #9 from Ralf Habacker  ---
Created attachment 104420
  --> https://bugs.kde.org/attachment.cgi?id=104420&action=edit
State of implemented use cases (update)

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-03-06 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #8 from Ralf Habacker  ---
Created attachment 104418
  --> https://bugs.kde.org/attachment.cgi?id=104418&action=edit
State of implemented use cases

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-03-01 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #7 from Ralf Habacker  ---
Git commit 576a4346ba591796142d716b2dab00fc86ae5708 by Ralf Habacker.
Committed on 02/03/2017 at 06:48.
Pushed by habacker into branch 'master'.

Refactor UMLInstance to be more UML and XMI 1.4 compatible.

- Create classifier instance on construction if not present
  and save it internal instead to be a non sharable classifier.
  Class UMLInstance itself stays to be derived from UMLClassifier
  because of the usage of UMLAttribute representing instance
  attributes.
- Save and load 'classifier' attribute to be xmi 1.4 compatible

M  +0-2CMakeLists.txt
M  +1-1umbrello/CMakeLists.txt
M  +1-1umbrello/cmds.h
R  +13   -14   umbrello/cmds/generic/cmdrenameumlinstancetype.cpp [from:
umbrello/cmds/generic/cmdrenameumlinstance.cpp - 056% similarity]
R  +17   -13   umbrello/cmds/generic/cmdrenameumlinstancetype.h [from:
umbrello/cmds/generic/cmdrenameumlinstance.h - 055% similarity]
M  +4-5umbrello/dialogs/pages/classgeneralpage.cpp
M  +98   -17   umbrello/uml1model/instance.cpp
M  +11   -4umbrello/uml1model/instance.h
M  +1-2umbrello/umlwidgets/associationwidget.cpp
M  +23   -9umbrello/umlwidgets/classifierwidget.cpp
M  +3-0umbrello/umlwidgets/widget_factory.cpp

https://commits.kde.org/umbrello/576a4346ba591796142d716b2dab00fc86ae5708

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-02-26 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #6 from Ralf Habacker  ---
Branch work/123633 has been merged into master. 

The following fixes has been applied after the merge to git master to fix
issues with the implementation:

1c382a7 Fixup of c91a4bf.
e5fd427 Do not write unrelated xmi attributes for UMLInstance.
c91a4bf Do not write unrelated xmi attributes for instance widgets.
509d7a2 umbrello-diagrams.dtd: Add element 'instancewidget'.
9676daf Keep getting widget name in ClassifierWidget::paint() in sync with
ClassifierWidget::calculateSize().
09347ce Enable drag and drop of instance widgets from list view.
cb210c0 Rename class CmdRenameUMLObjectInstance to CmdRenameUMLInstance.
1702611 Merge duplicate references to i18n("Instance name:") into
UMLObject::toI18nString().
317ccaf Fix incorrect i18n name for ot_Instance in UMLObject::toI18nString().
7372cd8 Keep instance and class name edit widget in the same order in
ClassGeneralPage.
de2c7a8 Remove duplicated implementation for entering instance name in class
ClassGeneralPage.
1732503 Move UMLObject::m_instanceName to UMLInstance where it belongs.
111e448 Limit object diagram support to master branch for now.
3a03de1 Fix duplicated label imported from frameworks branch.
f459e4b Change order of "rename" context menu entries for object and instance
widgets.
8bab98e Add layout config files for object diagrams.
beee90f Cleanup code for case WidgetBase::wt_Object in
ListPopupMenu::insertSingleSelectionMenu().
abb0b7e Fix bug showing "New"->"Class" in object diagrams context menu.
8cc52e3 Indention fix.
343297d Add missing ':' to UMLInstance objects in UMLObject::toI18nString().
fb7630d Indention fix.
077b5ac Fix instance attribute width calculation for displaying instances in
ClassifierWidget.
6ff72fc Fix calculating of width in ClassifierWidget on showing instances.
a4294f9 Add loading cursors from embedded pixmaps.
dfc5c0a Indention fix.
859d9b0 Merge multiple usage of i18n("Rename object...")
796b901 Add implementation of ListPopupMenu::mt_Rename_Object for instance
widgets.
3b3eb3c Allow assocations between instances.
61a916f Add default diagram name for object diagrams.

Remaining issues:
Implementation does not follow UML 1.4 standard because of using umbrello
specific XMI tag UML:InstanceAttribute. Additional UMLInstance is the
classifier and do not references a classifier which creates non sharable and
incomplete classifiers.

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-02-17 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #5 from Ralf Habacker  ---
Git commit 96b5ddc666ee22cab013c5a78b37a3c2fb4a1b1d by Ralf Habacker.
Committed on 17/02/2017 at 11:21.
Pushed by habacker into branch 'work/123633'.

Add icon for object diagram.

M  +1-0umbrello/icons.qrc
M  +1-0umbrello/pics/CMakeLists.txt
A  +---umbrello/pics/diag_object.png
A  +765  -0umbrello/pics/sources/diag_object.svg

https://commits.kde.org/umbrello/96b5ddc666ee22cab013c5a78b37a3c2fb4a1b1d

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-02-17 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

--- Comment #4 from Ralf Habacker  ---
Git commit 28b760607df4af71f3563a61cc260379e92e17b9 by Ralf Habacker.
Committed on 17/02/2017 at 09:12.
Pushed by habacker into branch 'work/123633'.

Extracted object diagram support from frameworks branch.

This patch already contains a few fixes:
- added missing copyright header
- Fix api changes (constructor)

Open issues:
- Instance related setup in ClassGeneralPage seems
  to be duplicated -> needs review
- missing icons for instance in tool bar
- missing icons for object diagram in diagram toolbar list

To test:
- test load/save

M  +5-0umbrello/CMakeLists.txt
M  +4-0umbrello/basictypes.cpp
M  +1-0umbrello/basictypes.h
M  +1-0umbrello/cmds.h
A  +43   -0umbrello/cmds/generic/cmdrenameumlobjectinstance.cpp
[License: GPL (v2+)]
A  +36   -0umbrello/cmds/generic/cmdrenameumlobjectinstance.h [License:
GPL (v2+)]
M  +33   -8umbrello/dialogs/pages/classgeneralpage.cpp
M  +2-0umbrello/dialogs/pages/classgeneralpage.h
M  +9-0umbrello/dialogs/pages/classifierlistpage.cpp
A  +67   -0umbrello/dialogs/umlinstanceattributedialog.cpp [License:
GPL (v2+)]
A  +41   -0umbrello/dialogs/umlinstanceattributedialog.h [License: GPL
(v2+)]
A  +54   -0umbrello/dialogs/umlinstanceattributedialog.ui
M  +8-0umbrello/icon_utils.cpp
M  +2-0umbrello/icon_utils.h
M  +56   -2umbrello/listpopupmenu.cpp
M  +7-0umbrello/listpopupmenu.h
M  +55   -3umbrello/model_utils.cpp
M  +14   -1umbrello/object_factory.cpp
M  +45   -16   umbrello/toolbarstateother.cpp
M  +1-0umbrello/umbrelloui.rc
M  +14   -0umbrello/uml.cpp
M  +1-0umbrello/uml.h
M  +22   -1umbrello/umllistview.cpp
M  +14   -2umbrello/umllistviewitem.cpp
M  +3-0umbrello/umllistviewitem.h
M  +13   -0umbrello/umlmodel/classifier.cpp
A  +112  -0umbrello/umlmodel/instance.cpp [License: GPL (v2+)]
A  +41   -0umbrello/umlmodel/instance.h [License: GPL (v2+)]
A  +104  -0umbrello/umlmodel/instanceattribute.cpp [License: GPL (v2+)]
A  +51   -0umbrello/umlmodel/instanceattribute.h [License: GPL (v2+)]
M  +1-1umbrello/umlmodel/package.cpp
M  +3-0umbrello/umlmodel/umlcanvasobject.cpp
M  +34   -1umbrello/umlmodel/umlobject.cpp
M  +14   -1umbrello/umlmodel/umlobject.h
M  +14   -0umbrello/umlscene.cpp
M  +9-1umbrello/umlwidgets/associationwidget.cpp
M  +51   -3umbrello/umlwidgets/classifierwidget.cpp
M  +1-0umbrello/umlwidgets/classifierwidget.h
M  +10   -1umbrello/umlwidgets/widget_factory.cpp
M  +9-1umbrello/umlwidgets/widgetbase.cpp
M  +1-0umbrello/umlwidgets/widgetbase.h
M  +14   -4umbrello/worktoolbar.cpp
M  +3-1umbrello/worktoolbar.h

https://commits.kde.org/umbrello/28b760607df4af71f3563a61cc260379e92e17b9

-- 
You are receiving this mail because:
You are watching all bug changes.

[umbrello] [Bug 123633] new diagram type: object diagram

2017-02-16 Thread Ralf Habacker
https://bugs.kde.org/show_bug.cgi?id=123633

Ralf Habacker  changed:

   What|Removed |Added

Summary|new diagram type: instance  |new diagram type: object
   |diagram |diagram

-- 
You are receiving this mail because:
You are watching all bug changes.