Designer 2.0.1 beta bug

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

Designer 2.0.1 beta bug

Postby jnorris » Wed Aug 11, 2004 9:38 am

Hi,

The following line of code causes SWT-Designer to throw an exception:

Code: Select all
for( int i = listCount, j = 0 ; (i < 3) && (j < items.length) ; i++, j++ )


This is in a widget selected method in response to clicking a button. Looking at the error screen it looks like the actual code in the method is being compared to code that has all of the formatting stripped out. However the ',' between the ++i and ++j is missing so the two versions of the source are not seen as being equal.

To recreate the exception - create a JFace Dialog and add the following in the createDialogArea method. Then try to change anything in the dialog and the error will occur.
Code: Select all
for( int i = 1, j = 0 ; (i < 3) && (j <2) ; i++, j++ )
    ;

I also get an error dialog a lot of times with the following message when I am editing code in the source pane:
super.createDialogArea(parent) expected in createDialogArea, but empty block found.
When this happens eclipse takes 95-99% of the cpu time and I end up having to kill the process. I now pretty much always open the file with the Java editor to edit the source code instead of using Designer to avoid killing Eclipse and losing work.

It would be good to know if there are any specific rules that Designer uses so manually editing the source instead of using Designer doesn't cause the system to hang as a result.

Jim
jnorris
 
Posts: 17
Joined: Tue Jul 27, 2004 5:10 am

Re: Designer 2.0.1 beta bug

Postby Eric Clayberg » Thu Aug 12, 2004 9:18 am

jnorris wrote:The following line of code causes SWT-Designer to throw an exception:

Code: Select all
for( int i = listCount, j = 0 ; (i < 3) && (j < items.length) ; i++, j++ )

This appears to be a problem isolated to Designer's diagnostic checking module. Do you have that turned on? Turn that off and the problem should go away. We have fixed the diagnostic problem for the next update.

jnorris wrote:I also get an error dialog a lot of times with the following message when I am editing code in the source pane:
super.createDialogArea(parent) expected in createDialogArea, but empty block found.

What changes were you making to that method? Did you remove the super.createDialogArea(parent) call?

jnorris wrote:When this happens eclipse takes 95-99% of the cpu time and I end up having to kill the process.

I have never had this happen, so I need more details on what you were doing at the time. Seeing an actual example would be very helpful.

jnorris wrote:It would be good to know if there are any specific rules that Designer uses so manually editing the source instead of using Designer doesn't cause the system to hang as a result.

There aren't any "rules". As I have never had this happen, I am assuming you are running into some very specialized event. Without more information, I can't even speculate on what might have happened or even begin to address the problem. If we can reproduce the problem, I'm sure we can fix it.
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

Postby jnorris » Fri Aug 13, 2004 3:57 am

Thanks for the reply Eric. I did have the diagnostic checking enabled. Without it everything is ok.

As for the empty block error message the super.createDialogArea(parent) call is where it was put when the dialog was created. I'm not seeing it now with the diagnostic checking disabled.

All in all, I think that Designer is a great plug-in and has saved me a lot of time and effort - well worth the purchase to me.
jnorris
 
Posts: 17
Joined: Tue Jul 27, 2004 5:10 am


Return to SWT Designer

Who is online

Users browsing this forum: No registered users and 1 guest