blob: d445ebfa680d8a544cb010837ed08a8282c810cd [file] [log] [blame]
mwenzb5dc2f92010-06-16 13:24:52 +00001<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2<html>
3<head>
4<meta name="generator" content=
5"HTML Tidy for Windows (vers 25 March 2009), see www.w3.org">
6<meta http-equiv="Content-Type" content=
7"text/html; charset=us-ascii">
8<meta name="Generator" content="Microsoft Word 12 (filtered)">
9<title>Selection behavior</title>
10<link rel="Stylesheet" type="text/css" media="all" href=
11"../book.css">
12<style type="text/css">
13<!--
14 /* Font Definitions */
15 @font-face
16 {font-family:"Cambria Math";
17 panose-1:2 4 5 3 5 4 6 3 2 4;}
18@font-face
19 {font-family:Cambria;
20 panose-1:2 4 5 3 5 4 6 3 2 4;}
21@font-face
22 {font-family:Tahoma;
23 panose-1:2 11 6 4 3 5 4 4 2 4;}
24@font-face
25 {font-family:Consolas;
26 panose-1:2 11 6 9 2 2 4 3 2 4;}
27 /* Style Definitions */
28 p.MsoNormal, li.MsoNormal, div.MsoNormal
29 {margin:0cm;
30 margin-bottom:.0001pt;
31 font-size:12.0pt;
32 font-family:"Times New Roman","serif";}
33h1
jpaschfa239712010-06-23 12:00:55 +000034 {mso-style-link:"&Uuml;berschrift 1 Zchn";
mwenzb5dc2f92010-06-16 13:24:52 +000035 margin-top:12.0pt;
36 margin-right:0cm;
37 margin-bottom:3.0pt;
38 margin-left:0cm;
39 page-break-after:avoid;
40 font-size:16.0pt;
41 font-family:"Times New Roman","serif";
42 font-weight:bold;}
43h2
jpaschfa239712010-06-23 12:00:55 +000044 {mso-style-link:"&Uuml;berschrift 2 Zchn";
mwenzb5dc2f92010-06-16 13:24:52 +000045 margin-top:12.0pt;
46 margin-right:0cm;
47 margin-bottom:3.0pt;
48 margin-left:0cm;
49 page-break-after:avoid;
50 font-size:14.0pt;
51 font-family:"Times New Roman","serif";
52 font-weight:bold;
53 font-style:italic;}
54h3
jpaschfa239712010-06-23 12:00:55 +000055 {mso-style-link:"&Uuml;berschrift 3 Zchn";
mwenzb5dc2f92010-06-16 13:24:52 +000056 margin-top:12.0pt;
57 margin-right:0cm;
58 margin-bottom:3.0pt;
59 margin-left:0cm;
60 page-break-after:avoid;
61 font-size:13.0pt;
62 font-family:"Times New Roman","serif";
63 font-weight:bold;}
64h4
jpaschfa239712010-06-23 12:00:55 +000065 {mso-style-link:"&Uuml;berschrift 4 Zchn";
mwenzb5dc2f92010-06-16 13:24:52 +000066 margin-top:11.25pt;
67 margin-right:0cm;
68 margin-bottom:1.7pt;
69 margin-left:0cm;
70 font-size:12.0pt;
71 font-family:"Times New Roman","serif";
72 font-weight:bold;
73 font-style:italic;}
74h5
jpaschfa239712010-06-23 12:00:55 +000075 {mso-style-link:"&Uuml;berschrift 5 Zchn";
mwenzb5dc2f92010-06-16 13:24:52 +000076 margin-right:0cm;
77 margin-left:0cm;
78 font-size:10.0pt;
79 font-family:"Times New Roman","serif";
80 font-weight:bold;}
81h6
jpaschfa239712010-06-23 12:00:55 +000082 {mso-style-link:"&Uuml;berschrift 6 Zchn";
mwenzb5dc2f92010-06-16 13:24:52 +000083 margin-right:0cm;
84 margin-left:0cm;
85 font-size:7.5pt;
86 font-family:"Times New Roman","serif";
87 font-weight:bold;}
88p.MsoCaption, li.MsoCaption, div.MsoCaption
89 {margin-top:6.0pt;
90 margin-right:0cm;
91 margin-bottom:24.0pt;
92 margin-left:0cm;
93 text-align:justify;
94 font-size:10.0pt;
95 font-family:"Times New Roman","serif";
96 font-weight:bold;}
97a:link, span.MsoHyperlink
98 {color:blue;
99 text-decoration:underline;}
100a:visited, span.MsoHyperlinkFollowed
101 {color:purple;
102 text-decoration:underline;}
103p
104 {margin-top:5.65pt;
105 margin-right:0cm;
106 margin-bottom:5.65pt;
107 margin-left:0cm;
108 font-size:12.0pt;
109 font-family:"Times New Roman","serif";}
110pre
111 {mso-style-link:"HTML Vorformatiert Zchn";
112 margin-top:0cm;
113 margin-right:0cm;
114 margin-bottom:0cm;
115 margin-left:3.4pt;
116 margin-bottom:.0001pt;
117 font-size:11.0pt;
118 font-family:"Courier New";}
119p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
120 {mso-style-link:"Sprechblasentext Zchn";
121 margin:0cm;
122 margin-bottom:.0001pt;
123 font-size:8.0pt;
124 font-family:"Tahoma","sans-serif";}
125span.berschrift1Zchn
jpaschfa239712010-06-23 12:00:55 +0000126 {mso-style-name:"&Uuml;berschrift 1 Zchn";
127 mso-style-link:"&Uuml;berschrift 1";
mwenzb5dc2f92010-06-16 13:24:52 +0000128 font-family:"Cambria","serif";
129 color:#365F91;
130 font-weight:bold;}
131span.berschrift2Zchn
jpaschfa239712010-06-23 12:00:55 +0000132 {mso-style-name:"&Uuml;berschrift 2 Zchn";
133 mso-style-link:"&Uuml;berschrift 2";
mwenzb5dc2f92010-06-16 13:24:52 +0000134 font-family:"Cambria","serif";
135 color:#4F81BD;
136 font-weight:bold;}
137span.berschrift3Zchn
jpaschfa239712010-06-23 12:00:55 +0000138 {mso-style-name:"&Uuml;berschrift 3 Zchn";
139 mso-style-link:"&Uuml;berschrift 3";
mwenzb5dc2f92010-06-16 13:24:52 +0000140 font-family:"Cambria","serif";
141 color:#4F81BD;
142 font-weight:bold;}
143span.berschrift4Zchn
jpaschfa239712010-06-23 12:00:55 +0000144 {mso-style-name:"&Uuml;berschrift 4 Zchn";
145 mso-style-link:"&Uuml;berschrift 4";
mwenzb5dc2f92010-06-16 13:24:52 +0000146 font-family:"Cambria","serif";
147 color:#4F81BD;
148 font-weight:bold;
149 font-style:italic;}
150span.berschrift5Zchn
jpaschfa239712010-06-23 12:00:55 +0000151 {mso-style-name:"&Uuml;berschrift 5 Zchn";
152 mso-style-link:"&Uuml;berschrift 5";
mwenzb5dc2f92010-06-16 13:24:52 +0000153 font-family:"Cambria","serif";
154 color:#243F60;}
155span.berschrift6Zchn
jpaschfa239712010-06-23 12:00:55 +0000156 {mso-style-name:"&Uuml;berschrift 6 Zchn";
157 mso-style-link:"&Uuml;berschrift 6";
mwenzb5dc2f92010-06-16 13:24:52 +0000158 font-family:"Cambria","serif";
159 color:#243F60;
160 font-style:italic;}
161span.HTMLVorformatiertZchn
162 {mso-style-name:"HTML Vorformatiert Zchn";
163 mso-style-link:"HTML Vorformatiert";
164 font-family:Consolas;}
165span.SprechblasentextZchn
166 {mso-style-name:"Sprechblasentext Zchn";
167 mso-style-link:Sprechblasentext;
168 font-family:"Tahoma","sans-serif";}
169p.code, li.code, div.code
170 {mso-style-name:code;
171 margin-top:0cm;
172 margin-right:0cm;
173 margin-bottom:0cm;
174 margin-left:15.0pt;
175 margin-bottom:.0001pt;
176 font-size:12.0pt;
177 font-family:"Times New Roman","serif";}
178p.note, li.note, div.note
179 {mso-style-name:note;
180 margin-top:19.5pt;
181 margin-right:0cm;
182 margin-bottom:19.5pt;
183 margin-left:30.0pt;
184 font-size:13.0pt;
185 font-family:"Times New Roman","serif";
186 font-style:italic;}
187p.msochpdefault, li.msochpdefault, div.msochpdefault
188 {mso-style-name:msochpdefault;
189 margin-top:5.65pt;
190 margin-right:0cm;
191 margin-bottom:5.65pt;
192 margin-left:0cm;
193 font-size:10.0pt;
194 font-family:"Times New Roman","serif";}
195span.code1
196 {mso-style-name:code1;
197 font-style:italic;}
198span.code0
199 {mso-style-name:code0;
200 font-style:italic;}
201.MsoChpDefault
202 {font-size:10.0pt;}
203@page Section1
204 {size:595.45pt 841.7pt;
205 margin:72.0pt 89.85pt 72.0pt 89.85pt;}
206div.Section1
207 {page:Section1;}
208-->
209</style>
210</head>
211<body bgcolor="white" lang="DE" link="blue" vlink="purple" style=
212'margin-bottom:12.0pt'>
213<div class="Section1">
214<h1><span lang="EN-US">Selection Behavior</span></h1>
215<p class="MsoNormal"><span lang="EN-US" style=
216'color:black'>&nbsp;</span></p>
217<h2><span lang="EN-US">Introduction</span></h2>
218<p class="MsoNormal"><span lang="EN-US" style=
219'color:black'>&nbsp;</span></p>
220<p class="MsoNormal"><span lang="EN-US" style='color:black'>In
221most cases a graphical figure is depicted by one outer
222&lsquo;main&rsquo; graphics algorithm, inside which several other
223graphics algorithms are located. The outer bounds of this outer
224&lsquo;main&rsquo; graphics algorithm also define the
225selection-behavior of the graphical figure.</span></p>
226<p class="MsoNormal"><span lang="EN-US" style='color:black'>But
227it is also possible to assemble a shape from overlapping or even
228distributed graphics algorithms. In such a case it is not so
229clear anymore, which bounds define the selection-behavior of the
230graphical figure.</span></p>
231<p class="MsoNormal"><span lang="EN-US" style=
232'color:black'>&nbsp;</span></p>
233<p class="MsoNormal"><span lang="EN-US" style='color:black'>For a
234better understanding look at the following figure:</span></p>
235<p class="MsoNormal"><span style='color:black'><img width="111"
236height="71" src="visio/rendering-area-1a.gif" alt=""></span></p>
237<p class="MsoCaption"><span class="code1"><span lang="EN-US"
238style='font-style:normal'>Figure: Graphical figure with
239distributed graphics algorithms (ellipse and
240text)</span></span></p>
241<p class="MsoNormal"><span lang="EN-US" style='color:black'>This
242graphical figure consists of an ellipse and a text. For technical
243reasons there is still an outer invisible rectangle, which
244contains the ellipse and text. But in this example it would seem
245strange for the user, if this outer invisible rectangle would
246define the selection-behavior, meaning that clicking on the
247invisible rectangle would select it and show the
248selection-handles along the bounds of the invisible
249rectangle.</span></p>
250<p class="MsoNormal"><span lang="EN-US" style=
251'color:black'>Instead the selection-behavior should work as can
252be seen in the following figure:</span></p>
253<p class="MsoNormal"><span style='color:black'><img width="111"
254height="72" src="visio/rendering-area-1b.gif" alt=""></span></p>
255<p class="MsoCaption"><span class="code1"><span lang="EN-US"
256style='font-style:normal'>Figure: Selection area is smaller than
257complete graphical figure</span></span></p>
258<p class="MsoNormal"><span lang="EN-US" style='color:black'>The
259selection-handles appear only along the borders of the ellipse
260and not along the borders of the larger invisible rectangle. It
261is possible to move or resize the circle along these
262selection-handles (which will implicitly move or resize the
263complete graphical figure).&nbsp; This makes the ellipse the
264&lsquo;main&rsquo; graphics algorithm, although the ellipse is
265technically not the outer graphics algorithm of the graphical
266figure.</span></p>
267<p class="MsoNormal"><span lang="EN-US" style=
268'color:black'>Another aspect of the selection-behavior is that
269the graphical figure shall be selected when the mouse clicks on
270either the ellipse or the text. When the mouse clicks the text
271however, then the handle-bounds still appear around the ellipse
272as described above, and not around the text. This means, that the
273selection-handles can be shown around a different area, than the
274area which reacts on the mouse clicks to select the graphical
275figure.</span></p>
276<p class="MsoNormal"><span lang="EN-US" style=
277'color:black'>&nbsp;</span></p>
278<p class="MsoNormal"><span lang="EN-US" style=
279'color:black'>&nbsp;</span></p>
280<h2><span lang="EN-US">Creating an Extended Rendering
281Area</span></h2>
282<p class="MsoNormal"><span lang="EN-US" style=
283'color:black'>&nbsp;</span></p>
284<p class="MsoNormal"><span lang="EN-US" style='color:black'>The
285following example bases on the <a href="anchors.htm">box relative
286anchor</a> we created previously. As you can see the box relative
287anchor was located completely inside the bounds of the rectangle
288depicting the EClass.</span></p>
289<p class="MsoNormal"><span lang="EN-US" style='color:black'>Now
290we want to change the location of the box relative anchor, so
291that it exceeds the bounds of the rectangle. This is actually
292quite typical, that box relative anchors or fix point anchors
293exceed the bounds of the graphical figure it belongs
294to.</span></p>
295<p class="MsoNormal"><span style='color:black'><img border="0"
296width="121" height="71" src="visio/rendering-area-2a.gif" alt=
297""></span></p>
298<p class="MsoCaption"><span class="code1"><span lang="EN-US"
299style='font-style:normal'>Figure: Box relative anchor exceeds
300bounds of graphical figure</span></span></p>
301<p class="MsoNormal"><span lang="EN-US" style='color:black'>As
302already mentioned, for technical reasons a graphics algorithm can
303never be painted outside the bounds of its parent graphics
304algorithm. Although it is possible to set the bounds of a
305graphics algorithm to exceed the bounds of its parent graphics
306algorithm, it will just be clipped when painting.</span></p>
307<p class="MsoNormal"><span lang="EN-US" style='color:black'>You
308can try that out by changing the bounds of the <a href=
309"anchors.htm">box relative anchor</a> we created
310previously:</span></p>
311<p class="MsoNormal"><span lang="EN-US" style=
312'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.<i>setLocationAndSizeOfGraphicsAlgorithm</i>(boxRect,
313-8, -4,</span> <b>16</b><span style='color:black'>,
3148);</span></span></p>
315<p class="MsoNormal"><span lang="EN-US" style=
316'color:black'>&nbsp;</span></p>
317<p class="MsoNormal"><span lang="EN-US" style='color:black'>As
318this doesn&rsquo;t work, we have to change the structure of the
319graphics algorithms for the EClass. The outer graphics algorithm
320shall be an invisible rectangle, which contains the rectangle
321depicting the EClass. The size of the invisible rectangle equals
322the size of the rectangle depicting the EClass, plus the space
323needed for the box relative anchor at its right side. You can see
324the bounds of the invisible rectangle when you select the
325graphical figure:</span></p>
326<p class="MsoNormal"><span style='color:black'><img border="0"
327width="131" height="71" src="visio/rendering-area-2b.gif" alt=
328""></span><span lang="EN-US" style=
329'color:black'>&nbsp;</span></p>
330<p class="MsoCaption"><span class="code1"><span lang="EN-US"
331style='font-style:normal'>Figure: Selection-handles around the
332invisible rectangle</span></span><span lang=
333"EN-US">&nbsp;</span></p>
334<p class="MsoNormal"><span lang="EN-US" style='color:black'>The
335invisible rectangle has to be created in the add method of the
336<a href="add-feature.htm">add feature</a><span class=
337"code1"><span style='font-style:normal'>, as explained in the
338following code snippet. Additionally the bounds of the box
339relative anchor have to be set differently. Note, that the
340expanded width of the invisible rectangle is set in a static
341field, because it also has to be used in calculations outside
342this class.</span></span></span></p>
343<p class="MsoNormal"><span lang="EN-US">&nbsp;</span></p>
344<table class="MsoNormalTable" border="0" cellspacing="0"
345cellpadding="0" width="851" style=
346'width:18.0cm;border-collapse:collapse'>
347<tr>
348<td width="851" valign="top" style=
349'width:18.0cm;border:solid windowtext 1.0pt; padding:0cm 5.4pt 0cm 5.4pt'>
350<p class="MsoNormal" style='text-autospace:none'><span lang=
351"EN-US" style=
352'font-size:10.0pt;font-family:"Courier New";color:#3F7F5F'>&nbsp;</span></p>
353<p class="MsoNormal" style='text-autospace:none'><span lang=
354"EN-US" style=
355'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
356<span lang="EN-US" style=
357'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
358the additional size of the invisible rectangle at the right
359border</span></p>
360<p class="MsoNormal" style='text-autospace:none'><span lang=
361"EN-US" style=
362'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
363<span lang="EN-US" style=
364'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
365(this also equals the half width of the anchor to paint
366there)</span></p>
367<p class="MsoNormal" style='text-autospace:none'><span lang=
368"EN-US" style=
369'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
370<b><span lang="EN-US" style=
371'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>public</span></b>
372<b><span lang="EN-US" style=
373'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>static</span></b>
374<b><span lang="EN-US" style=
375'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>final</span></b>
376<b><span lang="EN-US" style=
377'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>int</span></b>
378<i><span lang="EN-US" style=
379'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>INVISIBLE_RECT_RIGHT</span></i>
380<span lang="EN-US" style=
381'font-size:10.0pt;font-family:"Courier New";color:black'>=
3826;</span></p>
383<p class="MsoNormal" style='text-autospace:none'><span lang=
384"EN-US" style=
385'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
386<p class="MsoNormal" style='text-autospace:none'><span lang=
387"EN-US" style=
388'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
389<p class="MsoNormal" style='text-autospace:none'><span lang=
390"EN-US" style=
391'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
392<b><span lang="EN-US" style=
393'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>public</span></b>
394<span lang="EN-US" style=
395'font-size:10.0pt; font-family:"Courier New";color:black'>PictogramElement
396add(IAddContext context) {</span></p>
397<p class="MsoNormal" style='text-autospace:none'><span lang=
398"EN-US" style=
399'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
400EClass addedClass = (EClass) context.getNewObject();</span></p>
401<p class="MsoNormal" style='text-autospace:none'><span lang=
402"EN-US" style=
403'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
404Diagram targetDiagram = (Diagram)
405context.getTargetContainer();</span></p>
406<p class="MsoNormal" style='text-autospace:none'><span lang=
407"EN-US" style=
408'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
409<p class="MsoNormal" style='text-autospace:none'><span lang=
410"EN-US" style=
411'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
412<span lang="EN-US" style=
413'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
414CONTAINER SHAPE WITH ROUNDED RECTANGLE</span></p>
415<p class="MsoNormal" style='text-autospace:none'><span lang=
416"EN-US" style=
417'font-size:10.0pt;font-family:"Courier New";color:#3F7F5F'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
418<span lang="EN-US" style=
419'font-size:10.0pt;font-family:"Courier New"'>IPeCreateService
420peCreateService = Graphiti.getPeCreateService();</span></p>
421<p class="MsoNormal" style='text-autospace:none'><span lang=
422"EN-US" style=
423'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
424ContainerShape containerShape =</span></p>
425<p class="MsoNormal" style='text-autospace:none'><span lang=
426"EN-US" style=
427'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
428<span lang="EN-US" style=
429'font-size:10.0pt;font-family:"Courier New"'>peCreateService<span style='color:black'>.createContainerShape(targetDiagram,</span>
430<b><span style='color:#7F0055'>true</span></b><span style=
431'color:black'>);</span></span></p>
432<p class="MsoNormal" style='text-autospace:none'><span lang=
433"EN-US" style=
434'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
435<p class="MsoNormal" style='text-autospace:none'><span lang=
436"EN-US" style=
437'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
438<span lang="EN-US" style=
439'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
440check whether the context has a size (e.g. from a create
441feature)</span></p>
442<p class="MsoNormal" style='text-autospace:none'><span lang=
443"EN-US" style=
444'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
445<span lang="EN-US" style=
446'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
447otherwise define a default size for the shape</span></p>
448<p class="MsoNormal" style='text-autospace:none'><span lang=
449"EN-US" style=
450'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
451<b><span lang="EN-US" style=
452'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>int</span></b>
453<span lang="EN-US" style=
454'font-size:10.0pt; font-family:"Courier New";color:black'>width =
455context.getWidth() &lt;= 0 ? 100 : context.getWidth();</span></p>
456<p class="MsoNormal" style='text-autospace:none'><span lang=
457"EN-US" style=
458'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
459<b><span lang="EN-US" style=
460'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>int</span></b>
461<span lang="EN-US" style=
462'font-size:10.0pt; font-family:"Courier New";color:black'>height
463= context.getHeight() &lt;= 0 ? 50 :
464context.getHeight();</span></p>
465<p class="MsoNormal" style='text-autospace:none'><span lang=
466"EN-US" style=
467'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
468<p class="MsoNormal" style='text-autospace:none'><span lang=
469"EN-US" style=
470'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
471RoundedRectangle roundedRectangle;</span> <span lang="EN-US"
472style=
473'font-size: 10.0pt;font-family:"Courier New";color:#3F7F5F'>//
474need to access it later</span></p>
475<p class="MsoNormal" style='text-autospace:none'><span lang=
476"EN-US" style=
477'font-size:10.0pt;font-family:"Courier New";color:#3F7F5F'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
478<span lang="EN-US" style=
479'font-size:10.0pt;font-family:"Courier New"'>&nbsp;IGaService
480gaService = Graphiti.getGaService();</span></p>
481<p class="MsoNormal" style='text-autospace:none'><span lang=
482"EN-US" style=
483'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
484{</span></p>
485<p class="MsoNormal" style='text-autospace:none'><span lang=
486"EN-US" style=
487'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
488<span lang="EN-US" style=
489'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
490create invisible outer rectangle expanded by</span></p>
491<p class="MsoNormal" style='text-autospace:none'><span lang=
492"EN-US" style=
493'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
494<span lang="EN-US" style=
495'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
496the width needed for the anchor</span></p>
497<p class="MsoNormal" style='text-autospace:none'><span lang=
498"EN-US" style=
499'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
500Rectangle invisibleRectangle =</span></p>
501<p class="MsoNormal" style='text-autospace:none'><span lang=
502"EN-US" style=
503'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
504<span lang="EN-US" style=
505'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.createInvisibleRectangle(containerShape);</span></span></p>
506<p class="MsoNormal" style='text-autospace:none'><span lang=
507"EN-US" style=
508'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;
509&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span lang="EN-US"
510style=
511'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.setLocationAndSizeOfGraphicsAlgorithm(invisibleRectangle,</span></span></p>
512<p class="MsoNormal" style='text-autospace:none'><span lang=
513"EN-US" style=
514'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
515context.getX(), context.getY(), width +</span> <i><span lang=
516"EN-US" style=
517'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>INVISIBLE_RECT_RIGHT</span></i><span lang="EN-US"
518style=
519'font-size:10.0pt;font-family:"Courier New";color:black'>,</span></p>
520<p class="MsoNormal" style='text-autospace:none'><span lang=
521"EN-US" style=
522'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
523height);</span></p>
524<p class="MsoNormal" style='text-autospace:none'><span lang=
525"EN-US" style=
526'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
527<p class="MsoNormal" style='text-autospace:none'><span lang=
528"EN-US" style=
529'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
530<span lang="EN-US" style=
531'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
532create and set visible rectangle inside invisible
533rectangle</span></p>
534<p class="MsoNormal" style='text-autospace:none'><span lang=
535"EN-US" style=
536'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;
537&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;roundedRectangle
538=</span></p>
539<p class="MsoNormal" style='text-autospace:none'><span lang=
540"EN-US" style=
541'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
542<span lang="EN-US" style=
543'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.createRoundedRectangle(invisibleRectangle,
5445, 5);</span></span></p>
545<p class="MsoNormal" style='text-autospace:none'><span lang=
546"EN-US" style=
547'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
548roundedRectangle.setForeground(manageColor(</span><i><span lang=
549"EN-US" style=
550'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>CLASS_FOREGROUND</span></i><span lang="EN-US"
551style=
552'font-size:10.0pt;font-family:"Courier New";color:black'>));</span></p>
553<p class="MsoNormal" style='text-autospace:none'><span lang=
554"EN-US" style=
555'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
556roundedRectangle.setBackground(manageColor(</span><i><span lang=
557"EN-US" style=
558'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>CLASS_BACKGROUND</span></i><span lang="EN-US"
559style=
560'font-size:10.0pt;font-family:"Courier New";color:black'>));</span></p>
561<p class="MsoNormal" style='text-autospace:none'><span lang=
562"EN-US" style=
563'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
564&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;roundedRectangle.setLineWidth(2);</span></p>
565<p class="MsoNormal" style='text-autospace:none'><span lang=
566"EN-US" style=
567'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
568<span lang="EN-US" style=
569'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.setLocationAndSizeOfGraphicsAlgorithm(roundedRectangle,
5700,</span></span></p>
571<p class="MsoNormal" style='text-autospace:none'><span lang=
572"EN-US" style=
573'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
5740, width, height);</span></p>
575<p class="MsoNormal" style='text-autospace:none'><span lang=
576"EN-US" style=
577'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
578<p class="MsoNormal" style='text-autospace:none'><span lang=
579"EN-US" style=
580'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
581<span lang="EN-US" style=
582'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
583create link and wire it</span></p>
584<p class="MsoNormal" style='text-autospace:none'><span lang=
585"EN-US" style=
586'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
587link(containerShape, addedClass);</span></p>
588<p class="MsoNormal" style='text-autospace:none'><span lang=
589"EN-US" style=
590'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
591}</span></p>
592<p class="MsoNormal" style='text-autospace:none'><span lang=
593"EN-US" style=
594'font-size:10.0pt;font-family:"Courier New";color:#3F7F5F'>&nbsp;</span></p>
595<p class="MsoNormal" style='text-autospace:none'><span lang=
596"EN-US" style=
597'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
598<p class="MsoNormal" style='text-autospace:none'><span lang=
599"EN-US" style=
600'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
601<span lang="EN-US" style=
602'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
603... EXISTING CODING ...</span></p>
604<p class="MsoNormal" style='text-autospace:none'><span lang=
605"EN-US" style=
606'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
607<p class="MsoNormal" style='text-autospace:none'><span lang=
608"EN-US" style=
609'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
610<p class="MsoNormal" style='text-autospace:none'><span lang=
611"EN-US" style=
612'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
613<span lang="EN-US" style=
614'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
615add a chopbox anchor to the shape</span></p>
616<p class="MsoNormal" style='text-autospace:none'><span lang=
617"EN-US" style=
618'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
619<span lang="EN-US" style=
620'font-size:10.0pt;font-family:"Courier New"'>peCreateService<span style='color:black'>.createChopboxAnchor(containerShape);</span></span></p>
621<p class="MsoNormal" style='text-autospace:none'><span lang=
622"EN-US" style=
623'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
624<p class="MsoNormal" style='text-autospace:none'><span lang=
625"EN-US" style=
626'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
627<span lang="EN-US" style=
628'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
629create an additional box relative anchor at
630middle-right</span></p>
631<p class="MsoNormal" style='text-autospace:none'><span lang=
632"EN-US" style=
633'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
634BoxRelativeAnchor boxAnchor =</span></p>
635<p class="MsoNormal" style='text-autospace:none'><span lang=
636"EN-US" style=
637'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
638<span lang="EN-US" style=
639'font-size:10.0pt;font-family:"Courier New"'>peCreateService<span style='color:black'>.createBoxRelativeAnchor(containerShape);</span></span></p>
640<p class="MsoNormal" style='text-autospace:none'><span lang=
641"EN-US" style=
642'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
643boxAnchor.setRelativeWidth(1.0);</span></p>
644<p class="MsoNormal" style='text-autospace:none'><span lang=
645"EN-US" style=
646'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
647boxAnchor.setRelativeHeight(0.5);</span></p>
648<p class="MsoNormal" style='text-autospace:none'><span lang=
649"EN-US" style=
650'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
651<span lang="EN-US" style=
652'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
653anchor references visible rectangle instead of invisible
654rectangle</span></p>
655<p class="MsoNormal" style='text-autospace:none'><span lang=
656"EN-US" style=
657'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
658boxAnchor.setReferencedGraphicsAlgorithm(roundedRectangle);</span></p>
659<p class="MsoNormal" style='text-autospace:none'><span lang=
660"EN-US" style=
661'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
662<span lang="EN-US" style=
663'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
664assign a graphics algorithm for the box relative
665anchor</span></p>
666<p class="MsoNormal" style='text-autospace:none'><span lang=
667"EN-US" style=
668'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
669Rectangle boxRect =</span> <span lang="EN-US" style=
670'font-size:10.0pt; font-family:"Courier New"'>gaService<span style='color:black'>.createRectangle(boxAnchor);</span></span></p>
671<p class="MsoNormal" style='text-autospace:none'><span lang=
672"EN-US" style=
673'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
674<span lang="EN-US" style=
675'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
676anchor is located on the right border of the visible
677rectangle</span></p>
678<p class="MsoNormal" style='text-autospace:none'><span lang=
679"EN-US" style=
680'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
681<span lang="EN-US" style=
682'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
683and touches the border of the invisible rectangle</span></p>
684<p class="MsoNormal" style='text-autospace:none'><span lang=
685"EN-US" style=
686'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
687<b><span lang="EN-US" style=
688'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>int</span></b>
689<span lang="EN-US" style=
690'font-size:10.0pt; font-family:"Courier New";color:black'>w
691=</span> <i><span lang="EN-US" style=
692'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>INVISIBLE_RECT_RIGHT</span></i><span lang="EN-US"
693style=
694'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
695<p class="MsoNormal" style='text-autospace:none'><span lang=
696"EN-US" style=
697'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
698<span lang="EN-US" style=
699'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.setLocationAndSizeOfGraphicsAlgorithm(boxRect,
700-w, -w, 2 * w,</span></span></p>
701<p class="MsoNormal" style='text-autospace:none'><span lang=
702"EN-US" style=
703'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
7042 * w);</span></p>
705<p class="MsoNormal" style='text-autospace:none'><span lang=
706"EN-US" style=
707'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
708Color c =</span> <span lang="EN-US" style=
709'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.manageColor(getDiagram(),
710IColorConstant.</span><i><span style=
711'color:#0000C0'>DARK_BLUE</span></i><span style=
712'color:black'>);</span></span></p>
713<p class="MsoNormal" style='text-autospace:none'><span lang=
714"EN-US" style=
715'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
716boxRect.setBackground(c);</span></p>
717<p class="MsoNormal" style='text-autospace:none'><span lang=
718"EN-US" style=
719'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
720<p class="MsoNormal" style='text-autospace:none'><span lang=
721"EN-US" style=
722'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
723<span lang="EN-US" style=
724'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
725call the layout feature</span></p>
726<p class="MsoNormal" style='text-autospace:none'><span lang=
727"EN-US" style=
728'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
729<span style=
730'font-size:10.0pt;font-family:"Courier New";color:black'>layoutPictogramElement(containerShape);</span></p>
731<p class="MsoNormal" style='text-autospace:none'><span style=
732'font-size:10.0pt; font-family:"Courier New"'>&nbsp;</span></p>
733<p class="MsoNormal" style='text-autospace:none'><span style=
734'font-size:10.0pt; font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
735<b><span style=
736'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>return</span></b>
737<span style=
738'font-size:10.0pt;font-family:"Courier New";color:black'>containerShape;</span></p>
739<p class="MsoNormal" style='text-autospace:none'><span style=
740'font-size:10.0pt; font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;
741}</span></p>
742<p class="MsoNormal" style='text-autospace:none'><span lang=
743"EN-US" style=
744'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;</span></p>
745</td>
746</tr>
747</table>
748<p class="MsoNormal"><span lang="EN-US" style=
749'color:black'>&nbsp;</span></p>
750<p class="MsoNormal"><span lang="EN-US" style=
751'color:black'>&nbsp;</span></p>
752<p class="MsoNormal"><span lang="EN-US" style='color:black'>Next
753we have to change the layout method of the <a href=
754"layout-feature.htm">layout feature</a><span class=
755"code1"><span style='font-style:normal'>. Previously it adjusted
756the size of the inner graphics algorithms (line and text) in
757relation to the container graphics algorithm (visible rectangle).
758Now it has to adjust the size of the inner graphics algorithms
759(visible rectangle, line and text) in relation to the container
760graphics algorithm (invisible
761rectangle).</span></span></span></p>
762<p class="MsoNormal"><span class="code1"><span lang="EN-US"
763style='color:black; font-style:normal'>The implementation can be
764seen in the following code-snippet:</span></span></p>
765<p class="MsoNormal"><span lang="EN-US" style=
766'color:black'>&nbsp;</span></p>
767<table class="MsoNormalTable" border="0" cellspacing="0"
768cellpadding="0" width="851" style=
769'width:18.0cm;border-collapse:collapse'>
770<tr>
771<td width="851" valign="top" style=
772'width:18.0cm;border:solid windowtext 1.0pt; padding:0cm 5.4pt 0cm 5.4pt'>
773<p class="MsoNormal" style='text-autospace:none'><span lang=
774"EN-US" style='color:black'>&nbsp;</span></p>
775<p class="MsoNormal" style='text-autospace:none'><span lang=
776"EN-US" style=
777'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
778<b><span lang="EN-US" style=
779'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>public</span></b>
780<b><span lang="EN-US" style=
781'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>boolean</span></b>
782<span lang="EN-US" style=
783'font-size:10.0pt;font-family:"Courier New";color:black'>layout(ILayoutContext
784context) {</span></p>
785<p class="MsoNormal" style='text-autospace:none'><span lang=
786"EN-US" style=
787'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
788<b><span lang="EN-US" style=
789'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>boolean</span></b>
790<span lang="EN-US" style=
791'font-size:10.0pt; font-family:"Courier New";color:black'>anythingChanged
792=</span> <b><span lang="EN-US" style=
793'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>false</span></b><span lang="EN-US"
794style=
795'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
796<p class="MsoNormal" style='text-autospace:none'><span lang=
797"EN-US" style=
798'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
799ContainerShape containerShape =</span></p>
800<p class="MsoNormal" style='text-autospace:none'><span lang=
801"EN-US" style=
802'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
803(ContainerShape) context.getPictogramElement();</span></p>
804<p class="MsoNormal" style='text-autospace:none'><span lang=
805"EN-US" style=
806'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
807GraphicsAlgorithm containerGa =
808containerShape.getGraphicsAlgorithm();</span></p>
809<p class="MsoNormal" style='text-autospace:none'><span lang=
810"EN-US" style=
811'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
812<span lang="EN-US" style=
813'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
814the containerGa is the invisible rectangle</span></p>
815<p class="MsoNormal" style='text-autospace:none'><span lang=
816"EN-US" style=
817'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
818<span lang="EN-US" style=
819'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
820containing the visible rectangle as its (first and only)
821child</span></p>
822<p class="MsoNormal" style='text-autospace:none'><span lang=
823"EN-US" style=
824'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
825GraphicsAlgorithm rectangle =</span></p>
826<p class="MsoNormal" style='text-autospace:none'><span lang=
827"EN-US" style=
828'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
829containerGa.getGraphicsAlgorithmChildren().get(0);</span></p>
830<p class="MsoNormal" style='text-autospace:none'><span lang=
831"EN-US" style=
832'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
833<p class="MsoNormal" style='text-autospace:none'><span lang=
834"EN-US" style=
835'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
836<span lang="EN-US" style=
837'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
838height of invisible rectangle</span></p>
839<p class="MsoNormal" style='text-autospace:none'><span lang=
840"EN-US" style=
841'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
842<b><span lang="EN-US" style=
843'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
844<span lang="EN-US" style=
845'font-size:10.0pt; font-family:"Courier New";color:black'>(containerGa.getHeight()
846&lt;</span> <i><span lang="EN-US" style=
847'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>MIN_HEIGHT</span></i><span lang="EN-US"
848style='font-size:10.0pt;font-family:"Courier New";color:black'>)
849{</span></p>
850<p class="MsoNormal" style='text-autospace:none'><span lang=
851"EN-US" style=
852'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
853containerGa.setHeight(</span><i><span lang="EN-US" style=
854'font-size:10.0pt; font-family:"Courier New";color:#0000C0'>MIN_HEIGHT</span></i><span lang="EN-US"
855style=
856'font-size:10.0pt;font-family:"Courier New";color:black'>);</span></p>
857<p class="MsoNormal" style='text-autospace:none'><span lang=
858"EN-US" style=
859'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
860anythingChanged =</span> <b><span lang="EN-US" style=
861'font-size:10.0pt; font-family:"Courier New";color:#7F0055'>true</span></b><span lang="EN-US"
862style=
863'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
864<p class="MsoNormal" style='text-autospace:none'><span lang=
865"EN-US" style=
866'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
867}</span></p>
868<p class="MsoNormal" style='text-autospace:none'><span lang=
869"EN-US" style=
870'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
871<p class="MsoNormal" style='text-autospace:none'><span lang=
872"EN-US" style=
873'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
874<span lang="EN-US" style=
875'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
876height of visible rectangle (same as invisible
877rectangle)</span></p>
878<p class="MsoNormal" style='text-autospace:none'><span lang=
879"EN-US" style=
880'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
881<b><span lang="EN-US" style=
882'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
883<span lang="EN-US" style=
884'font-size:10.0pt; font-family:"Courier New";color:black'>(rectangle.getHeight()
885!= containerGa.getHeight()) {</span></p>
886<p class="MsoNormal" style='text-autospace:none'><span lang=
887"EN-US" style=
888'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
889rectangle.setHeight(containerGa.getHeight());</span></p>
890<p class="MsoNormal" style='text-autospace:none'><span lang=
891"EN-US" style=
892'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
893anythingChanged =</span> <b><span lang="EN-US" style=
894'font-size:10.0pt; font-family:"Courier New";color:#7F0055'>true</span></b><span lang="EN-US"
895style=
896'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
897<p class="MsoNormal" style='text-autospace:none'><span lang=
898"EN-US" style=
899'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
900}</span></p>
901<p class="MsoNormal" style='text-autospace:none'><span lang=
902"EN-US" style=
903'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
904<p class="MsoNormal" style='text-autospace:none'><span lang=
905"EN-US" style=
906'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
907<span lang="EN-US" style=
908'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
909width of invisible rectangle</span></p>
910<p class="MsoNormal" style='text-autospace:none'><span lang=
911"EN-US" style=
912'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
913<b><span lang="EN-US" style=
914'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
915<span lang="EN-US" style=
916'font-size:10.0pt; font-family:"Courier New";color:black'>(containerGa.getWidth()
917&lt;</span> <i><span lang="EN-US" style=
918'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>MIN_WIDTH</span></i><span lang="EN-US"
919style='font-size:10.0pt;font-family:"Courier New";color:black'>)
920{</span></p>
921<p class="MsoNormal" style='text-autospace:none'><span lang=
922"EN-US" style=
923'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;
924&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;containerGa.setWidth(</span><i><span lang="EN-US"
925style=
926'font-size:10.0pt;font-family:"Courier New";color:#0000C0'>MIN_WIDTH</span></i><span lang="EN-US"
927style=
928'font-size:10.0pt;font-family:"Courier New";color:black'>);</span></p>
929<p class="MsoNormal" style='text-autospace:none'><span lang=
930"EN-US" style=
931'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
932anythingChanged =</span> <b><span lang="EN-US" style=
933'font-size:10.0pt; font-family:"Courier New";color:#7F0055'>true</span></b><span lang="EN-US"
934style=
935'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
936<p class="MsoNormal" style='text-autospace:none'><span lang=
937"EN-US" style=
938'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
939}</span></p>
940<p class="MsoNormal" style='text-autospace:none'><span lang=
941"EN-US" style=
942'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
943<p class="MsoNormal" style='text-autospace:none'><span lang=
944"EN-US" style=
945'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
946<span lang="EN-US" style=
947'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
948width of visible rectangle (smaller than invisible
949rectangle)</span></p>
950<p class="MsoNormal" style='text-autospace:none'><span lang=
951"EN-US" style=
952'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
953<b><span lang="EN-US" style=
954'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>int</span></b>
955<span lang="EN-US" style=
956'font-size:10.0pt; font-family:"Courier New";color:black'>rectangleWidth
957=</span></p>
958<p class="MsoNormal" style='text-autospace:none'><span lang=
959"EN-US" style=
960'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
961containerGa.getWidth()</span></p>
962<p class="MsoNormal" style='text-autospace:none'><span lang=
963"EN-US" style=
964'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
jpaschfa239712010-06-23 12:00:55 +0000965- TutorialEAddClassFeature.</span><i><span lang="EN-US" style=
mwenzb5dc2f92010-06-16 13:24:52 +0000966'font-size:10.0pt; font-family:"Courier New";color:#0000C0'>INVISIBLE_RECT_RIGHT</span></i><span lang="EN-US"
967style=
968'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
969<p class="MsoNormal" style='text-autospace:none'><span lang=
970"EN-US" style=
971'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
972<b><span lang="EN-US" style=
973'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
974<span lang="EN-US" style=
975'font-size:10.0pt; font-family:"Courier New";color:black'>(rectangle.getWidth()
976!= rectangleWidth) {</span></p>
977<p class="MsoNormal" style='text-autospace:none'><span lang=
978"EN-US" style=
979'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
980rectangle.setWidth(rectangleWidth);</span></p>
981<p class="MsoNormal" style='text-autospace:none'><span lang=
982"EN-US" style=
983'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
984anythingChanged =</span> <b><span lang="EN-US" style=
985'font-size:10.0pt; font-family:"Courier New";color:#7F0055'>true</span></b><span lang="EN-US"
986style=
987'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
988<p class="MsoNormal" style='text-autospace:none'><span lang=
989"EN-US" style=
990'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
991}</span></p>
992<p class="MsoNormal" style='text-autospace:none'><span lang=
993"EN-US" style=
994'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
995<p class="MsoNormal" style='text-autospace:none'><span lang=
996"EN-US" style=
997'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
998<span lang="EN-US" style=
999'font-size:10.0pt;font-family:"Courier New"; color:#3F7F5F'>//
1000width of text and line (same as visible rectangle)</span></p>
1001<p class="MsoNormal" style='text-autospace:none'><span lang=
1002"EN-US" style=
1003'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1004Iterator iter =
1005containerShape.getChildren().iterator();</span></p>
1006<p class="MsoNormal" style='text-autospace:none'><span lang=
1007"EN-US" style=
1008'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1009<b><span lang="EN-US" style=
1010'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>while</span></b>
1011<span lang="EN-US" style=
1012'font-size:10.0pt; font-family:"Courier New";color:black'>(iter.hasNext())
1013{</span></p>
1014<p class="MsoNormal" style='text-autospace:none'><span lang=
1015"EN-US" style=
1016'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1017Shape shape = (Shape) iter.next();</span></p>
1018<p class="MsoNormal" style='text-autospace:none'><span lang=
1019"EN-US" style=
1020'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1021GraphicsAlgorithm graphicsAlgorithm =
1022shape.getGraphicsAlgorithm();</span></p>
1023<p class="MsoNormal" style='text-autospace:none'><span lang=
1024"EN-US" style=
1025'font-size:10.0pt;font-family:"Courier New"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1026IGaService gaService = Graphiti.getGaService();</span></p>
1027<p class="MsoNormal" style='text-autospace:none'><span lang=
1028"EN-US" style=
1029'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1030IDimension size =</span></p>
1031<p class="MsoNormal" style='text-autospace:none'><span lang=
1032"EN-US" style=
1033'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1034<span lang="EN-US" style=
1035'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.<i>calculateSizeOfGraphicsAlgorithm</i>(graphicsAlgorithm);</span></span></p>
1036<p class="MsoNormal" style='text-autospace:none'><span lang=
1037"EN-US" style=
1038'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1039<b><span lang="EN-US" style=
1040'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
1041<span lang="EN-US" style=
1042'font-size:10.0pt; font-family:"Courier New";color:black'>(rectangleWidth
1043!= size.getWidth()) {</span></p>
1044<p class="MsoNormal" style='text-autospace:none'><span lang=
1045"EN-US" style=
1046'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1047<b><span lang="EN-US" style=
1048'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
1049<span lang="EN-US" style=
1050'font-size:10.0pt; font-family:"Courier New";color:black'>(graphicsAlgorithm</span>
1051<b><span lang="EN-US" style=
1052'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>instanceof</span></b>
1053<span lang="EN-US" style=
1054'font-size:10.0pt;font-family:"Courier New";color:black'>Polyline)
1055{</span></p>
1056<p class="MsoNormal" style='text-autospace:none'><span lang=
1057"EN-US" style=
1058'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1059Polyline polyline = (Polyline) graphicsAlgorithm;</span></p>
1060<p class="MsoNormal" style='text-autospace:none'><span lang=
1061"EN-US" style=
1062'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1063Point secondPoint = polyline.getPoints().get(1);</span></p>
1064<p class="MsoNormal" style='text-autospace:none'><span lang=
1065"EN-US" style=
1066'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1067Point newSecondPoint =</span></p>
1068<p class="MsoNormal" style='text-autospace:none'><span lang=
1069"EN-US" style=
1070'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1071<span lang="EN-US" style=
jpaschfa239712010-06-23 12:00:55 +00001072'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.<i>createPoint</i>(rectangleWidth,</span></span></p>
mwenzb5dc2f92010-06-16 13:24:52 +00001073<p class="MsoNormal" style='text-autospace:none'><span lang=
1074"EN-US" style=
1075'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1076secondPoint.getY());</span></p>
1077<p class="MsoNormal" style='text-autospace:none'><span lang=
1078"EN-US" style=
1079'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1080polyline.getPoints().set(1, newSecondPoint);</span></p>
1081<p class="MsoNormal" style='text-autospace:none'><span lang=
1082"EN-US" style=
1083'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1084anythingChanged =</span> <b><span lang="EN-US" style=
1085'font-size:10.0pt; font-family:"Courier New";color:#7F0055'>true</span></b><span lang="EN-US"
1086style=
1087'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
1088<p class="MsoNormal" style='text-autospace:none'><span lang=
1089"EN-US" style=
1090'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1091}</span> <b><span lang="EN-US" style=
1092'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>else</span></b>
1093<span lang="EN-US" style=
1094'font-size:10.0pt; font-family:"Courier New";color:black'>{</span></p>
1095<p class="MsoNormal" style='text-autospace:none'><span lang=
1096"EN-US" style=
1097'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1098<span lang="EN-US" style=
1099'font-size:10.0pt;font-family:"Courier New"'>gaService<span style='color:black'>.<i>setWidthOfGraphicsAlgorithm</i>(graphicsAlgorithm,</span></span></p>
1100<p class="MsoNormal" style='text-autospace:none'><span lang=
1101"EN-US" style=
1102'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1103rectangleWidth);</span></p>
1104<p class="MsoNormal" style='text-autospace:none'><span lang=
1105"EN-US" style=
1106'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1107anythingChanged =</span> <b><span lang="EN-US" style=
1108'font-size:10.0pt; font-family:"Courier New";color:#7F0055'>true</span></b><span lang="EN-US"
1109style=
1110'font-size:10.0pt;font-family:"Courier New";color:black'>;</span></p>
1111<p class="MsoNormal" style='text-autospace:none'><span lang=
1112"EN-US" style=
1113'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1114}</span></p>
1115<p class="MsoNormal" style='text-autospace:none'><span lang=
1116"EN-US" style=
1117'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1118}</span></p>
1119<p class="MsoNormal" style='text-autospace:none'><span lang=
1120"EN-US" style=
1121'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1122}</span></p>
1123<p class="MsoNormal" style='text-autospace:none'><span lang=
1124"EN-US" style=
1125'font-size:10.0pt;font-family:"Courier New"'>&nbsp;</span></p>
1126<p class="MsoNormal" style='text-autospace:none'><span lang=
1127"EN-US" style=
1128'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1129<b><span lang="EN-US" style=
1130'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>return</span></b>
1131<span lang="EN-US" style=
1132'font-size:10.0pt; font-family:"Courier New";color:black'>anythingChanged;</span></p>
1133<p class="MsoNormal" style='text-autospace:none'><span lang=
1134"EN-US" style=
1135'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
1136<span style=
1137'font-size:10.0pt;font-family:"Courier New";color:black'>}</span></p>
1138<p class="MsoNormal" style='text-autospace:none'><span lang=
1139"EN-US" style=
1140'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;</span></p>
1141</td>
1142</tr>
1143</table>
1144<p class="MsoNormal"><span lang="EN-US" style=
1145'color:black'>&nbsp;</span></p>
1146<p class="MsoNormal"><span lang="EN-US" style=
1147'color:black'>&nbsp;</span></p>
1148<h2><span lang="EN-US">Test: Create a EClass with Extended
1149Rendering Area</span></h2>
1150<p class="MsoNormal"><span lang="EN-US" style=
1151'color:black'>&nbsp;</span></p>
1152<p class="MsoNormal"><span lang="EN-US" style='color:black'>Start
1153the editor and create a new EClass. Verify that the EClass and
1154its selection-handles look similar to the figures
1155above.&nbsp;</span></p>
1156<p class="MsoNormal"><span lang="EN-US" style=
1157'color:black'>&nbsp;</span></p>
1158<p class="MsoNormal"><span lang="EN-US" style=
1159'color:black'>&nbsp;</span></p>
1160<h2><span lang="EN-US">Adjusting the Selection
1161Behavior</span></h2>
1162<p class="MsoNormal"><span lang="EN-US" style=
1163'color:black'>&nbsp;</span></p>
1164<p class="MsoNormal"><span lang="EN-US" style='color:black'>As
1165you can see above the selection-handles of the EClass are around
1166the invisible rectangle.</span></p>
1167<p class="MsoNormal"><span lang="EN-US" style='color:black'>This
1168is not a good selection-behavior, because the user considers the
1169visible rectangle as the &lsquo;main&rsquo; graphics algorithm
1170and doesn&rsquo;t care about the extra space needed to show the
1171anchor. This also means that when resizing/moving the EClass,
1172this should be done on the visible rectangle and not the
1173invisible rectangle.</span></p>
1174<p class="MsoNormal"><span lang="EN-US" style='color:black'>In
1175the following we want to change the selection behavior in a way
1176that the selection-handles appear directly around the visible
1177rectangle, as you can see in the following figure:</span></p>
1178<p class="MsoNormal"><span style='color:black'><img border="0"
1179width="121" height="71" src="visio/rendering-area-2c.gif" alt=
1180""></span></p>
1181<p class="MsoCaption"><span class="code1"><span lang="EN-US"
1182style='font-style:normal'>Figure: Selection-handles around the
1183visible rectangle</span></span><span lang=
1184"EN-US">&nbsp;</span></p>
1185<p class="MsoNormal"><span lang="EN-US" style=
1186'color:black'>Additionally we want to define the visible
1187rectangle as the selection-area, which activates the selection
1188when the mouse clicks into it. So a mouse click on the invisible
1189rectangle outside the visible rectangle will no longer activate
1190the selection.&nbsp;</span></p>
1191<p class="MsoNormal"><span lang="EN-US" style=
1192'color:black'>&nbsp;</span></p>
1193<p class="MsoNormal"><span lang="EN-GB" style=
1194'color:black'>Selection areas are defined in the tool behavior
1195provider.</span></p>
1196<p class="MsoNormal"><span lang="EN-GB" style='color:black'>If
1197you didn&rsquo;t do so already you must <b>first create a tool
1198behavior provider and add it to the diagram type provider as
1199described <a href=
1200"tool-behavior-provider.htm">here</a>.</b></span></p>
1201<p class="MsoNormal"><span lang="EN-GB" style='color:black'>The
1202following methods of the tool behavior provider must be
1203overwritten:</span></p>
1204<p class="MsoNormal"><span lang="EN-GB" style='color:black'>The
1205method <a href=
1206"file://///wdfd00184898a/../javadoc/com/sap/tc/emf/gfw/tb/IToolBehaviorProvider.html#getSelectionGraphicsAlgorithm(com.sap.tc.emf.gfw.mm.pictograms.PictogramElement)">
1207getSelectionGraphicsAlgorithm</a> has to return one graphics
1208algorithm, which defines the selection-handle.</span></p>
1209<p class="MsoNormal"><span lang="EN-GB" style='color:black'>The
1210method <a href=
1211"file://///wdfd00184898a/../javadoc/com/sap/tc/emf/gfw/tb/IToolBehaviorProvider.html#getSelectionArea(com.sap.tc.emf.gfw.mm.pictograms.PictogramElement)">
1212getSelectionArea</a> has to return multiple graphics algorithms,
1213which union defines the selection-area inside which mouse-clicks
1214activate the selection.</span></p>
1215<p class="MsoNormal"><span lang="EN-GB" style=
1216'color:black'>&nbsp;</span></p>
1217<p class="MsoNormal"><span lang="EN-GB" style='color:black'>In
1218this example we want to return the visible rectangle in both
1219methods. &nbsp;</span></p>
1220<p class="MsoNormal"><span lang="EN-US" style=
1221'color:black'>&nbsp;</span></p>
1222<p class="MsoNormal"><span lang="EN-GB" style='color:black'>You
1223can see the complete implementation of the selection area
1224here:</span></p>
1225<p class="MsoNormal"><span lang="EN-GB" style=
1226'color:black'>&nbsp;</span></p>
1227<table class="MsoNormalTable" border="0" cellspacing="0"
1228cellpadding="0" width="851" style=
1229'width:18.0cm;border-collapse:collapse'>
1230<tr>
1231<td width="851" valign="top" style=
1232'width:18.0cm;border:solid windowtext 1.0pt; padding:0cm 5.4pt 0cm 5.4pt'>
1233<p class="MsoNormal" style='text-autospace:none'><span lang=
1234"EN-US" style='color:black'>&nbsp;&nbsp;</span></p>
1235<p class="MsoNormal" style='text-autospace:none'><span lang=
1236"EN-US" style=
1237'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
1238<span lang="EN-US" style=
1239'font-size:10.0pt;font-family:"Courier New"; color:#646464'>@Override</span></p>
1240<p class="MsoNormal" style='text-autospace:none'><span lang=
1241"EN-US" style=
1242'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
1243<b><span lang="EN-US" style=
1244'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>public</span></b>
1245<span lang="EN-US" style=
1246'font-size:10.0pt; font-family:"Courier New";color:black'>GraphicsAlgorithm[]
1247getSelectionArea(PictogramElement pe) {</span></p>
1248<p class="MsoNormal" style='text-autospace:none'><span lang=
1249"EN-US" style=
1250'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1251IFeatureProvider featureProvider =
1252getFeatureProvider();</span></p>
1253<p class="MsoNormal" style='text-autospace:none'><span lang=
1254"EN-US" style=
1255'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1256Object bo =
1257featureProvider.getBusinessObjectForPictogramElement(pe);</span></p>
1258<p class="MsoNormal" style='text-autospace:none'><span lang=
1259"EN-US" style=
1260'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1261<b><span lang="EN-US" style=
1262'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
1263<span lang="EN-US" style=
1264'font-size:10.0pt; font-family:"Courier New";color:black'>(bo</span>
1265<b><span lang="EN-US" style=
1266'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>instanceof</span></b>
1267<span lang="EN-US" style=
1268'font-size:10.0pt;font-family:"Courier New";color:black'>EClass)
1269{</span></p>
1270<p class="MsoNormal" style='text-autospace:none'><span lang=
1271"EN-US" style=
1272'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1273GraphicsAlgorithm invisible =
1274pe.getGraphicsAlgorithm();</span></p>
1275<p class="MsoNormal" style='text-autospace:none'><span lang=
1276"EN-US" style=
1277'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1278GraphicsAlgorithm rectangle =</span></p>
1279<p class="MsoNormal" style='text-autospace:none'><span lang=
1280"EN-US" style=
1281'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1282invisible.getGraphicsAlgorithmChildren().get(0);</span></p>
1283<p class="MsoNormal" style='text-autospace:none'><span lang=
1284"EN-US" style=
1285'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1286<b><span lang="EN-US" style=
1287'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>return</span></b>
1288<b><span lang="EN-US" style=
1289'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>new</span></b>
1290<span lang="EN-US" style=
1291'font-size:10.0pt;font-family:"Courier New";color:black'>GraphicsAlgorithm[]
1292{ rectangle };</span></p>
1293<p class="MsoNormal" style='text-autospace:none'><span lang=
1294"EN-US" style=
1295'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1296}</span></p>
1297<p class="MsoNormal" style='text-autospace:none'><span lang=
1298"EN-US" style=
1299'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1300<b><span lang="EN-US" style=
1301'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>return</span></b>
1302<b><span lang="EN-US" style=
1303'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>super</span></b><span lang="EN-US"
1304style=
1305'font-size:10.0pt;font-family:"Courier New";color:black'>.getSelectionArea(pe);</span></p>
1306<p class="MsoNormal" style='text-autospace:none'><span lang=
1307"EN-US" style=
1308'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;
1309}</span></p>
1310<p class="MsoNormal" style='text-autospace:none'><span lang=
1311"EN-US" style=
1312'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;</span></p>
1313<p class="MsoNormal" style='text-autospace:none'><span lang=
1314"EN-US" style=
1315'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
1316<span lang="EN-US" style=
1317'font-size:10.0pt;font-family:"Courier New"; color:#646464'>@Override</span></p>
1318<p class="MsoNormal" style='text-autospace:none'><span lang=
1319"EN-US" style=
1320'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
1321<b><span lang="EN-US" style=
1322'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>public</span></b>
1323<span lang="EN-US" style=
1324'font-size:10.0pt; font-family:"Courier New";color:black'>GraphicsAlgorithm
1325getSelectionGraphicsAlgorithm(</span></p>
1326<p class="MsoNormal" style='text-autospace:none'><span lang=
1327"EN-US" style=
1328'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1329PictogramElement pe) {</span></p>
1330<p class="MsoNormal" style='text-autospace:none'><span lang=
1331"EN-US" style=
1332'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1333IFeatureProvider featureProvider =
1334getFeatureProvider();</span></p>
1335<p class="MsoNormal" style='text-autospace:none'><span lang=
1336"EN-US" style=
1337'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1338Object bo =
1339featureProvider.getBusinessObjectForPictogramElement(pe);</span></p>
1340<p class="MsoNormal" style='text-autospace:none'><span lang=
1341"EN-US" style=
1342'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1343<b><span lang="EN-US" style=
1344'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>if</span></b>
1345<span lang="EN-US" style=
1346'font-size:10.0pt; font-family:"Courier New";color:black'>(bo</span>
1347<b><span lang="EN-US" style=
1348'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>instanceof</span></b>
1349<span lang="EN-US" style=
1350'font-size:10.0pt;font-family:"Courier New";color:black'>EClass)
1351{</span></p>
1352<p class="MsoNormal" style='text-autospace:none'><span lang=
1353"EN-US" style=
1354'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1355GraphicsAlgorithm invisible = pe.getGraphicsAlgorithm();<br>
1356&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1357EList&lt;GraphicsAlgorithm&gt; graphicsAlgorithmChildren =<br>
1358&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1359invisible.getGraphicsAlgorithmChildren();</span></p>
1360<p class="MsoNormal" style='text-autospace:none'><span lang=
1361"EN-US" style=
1362'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span></p>
1363<p class="MsoNormal" style='text-autospace:none'><span lang=
1364"EN-US" style=
1365'font-size:10.0pt;font-family:"Courier New"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1366<b><span style='color:purple'>if</span></b>
1367(!graphicsAlgorithmChildren.isEmpty()) {<br>
1368&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1369<b><span style='color:purple'>return</span></b>
1370graphicsAlgorithmChildren.get(0);<br>
1371&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1372}</span></p>
1373<p class="MsoNormal" style='text-autospace:none'><span lang=
1374"EN-US" style=
1375'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1376}</span></p>
1377<p class="MsoNormal" style='text-autospace:none'><span lang=
1378"EN-US" style=
1379'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
1380<b><span lang="EN-US" style=
1381'font-size:10.0pt;font-family:"Courier New"; color:#7F0055'>return</span></b>
1382<b><span lang="EN-US" style=
1383'font-size:10.0pt;font-family:"Courier New";color:#7F0055'>super</span></b><span lang="EN-US"
1384style=
1385'font-size:10.0pt;font-family:"Courier New";color:black'>.getSelectionGraphicsAlgorithm(pe);</span></p>
1386<p class="MsoNormal" style='text-autospace:none'><span lang=
1387"EN-US" style=
1388'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp;</span>
1389<span style=
1390'font-size:10.0pt;font-family:"Courier New";color:black'>}</span></p>
1391<p class="MsoNormal" style='text-autospace:none'><span style=
1392'font-size:10.0pt; font-family:"Courier New"'>&nbsp;</span></p>
1393<p class="MsoNormal" style='text-autospace:none'><span lang=
1394"EN-US" style=
1395'font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;</span></p>
1396</td>
1397</tr>
1398</table>
1399<p class="MsoNormal"><span lang="EN-US" style=
1400'color:black'>&nbsp;</span></p>
1401<p class="MsoNormal"><span lang="EN-US" style=
1402'color:black'>&nbsp;</span></p>
1403<h2><span lang="EN-US">Test: Verify the Adjusted Selection
1404Behavior</span></h2>
1405<p class="MsoNormal"><span lang="EN-US" style=
jpaschfa239712010-06-23 12:00:55 +00001406'color:black'><i>Note</i>: This change is incompatible with diagrams created in earlier stages of the tutorial. You will get an exception, when opening these diagrams.</span></p>
1407<p class="MsoNormal"><span lang="EN-US" style=
mwenzb5dc2f92010-06-16 13:24:52 +00001408'color:black'>&nbsp;</span></p>
jpaschfa239712010-06-23 12:00:55 +00001409<p class="MsoNormal">S<span lang="EN-US" style='color:black'>tart
mwenzb5dc2f92010-06-16 13:24:52 +00001410the editor and create a new EClass. Click on the visible
1411rectangle and verify that the selection-handles are only around
1412the visible rectangle.&nbsp;Click slightly right of the visible
1413rectangle on the invisible rectangle and verify that the EClass
1414becomes deselected.</span></p>
1415<p class="MsoNormal"><span lang="EN-US">&nbsp;</span></p>
1416<p class="MsoNormal"><span lang="EN-GB" style=
1417'color:black'>&nbsp;</span></p>
1418</div>
1419<hr>
1420 <a href="http://www.eclipse.org/legal/epl-v10.html" shape="rect">Copyright (c) SAP AG 2005, 2010.</a>
1421</body>
1422</html>