Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Multiple Canvas
Multiple Canvas [message #148970] Wed, 05 September 2007 05:26 Go to next message
Eclipse UserFriend
Originally posted by: marsha.rohrer.swisscom.com

Hi

Is it possible to define multiple canvas for an editor. Like this I could
have a subcanvas that represents the model designed in an other editor and
the maincanvas where I can "draw" on.

Thanks

Marsha
Re: Multiple Canvas [message #149952 is a reply to message #148970] Tue, 11 September 2007 05:30 Go to previous messageGo to next message
Eclipse UserFriend
Hello Marsha,

Are you talking about the possibility to "open diagram for the subpackage"
on class diagram?

-----------------
Alex Shatalin
Re: Multiple Canvas [message #150256 is a reply to message #149952] Wed, 12 September 2007 01:57 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: marsha.rohrer.swisscom.com

Hi Alex.

I don't really know. My goal is to have two editors with one shared
editing domain. If I follow the tutorial I'm not able to draw on the
second editor.

In more detail: I open the first editor and I create a diagram. Then I
choose "Open With" editor 2 and I'd like to continue with my diagram with
the palette of editor 2. Unfortunately this doesn't work. If I hover to
the Canvas the "empty set" symbol is shown, saying that I'm not allowed to
draw this figure.

So now I'm serching for a reason why this does not work, and what other
solutions I could find. One idea was to create two canvas and to lay the
canvas from editor 2 over the one of editor 1. Like this the diagram on
canvas 1 is not editable any more and I can continue the diagram with
editor 2.

Thanks a lot

Marsha
Re: Multiple Canvas [message #150331 is a reply to message #150256] Wed, 12 September 2007 05:51 Go to previous messageGo to next message
Eclipse UserFriend
Hello Marsha,

> hover to the Canvas the "empty set" symbol is shown, saying that I'm
> not allowed to draw this figure.
Looks like the problem is in ElementType registration. You should register
only one ElementType hierarchy for one EditingDmomain id. If you'd like to
use the same EditingDomain ID on the second diagram you should menually "merge"
ElementType hierarchies.

-----------------
Alex Shatalin
Re: Multiple Canvas [message #150377 is a reply to message #150331] Wed, 12 September 2007 07:02 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: marsha.rohrer.swisscom.com

Hi Alex,

Alex Shatalin wrote:
> If you'd like to use the same EditingDomain ID on the second diagram you
should > menually "merge" ElementType hierarchies.

Thanks for your reply. How do I achieve this? With the elementTypeBindings
extension point in the plugin.xml? Or in the generated code?
I tried to achieve my goal following the two tutorials. Is there something
missing in those tutorials then?

http://wiki.eclipse.org/index.php/GMF_Tips#Sharing_single_Ed itingDomain_instance_across_several_diagrams
http://sdqweb.ipd.uni-karlsruhe.de/wiki/GMF

Thanks

Marsha
Re: Multiple Canvas [message #150539 is a reply to message #150377] Thu, 13 September 2007 04:22 Go to previous messageGo to next message
Eclipse UserFriend
Hello Marsha,

> http://wiki.eclipse.org/index.php/GMF_Tips#Sharing_single_Ed itingDomai
> n_instance_across_several_diagrams
Contains:
10. Only one metamodelType could be registered for each EClass in scope of
one EditingDomain. During this step you have to replace by specializationType
declaration all the metamodelType declarations inside plugin.xml for diagram2
duplicating metamodelType declarations inside plugin.xml for diagram1 (having
the same eclass attribute). Following part of plugin.xml:

So, I suppose this step was not done properly.

-----------------
Alex Shatalin
Re: Multiple Canvas [message #150662 is a reply to message #150539] Thu, 13 September 2007 08:28 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: marsha.rohrer.swisscom.com

Unfortunately not. I tried it several times from scratch and I end up with
the same problem at each trial.

Thanks anyway

Marsha
Re: Multiple Canvas [message #150809 is a reply to message #150662] Fri, 14 September 2007 05:16 Go to previous messageGo to next message
Eclipse UserFriend
Hello Marsha,

Looks like I read your original description with lack of attention. I’ll
try to correct the situation now. ;-)

>In more detail: I open the first editor and I create a diagram.
>Then I choose "Open With" editor 2 and I'd like to continue with my diagram
with
>the palette of editor 2. Unfortunately this doesn't work. If I hover to
the Canvas
>the "empty set" symbol is shown, saying that I'm not allowed to draw this
figure.
The problem is: you are trying to open first diagram file using second diagram
editor. This is incorrect. You can open diagram file only using appropriate
editor. Second editor is using different Visual ID’s + potentially can has
different diagram element structure.

If you’d like to create kind of “template diagram” using the first editor
and continue working with this diagram in the second editor (due to some
reasons this should be two different editors) then I suggest you to create
“initialize diagram from template” action for the second editor. Another
option is to extend editor2 from editor1, but this use case is not supported
by generator right now, so you should do it manually.

-----------------
Alex Shatalin
Re: Multiple Canvas [message #150814 is a reply to message #150809] Fri, 14 September 2007 06:30 Go to previous message
Eclipse UserFriend
Originally posted by: marsha.rohrer.swisscom.com

Hi Alex.

Thanks for your reply...I got that now that this is not possible. Im
trying the "Initialize..." thing now.
But up to know I can't load the "template" but I posted a question in the
accorting thread.

Marsha
Previous Topic:Importing Diagrams (GMF 1.0)
Next Topic:Creating a standalone app
Goto Forum:
  


Current Time: Fri Apr 25 21:10:13 EDT 2025

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

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

Back to the top