root/gaphor/tags/gaphor-0.3.0/gaphor/diagram/README

Revision 209, 1.0 kB (checked in by arjanmol, 5 years ago)

*** empty log message ***

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1 Diagram items
2
3 Diagrams typically contain a diacanvas.Canvas. This Canvas contains a bunch of
4 items. Those items are one way or another related to some UML.Element.
5
6 In the UML module a class Presentation is defined. It defines the relation
7 between one Element and its Presentations.
8
9 In the UML module all relations between objects are presented as associations.
10
11 There are some conflicts that have to be resolved when using Presentation in
12 conjunction with diacanvas.CanvasItem:
13
14 The default signature of the methods connect() and disconnect() is slightly
15 different.
16
17 This is resolved by overriding connect() and disconnect() and let them act
18 the same way as UML.Element's.
19 The unlink() method is added to remove the item from the canvas. This should
20 be used in stead of disconnecting directly from the parent object.
21
22 A __unlink__ signal is added.
23
24 Element.presentation connects to '__unlink__' of Presentation.subject.
25
26 Note that the subject notifiers are not called during loading, since no
27 notifications are send during loading.
28
Note: See TracBrowser for help on using the browser.