Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Changing a DiagramRoot Property
Changing a DiagramRoot Property [message #218322] Wed, 11 February 2009 16:31 Go to next message
Eclipse UserFriend
Hello everybody!

I would like to edit a property from my diagram root(the one that I select
in my XXX.gmfmap/Canvas/Domain Meta information/Element).

This element has a String property called "name". I would like to know if
there is a way to change the value of this property after the user creates
a new diagram. Example: after the wizard defining the names of the files
for a diagram, the name property of the element root should receive the
same value of the diagram name selected by the user.

Any help is appreciated,
Thanks,
Raphael
Re: Changing a DiagramRoot Property [message #218447 is a reply to message #218322] Thu, 12 February 2009 06:55 Go to previous messageGo to next message
Eclipse UserFriend
Hello Raphael,

It should be possible from the properties sheet (if you click on the diagram).
Definitely it is possible to change domain model element properties using
custom code.

-----------------
Alex Shatalin
Re: Changing a DiagramRoot Property [message #218492 is a reply to message #218447] Thu, 12 February 2009 08:47 Go to previous messageGo to next message
Eclipse UserFriend
Hello Alex,

Thanks for the reply!

When I select the diagramroot, using the "project explorer view" the
properties sheet aren't editable. =(

Do you know which class should I have to modify to change a string
property from diagramroot?

Thanks a lot,
Raphael
Re: Changing a DiagramRoot Property [message #218500 is a reply to message #218492] Thu, 12 February 2009 09:24 Go to previous messageGo to next message
Eclipse UserFriend
Hello Raphael,

I meant selecting diagram itself in a diagram editor. Just click to the diagram
surface - in this case properties view should be editable.

-----------------
Alex Shatalin
Re: Changing a DiagramRoot Property [message #218734 is a reply to message #218500] Fri, 13 February 2009 08:32 Go to previous messageGo to next message
Eclipse UserFriend
Alex Shatalin wrote:

> Hello Raphael,

> I meant selecting diagram itself in a diagram editor. Just click to the
diagram
> surface - in this case properties view should be editable.

> -----------------
> Alex ShatalinHello Alex,

i have the same question..
this question is... i have root element, example: class DOMAIN with
atributte name - type string.

In Mapping i set "DOMAIN" in "Element" of "Domain Meta information".

Its ok.. i build my diagram and initialize this..
but the name of DOMAIN in navigator of Package Explorer initialize with
value "null".
I want initialize this name, but i cant put feature seq initializer before
top nodding....

Any ideia?

Thanks,
Danilo
Re: Changing a DiagramRoot Property [message #218768 is a reply to message #218734] Fri, 13 February 2009 09:40 Go to previous messageGo to next message
Eclipse UserFriend
Hello Danilo,

> Any ideia?
Looks like you can modify generated code + add a request asking to allow
diagram element's initialization description in .gmfmap model.

-----------------
Alex Shatalin
Re: Changing a DiagramRoot Property [message #218847 is a reply to message #218768] Fri, 13 February 2009 13:15 Go to previous messageGo to next message
Eclipse UserFriend
Alex Shatalin wrote:

> Hello Danilo,

>> Any ideia?
> Looks like you can modify generated code + add a request asking to allow
> diagram element's initialization description in .gmfmap model.

> -----------------
> Alex Shatalin

But.. Where i need modify the code?
Re: Changing a DiagramRoot Property [message #218923 is a reply to message #218847] Mon, 16 February 2009 06:13 Go to previous messageGo to next message
Eclipse UserFriend
Hello Danilo,

If you have to modify properties of newly created domain diagram element
then you can patch generated ???DiagramEditorUtil.createInitialModel() method.

-----------------
Alex Shatalin
Re: Changing a DiagramRoot Property [message #219014 is a reply to message #218923] Mon, 16 February 2009 13:39 Go to previous message
Eclipse UserFriend
its works
thanks!
Previous Topic:Making a label non-editable
Next Topic:default font
Goto Forum:
  


Current Time: Tue Jul 15 23:04:39 EDT 2025

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

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

Back to the top