Runtime errors

I'm getting the following error from 1.3.3 for a node that works normally under 1.2.1. I don't get it from other nodes with similar GUI components.


ERROR OpenDialogAction The dialog pane for node 'DeNovo (#2)' has thrown a 'AWTError'. That is most likely an implementation error.
ERROR OpenDialogAction Illegal request

To date this is probably the most frustrating and inadequate runtime message from Eclipse.

(I would normally not upgrade my development version until my users have updated).


a stacktrace that should help locating the problem should be available in the log file.

If you want, I could look at the log, and/or your code, trying to find out if it is a problem in our code.

peter.ohl at

- Peter

Sorry, it didn't occur to me that the logfile might have something useful in it!


2008-03-12 10:19:55,302 DEBUG main OpenDialogAction : Opening node dialog...
2008-03-12 10:19:55,817 ERROR main OpenDialogAction : The dialog pane for node 'DeNovo (#2)' has thrown a 'AWTError'. That is most likely an implementation error.
2008-03-12 10:19:55,833 ERROR main OpenDialogAction : Illegal request
2008-03-12 10:19:55,833 DEBUG main OpenDialogAction : The dialog pane for node 'DeNovo (#2)' has thrown a 'AWTError'. That is most likely an implementation error.
java.awt.AWTError: Illegal request
at javax.swing.Box.setLayout(
at org.denovo.DeNovoNodeDialog.(

The problem appears to relate to the commented out code in


createNewGroup("Interaction Centres");

DialogComponentNumber c_centre1 = new DialogComponentNumber(
new SettingsModelIntegerBounded( DeNovoNodeModel.CFGKEY_CENTRES1, DeNovoNodeModel.DEFAULT_CENTRE1, 0, 10),
"Minimum ", 1., 2);

c_centre1.setToolTipText("Eliminate molecules with fewer interaction centres than the minimum");
// c_centre1.getComponentPanel().getParent().setLayout(new FlowLayout(0));

DialogComponentNumber c_centre2 = new DialogComponentNumber(
new SettingsModelIntegerBounded( DeNovoNodeModel.CFGKEY_CENTRES2, DeNovoNodeModel.DEFAULT_CENTRE2,
0, 10),
"Maximum ", 1., 2);

c_centre2.setToolTipText("Eliminate molecules with more interaction centres than the maximum");

Under 1.2.1 this places Min and Max fields on the same horizontal line (the range GUI component was broken in 1.2.1). Its not obvious to me what might have changed in 1.3.3 which would prevent this from working - to the extent of causing a crash!

The problem is probably that you are trying to set a FlowLayout into a Swing Box.
Why this is working in 1.2.2, I don't know - we may have changed the components in the dialog component in version 1.3.
The DefaultDialogComponents are really meant for creating simple dialogs. As soon as you need a different layout or a more complex dialog, you probably shouldn't use the default dialog components. We are trying hard not to change the API of the components. But the underlying layout/components/fields could change at any time.
Can you achieve the same thing now with the new option "setHorizontalPlacement(true)"?
That will place/layout all subsequently added components horizontally - until the same method is called with parameter "false".
Also, the DoubleRange component has been fixed.