Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Problem with properties
Problem with properties [message #1136] Mon, 31 July 2006 15:59 Go to next message
Eclipse UserFriend
Originally posted by: bob2.msn.com

Hi,

I've spent ages trying to implement my own properites for my generated
diagrams but I'm not getting anywhere. I've read the "Take control of your
properties" and "The Eclipse Tabbed Properties View" articles but I still
cant get even a simple property box to work with the message "Properties are
not available".

I've based most of what I've done on the HockeyLeague example and am just
trying to get the name of a node in my diagram to be displayed in the
property box.

I've added the propertyContributor, propertyTabs and propertySections to my
plugin.xml and have copied AbstractStringPropertySection,
AbstractTextPropertySection, HockeyleaguePropertySheetPage and
NamePropertySection, AbstractHockeyleaguePropertySection classes. I've
changed the following to conform with my own diagram:

NamePropertySection's getFeature method uses my own package instead of
HockeyleaguePackage.
In my editor file, it now implements ITabbedPropertySheetPageContributor and
I've added the methods getContibutorId() and getAdapter(Class) as the
article says.
I've only got one property section which uses the class NamePropertySection.
The input to the section has been set to a class in my model which extends
EObject and just has get and set methods for a name.

In the propertySheetPage, it has a method to get the AdapterFactory of the
editor. My editor doesent have an adapterfactory method. Im not entirely
sure what this actually does and if its got any relevance to the properties
not appearing.

Has anyone had any similar problems and know what to do to fix this?

Thanks in advance
Bob
Re: Problem with properties [message #1190 is a reply to message #1136] Mon, 31 July 2006 19:24 Go to previous messageGo to next message
Anthony Hunter is currently offline Anthony HunterFriend
Messages: 446
Registered: July 2009
Senior Member
Hi

The message "Properties are not available" indicates that no
propertySections match your selection.

I am guessing that you are selecting objects on the diagram, which are
EditParts, yet the <input> in the propertySections specify semantic objects.

I would debug TabbedPropertySheetPage.setInput() to make sure the selection
is as you expect.

You can then look at the typeMapper used in the logic example which
translates between the diagram and the semantic objects.

Cheers...
Anthony


"bob" <bob2@msn.com> wrote in message news:eal995$t9e$1@utils.eclipse.org...
> Hi,
>
> I've spent ages trying to implement my own properites for my generated
> diagrams but I'm not getting anywhere. I've read the "Take control of
> your
> properties" and "The Eclipse Tabbed Properties View" articles but I still
> cant get even a simple property box to work with the message "Properties
> are
> not available".
>
> I've based most of what I've done on the HockeyLeague example and am just
> trying to get the name of a node in my diagram to be displayed in the
> property box.
>
> I've added the propertyContributor, propertyTabs and propertySections to
> my
> plugin.xml and have copied AbstractStringPropertySection,
> AbstractTextPropertySection, HockeyleaguePropertySheetPage and
> NamePropertySection, AbstractHockeyleaguePropertySection classes. I've
> changed the following to conform with my own diagram:
>
> NamePropertySection's getFeature method uses my own package instead of
> HockeyleaguePackage.
> In my editor file, it now implements ITabbedPropertySheetPageContributor
> and
> I've added the methods getContibutorId() and getAdapter(Class) as the
> article says.
> I've only got one property section which uses the class
> NamePropertySection.
> The input to the section has been set to a class in my model which extends
> EObject and just has get and set methods for a name.
>
> In the propertySheetPage, it has a method to get the AdapterFactory of the
> editor. My editor doesent have an adapterfactory method. Im not entirely
> sure what this actually does and if its got any relevance to the
> properties
> not appearing.
>
> Has anyone had any similar problems and know what to do to fix this?
>
> Thanks in advance
> Bob
>
>
>
Re: Problem with properties [message #2674 is a reply to message #1190] Wed, 02 August 2006 16:54 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: bob2.msn.com

Thanks for your help. I've managed to get it working now
Re: Problem with properties [message #4353 is a reply to message #2674] Thu, 03 August 2006 10:18 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: netsrujana.rediffmail.com

Hi Bob,

I have been struggling with the properties for a while now, with the GMF
generated code. Could you let me know how you managed to make it work

regards,
Phani Kumar K.

"bob" <bob2@msn.com> wrote in message news:eaql87$vko$1@utils.eclipse.org...
> Thanks for your help. I've managed to get it working now
>
>
Re: Problem with properties [message #4697 is a reply to message #4353] Thu, 03 August 2006 12:21 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: netsrujana.rediffmail.com

Hi

I made it work, the culprit is the TypeMapper

"Phani Kumar Kotaprolu" <netsrujana@rediffmail.com> wrote in message
news:easiho$1bo$1@utils.eclipse.org...
> Hi Bob,
>
> I have been struggling with the properties for a while now, with the GMF
> generated code. Could you let me know how you managed to make it work
>
> regards,
> Phani Kumar K.
>
> "bob" <bob2@msn.com> wrote in message
> news:eaql87$vko$1@utils.eclipse.org...
>> Thanks for your help. I've managed to get it working now
>>
>>
>
>
Re: Problem with properties [message #6687 is a reply to message #4697] Sun, 06 August 2006 11:00 Go to previous message
Eclipse UserFriend
Originally posted by: bob2.msn.com

Yes the TypeMapper was the problem for me aswell.
Previous Topic:New to GMF - help needed
Next Topic:refactoring GMF document support into platform
Goto Forum:
  


Current Time: Sat Nov 02 18:03:38 GMT 2024

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

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

Back to the top