Custom widgets with style property

SWT Designer allows you to create the views, editors, perspectives, pref pages, composites, etc. that comprise Eclipse SWT & RCP applications and plug-ins.

Moderators: Konstantin.Scheglov, gnebling, Alexander.Mitin, jwren, Eric Clayberg

Custom widgets with style property

Postby motse1 » Fri Apr 11, 2008 3:02 am

Hi all,

I have to adapt our custom widgets to be used together with SWT Designer 6.6. The custom widget is (as needed) a subclass of Composite.
As for every composite it is possible to set a few SWT-styles in the SWT-Designer UI properties. My current problem is how do I get
SWT-Designer to show further styles that are supported by our custom widgets in the porperties UI?

Greetings
Martin
motse1
 
Posts: 1
Joined: Fri Apr 11, 2008 2:47 am

Re: Custom widgets with style property

Postby Eric Clayberg » Fri Apr 11, 2008 3:47 am

motse1 wrote:I have to adapt our custom widgets to be used together with SWT Designer 6.6. The custom widget is (as needed) a subclass of Composite.
As for every composite it is possible to set a few SWT-styles in the SWT-Designer UI properties. My current problem is how do I get
SWT-Designer to show further styles that are supported by our custom widgets in the porperties UI?

That is not possible in the current version of SWT Designer (as it is not supported by the current JavaBean spec).

While you can overload the style argument in the constructor to do anything you want, it is really only meant to be used to pass known SWT styles to the widget.

We do plan to offer a way to do this in the future, but, for now, you would need to use a standard bean property instead.
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA


Return to SWT Designer

Who is online

Users browsing this forum: No registered users and 2 guests