Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » hide single property attribute
hide single property attribute [message #189075] Fri, 23 May 2008 11:33 Go to next message
paolo russian is currently offline paolo russianFriend
Messages: 34
Registered: July 2009
Member
How may I hide from my property view a choosen EAttribute of mine? I have
built a working custom tab property view that reads/saves its value, so I
don't want this property to be shown under the full property list any more.

Thanks!

Paolo
Re: hide single property attribute [message #189107 is a reply to message #189075] Fri, 23 May 2008 12:55 Go to previous messageGo to next message
paolo russian is currently offline paolo russianFriend
Messages: 34
Registered: July 2009
Member
don't know if it's the better way, but I did by commenting out

public List getPropertyDescriptors(Object object) {
if (itemPropertyDescriptors == null) {
super.getPropertyDescriptors(object);
[...]
addCSSPaddingRightPropertyDescriptor(object);
addRenderedELPropertyDescriptor(object);
//addCustomCodePropertyDescriptor(object); //don't get displayed!!
addRequiredPropertyDescriptor(object);
addStyleClassPropertyDescriptor(object);
[...]
}
return itemPropertyDescriptors;
}


in xxxxxItemProvider.java

This does not remove the eattribute, but prevents only to be enlisted in
the property sheets. Anyway you can access it by get/set methods if you
need to, this is the case if you do a custom tab sheet property view with
a specific editor for a property (here I have a large swt textarea where
to paste & edit code inside).
Re: hide single property attribute [message #189124 is a reply to message #189107] Fri, 23 May 2008 13:43 Go to previous message
Eclipse UserFriend
Originally posted by: gmerin.integranova.com

Hi Paolo,
You could have achieve that just changing the "property type" to "None"
within your genmodel. It changes the below code for you automatically.

Regards,
Gabriel.

paolo escribió:
> don't know if it's the better way, but I did by commenting out
>
> public List getPropertyDescriptors(Object object) {
> if (itemPropertyDescriptors == null) {
> super.getPropertyDescriptors(object);
> [...]
> addCSSPaddingRightPropertyDescriptor(object);
> addRenderedELPropertyDescriptor(object);
> //addCustomCodePropertyDescriptor(object); //don't get displayed!!
> addRequiredPropertyDescriptor(object);
> addStyleClassPropertyDescriptor(object);
> [...]
> }
> return itemPropertyDescriptors;
> }
>
>
> in xxxxxItemProvider.java
>
> This does not remove the eattribute, but prevents only to be enlisted in
> the property sheets. Anyway you can access it by get/set methods if you
> need to, this is the case if you do a custom tab sheet property view
> with a specific editor for a property (here I have a large swt textarea
> where to paste & edit code inside).
>
Previous Topic:Error saving resource set
Next Topic:PartContribution
Goto Forum:
  


Current Time: Thu Apr 25 04:45:02 GMT 2024

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

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

Back to the top