I've a custom property editor for a custom widget. My property editor returns a Java code
which refers a class in classpath. For example;
- Code: Select all
myButton.setSettings(
//property editor begins
new ButtonSettings {
"test", //Button Test
BAlignment.LEFT //an enum class in classpath
}
//property editor ends
);
The problem is that WindowBuilder does not import BAlignment class automatically.
In WindowBuilder 6.9.2,
The designer is adding the java code, but eclipse is giving an import error. And designer
is not refreshing widget Alignment.
In WindowBuilder 7.1
The designer is crashing the code with an error.
If you return the fullpath of the class, probably you won't get an error. Bu it looks awful.
- Code: Select all
myButton.setSettings(
//property editor begins
new ButtonSettings {
"test", //Button Test
org.myproject.mypacket.mysubpacket.BAlignment.LEFT //an enum class in classpath
}
//property editor ends
);
Is there an another way of doing this?
Thanks.