Eclipse/Visual Designer

I played with the visual designer a bit in Eclipse (some time ago, to be honest), but I have not used it for any of my programs.

I noticed that the Eclipse ‘Open With…’ menu item includes something called ‘Vaadin Editor’ which I assume is the visual designer. I tried opening a file (which has forms, text fields, buttons etc.) on it using the Vaadin Editor and when I click the ‘Design’ tab in the editor, I get a popup error saying ‘Failed to find or parse visually editable class caused by Not an editable CustomComponent’.

Can someone tell me what that means? The file in question extends VerticalLayout - do I need to change that to be able to use the visual editor? Is that something worth considering?

I have not seen any updates to the Visual Editor - is that a project that is not being maintained or improved? Is it worth trying to use?

thanks,

nbc

I think the Visual Editor is a bit on the back burner now, but definitely not abandoned.

I think you’re not limited to only using a CustomComponent as the root, but I might be wrong also. But you should have the @VisuallEditable (something like that) annotation in the class in order for the editor to be able to parse the class, and you also need some specially named methods there I think. You can try by creating a new component with the editor and seeing how the code is structured there and them maybe try to retrofit your component to a similar structure.

Thanks - I’ll look into doing that…

nbc

The current version of the visual editor only supports CustomComponents with a certain kind of structure - see
this book page
for some information. A CustomComponent can have a layout as its content, though, so the difference from editing a layout directly is small.

There should be fields and methods with an @AutoGenerated annotation for each component in the visually editable class.

I could note that the editor part and its data model does not really have these limitations but the Eclipse code parsing and generation integration does, and I wouldn’t expect the generated class structure or these limitations to change much.

The Visual Designer will be updated to support Vaadin 7 after Vaadin 7 release and might also get other updates at that point.

Any plans to merge the Visual Designer with eclipse’s Window Builder?

http://www.eclipse.org/windowbuilder/

I believe it already handles GWT, in addition to SWT and Swing.

A few years ago I evaluated the then commercial product on which eclipse’s Window Builder is based on for Swing work. It was very good!

Starting my first Vaadin project I had a look at the Visual Designer, and quickly decided not to bother with it.

Maintaining a completely in-house solution, with questionable quality and low rate of adoption, seems like a waste of resources to me.

/Anders

This would not be a merge but a total rewrite.

When Vaadin visual editor was first developed, WindowBuilder was a commercial closed-source product. At least according to the Eclipse project page, WindowBuilder is still not a full Eclipse project but in the proposal phase, pending full IP review and more.

Vaadin visual editor is running as a Vaadin application and thus can use the real Vaadin components and support its layout features. In fact, there are also some applications outside of Eclipse using the visual editor directly for various purposes, whereas WindowBuilder is in practice specific to Eclipse.

Both visual editors are open source projects, though, so anyone can create and contribute a Vaadin extension for WindowBuilder. Already, e.g. each Swing layout is a separate Eclipse plug-in (or two) in WindowBuilder, so it might not be necessary to make any changes to existing WindowBuilder code and this could be built piece by piece if someone first sets up the main projects and build infrastructure for it.