Find all elements of the same type [message #160214] |
Wed, 14 November 2007 06:03  |
Eclipse User |
|
|
|
Originally posted by: boucher.fbk.eu
Hi,
I'm a beginner with GMF and I'm facing some problems.
I'd like to know how to get access to all elements of the same type than
the element that has just be modified (in order to apply the same outline
properties like color, size,...).
Is it also possible to get access to all elements of a diagram in order to
check that there is a minimal distance between them?!
Thank you for your help.
Quentin
|
|
|
|
Re: Find all elements of the same type [message #160428 is a reply to message #160249] |
Wed, 14 November 2007 10:34   |
Eclipse User |
|
|
|
Originally posted by: ijerez2001.msn.com
I prevent overlapping in each ElementEditPart, in the
handleNotificationEvent method.
When the notifier is a Bounds, it is because You have moved a figure, and I
prevent that the new position not overlap with another figure using the
figures of the editpart.
"Tomas Zijdemans" <trommas@yahoo.com> escribió en el mensaje de
noticias:fheudq$hgj$1@build.eclipse.org...
> Quentin wrote:
>> Hi,
>>
>> I'm a beginner with GMF and I'm facing some problems.
>>
>> I'd like to know how to get access to all elements of the same type than
>> the element that has just be modified (in order to apply the same outline
>> properties like color, size,...).
> This should be doable. All your objects are contained by some element
> (Like library in the tutorial). This element holds a collection over all
> model elements of this type, so you can just iterate through it.
>
>> Is it also possible to get access to all elements of a diagram in order
>> to check that there is a minimal distance between them?!
> You can get access to all elements like I described above, but check for
> minimal distance is a bit more tricky. Maybe this will be of help:
>
> http://wiki.eclipse.org/index.php/GMF_Newsgroup_Q&A#How_ do_I_prevent_figure_overlap.3F
>
> HTH,
>
> Tomas Zijdemans
|
|
|
|
|
|
Re: Find all elements of the same type [message #160643 is a reply to message #160617] |
Thu, 15 November 2007 07:41  |
Eclipse User |
|
|
|
Originally posted by: quentin.boucher.gmail.com
Thank you,
Actually I want to check some properties (compared to some elements of the
same type) of an element whent it is modified/created. I'll try to do this
with the informations you gave me.
Regards,
Quentin
|
|
|
Powered by
FUDForum. Page generated in 0.05063 seconds