Graphics/AssociationItem.py

changeset 5587
ea526b78ee6c
parent 5389
9b1c800daff3
child 6048
82ad8ec9548c
diff -r 0e5421d679e7 -r ea526b78ee6c Graphics/AssociationItem.py
--- a/Graphics/AssociationItem.py	Tue Mar 07 18:46:09 2017 +0100
+++ b/Graphics/AssociationItem.py	Tue Mar 07 18:53:18 2017 +0100
@@ -41,14 +41,14 @@
     The association is drawn as an arrow starting at the first items and
     ending at the second.
     """
-    def __init__(self, itemA, itemB, type=Normal, topToBottom=False,
+    def __init__(self, itemA, itemB, assocType=Normal, topToBottom=False,
                  parent=None):
         """
         Constructor
         
         @param itemA first widget of the association
         @param itemB second widget of the association
-        @param type type of the association. This must be one of
+        @param assocType type of the association. This must be one of
             <ul>
             <li>Normal (default)</li>
             <li>Generalisation</li>
@@ -58,13 +58,13 @@
             from item A top to item B bottom (boolean)
         @keyparam parent reference to the parent object (QGraphicsItem)
         """
-        if type == Normal:
+        if assocType == Normal:
             arrowType = NormalArrow
             arrowFilled = True
-        elif type == Imports:
+        elif assocType == Imports:
             arrowType = NormalArrow
             arrowFilled = True
-        elif type == Generalisation:
+        elif assocType == Generalisation:
             arrowType = WideArrow
             arrowFilled = False
         
@@ -83,7 +83,7 @@
         
         self.itemA = itemA
         self.itemB = itemB
-        self.assocType = type
+        self.assocType = assocType
         self.topToBottom = topToBottom
         
         self.regionA = NoRegion

eric ide

mercurial