Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Initializing empty diagrams on a shared model
Initializing empty diagrams on a shared model [message #120232] Wed, 18 April 2007 10:04 Go to next message
Eclipse UserFriend
Hello,

I'm using Initialize diagram X on a shared emf model to create multiple
views of the same model. However, even when I have set syncronized
to be false, the newly created diagrams show all the elements that already
exist
in the model. However, I really want to launch a blank diagram
which I can add new elements to.

Is there anyway to make this happen?

Thanks,

Andy
Re: Initializing empty diagrams on a shared model [message #120436 is a reply to message #120232] Thu, 19 April 2007 03:53 Go to previous messageGo to next message
Eclipse UserFriend
Make sure that ???RootEditPart#createDefaultEditPolicies() doesn't
install a ???CannonicalEditPolicy.

if there is code like:
installEditPolicy(EditPolicyRoles.CANONICAL_ROLE, new
???CanonicalEditPolicy());
the diagram is still syncronized.

setting syncronized to false should normaly remove this code after
regenerating.


ase schrieb:
> Hello,
>
> I'm using Initialize diagram X on a shared emf model to create multiple
> views of the same model. However, even when I have set syncronized
> to be false, the newly created diagrams show all the elements that already
> exist
> in the model. However, I really want to launch a blank diagram
> which I can add new elements to.
>
> Is there anyway to make this happen?
>
> Thanks,
>
> Andy
>
>
Re: Initializing empty diagrams on a shared model [message #120511 is a reply to message #120232] Thu, 19 April 2007 05:24 Go to previous messageGo to next message
Eclipse UserFriend
Hello ase,

Comment out "new DiagramContentsInitializer().initDiagramContents(..)" in
???NewDiagramFileWizard.

-----------------
Alex Shatalin
Re: Initializing empty diagrams on a shared model [message #120550 is a reply to message #120511] Thu, 19 April 2007 05:38 Go to previous messageGo to next message
Eclipse UserFriend
Thanks Alex,

This seems a very important thing to be able to control via the gmfgen
parameters
as I would have thought by default most shared view implementations would
not
want to show the existing elements.

Can it be added as a feature request?

Andy


"Alex Shatalin" <vano@borland.com> wrote in message
news:3c3172e612b298c9508c7f6a8abc@news.eclipse.org...
> Hello ase,
>
> Comment out "new DiagramContentsInitializer().initDiagramContents(..)" in
> ???NewDiagramFileWizard.
>
> -----------------
> Alex Shatalin
>
>
Re: Initializing empty diagrams on a shared model [message #120562 is a reply to message #120436] Thu, 19 April 2007 05:46 Go to previous messageGo to next message
Eclipse UserFriend
Thanks, but this doesn't solve the problem of the elements that are shared
with other views
of the same domain model - they still get added.

I think Alex's email is right in that you have to remove some code, but it
does feel like my
scenario is a common one to want to control via the gmfgen model.

Andy

"Andreas Schuster" <a.schuster@exxcellent.de> wrote in message
news:f0773g$js0$1@build.eclipse.org...
> Make sure that ???RootEditPart#createDefaultEditPolicies() doesn't install
> a ???CannonicalEditPolicy.
>
> if there is code like:
> installEditPolicy(EditPolicyRoles.CANONICAL_ROLE, new
> ???CanonicalEditPolicy());
> the diagram is still syncronized.
>
> setting syncronized to false should normaly remove this code after
> regenerating.
>
>
> ase schrieb:
>> Hello,
>>
>> I'm using Initialize diagram X on a shared emf model to create multiple
>> views of the same model. However, even when I have set syncronized
>> to be false, the newly created diagrams show all the elements that
>> already exist
>> in the model. However, I really want to launch a blank diagram
>> which I can add new elements to.
>>
>> Is there anyway to make this happen?
>>
>> Thanks,
>>
>> Andy
Re: Initializing empty diagrams on a shared model [message #120574 is a reply to message #120550] Thu, 19 April 2007 05:49 Go to previous messageGo to next message
Eclipse UserFriend
Hello ase,

> Can it be added as a feature request?
Sure - create a reuest.

-----------------
Alex Shatalin
Re: Initializing empty diagrams on a shared model [message #120694 is a reply to message #120511] Thu, 19 April 2007 07:36 Go to previous messageGo to next message
Eclipse UserFriend
Hi Alex,
there's no DiagramContentsInitializer or anything similar in my gmf
project. Is the class/method obsolete? I'm working with GMF 2.0M6

Alex Shatalin schrieb:
> Hello ase,
>
> Comment out "new DiagramContentsInitializer().initDiagramContents(..)"
> in ???NewDiagramFileWizard.
>
> -----------------
> Alex Shatalin
>
>
Re: Initializing empty diagrams on a shared model [message #120716 is a reply to message #120694] Thu, 19 April 2007 08:04 Go to previous messageGo to next message
Eclipse UserFriend
Try searching for
initDiagramContents

in your .diagram files.

If it's been addressed a more sensible way, then great, but I doubt it.

Andy



"Andreas Schuster" <a.schuster@exxcellent.de> wrote in message
news:f07k6b$sg1$1@build.eclipse.org...
> Hi Alex,
> there's no DiagramContentsInitializer or anything similar in my gmf
> project. Is the class/method obsolete? I'm working with GMF 2.0M6
>
> Alex Shatalin schrieb:
>> Hello ase,
>>
>> Comment out "new DiagramContentsInitializer().initDiagramContents(..)" in
>> ???NewDiagramFileWizard.
>>
>> -----------------
>> Alex Shatalin
>>
Re: Initializing empty diagrams on a shared model [message #121176 is a reply to message #120694] Mon, 23 April 2007 07:08 Go to previous messageGo to next message
Eclipse UserFriend
Hello Andreas,

> there's no DiagramContentsInitializer or anything similar in my gmf
This class should be generated only for non-synchronized diagrams. Do you
have synchronized diagram?

-----------------
Alex Shatalin
Re: Initializing empty diagrams on a shared model [message #121557 is a reply to message #121176] Tue, 24 April 2007 10:55 Go to previous message
Eclipse UserFriend
hi alex,
thats it. i've generated a syncronized diagram.
but good to know. i'm trying to implement different actions, that makes
it possible to initialize filled or empty diagrams. the
DiagramContentsInitializer is exactly what i need for this approach.

Alex Shatalin schrieb:
> Hello Andreas,
>
>> there's no DiagramContentsInitializer or anything similar in my gmf
> This class should be generated only for non-synchronized diagrams. Do
> you have synchronized diagram?
>
> -----------------
> Alex Shatalin
>
>
Previous Topic:Propsheet : How to integrate the plugin propsheet in my model
Next Topic:EOpposite problem
Goto Forum:
  


Current Time: Sun May 04 00:15:18 EDT 2025

Powered by FUDForum. Page generated in 0.03535 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top