News from the editor

December 16, 2011 at 2:46 pm Leave a comment


A while back we wrote about a new XForms editor as part of our post ‘What’s new in betterFORM limeGreen’. Now it’s about time for an update as we have a first working beta running and it’s ready for testing by the community.

Before this questions comes up – no, it’s not WYSIWYG and likely never will be. We’ve been working with XForms for many years and our experience showed that it’s not the layout and styling that are the challenges in XForms authoring. In contrast – concentrating on this aspect just draws the attention away from the more challenging aspects of building XForms.

XForms offers an abstraction layer for developing complex forms with constraints, calculations, events, actions, submissions and a dynamic UI that ignores the concrete rendering of a control on a device. And we think there should be an editor that supports this abstract view.

It must be confessed that XForms is not easy to master – especially not for the beginner. You have to learn a set of elements, attributes, know at least the basics of XPath, understand XML Events and namespaces and learn to assemble all that in a meaningful manner. You also have to understand some basic concepts like the MVC, the lifecycle, bindings etc. and finally write all that down without typos in your favorite text editor. Wouldn’t it be good to at least have a little help with some of these aspects?

To achieve consistency with the XForms Schema we decided to generate big parts of the editor directly from the schema. This makes sure that all elements and attributes are present and supported.

The editor can be started directly from the betterFORM dashboard. Clicking the editor icon next to the filename this will be opened in the editor.

opening the editor from dashboard

opening the editor from dashboard

The following screen will appear.

Editor Window

the editor window

The loaded document is a XHTML/XForms document but HTML elements are not shown. Instead the editor focusses on the XForms elements and shows them in a hierarchical view of boxes where each box represents an element in the document. However HTML markup will not be discarded by the editing process  – it will be preserved and will still be part of the output document.

On the right side all possible attributes for the element are shown and can be edited. In the current early version these attributes are not sorted and do not offer any help. This will change in later versions – we plan to add hint and help texts that give some explanations about the attributes. Further we’ll introduce some sorting of the attributes depending on the frequency of their use.

The currently selected element will show 3 buttons on the right side:

  • one for inserting sibling elements
  • one for inserting child elements
  • and one to delete the current element

This screenshot shows the context menu for inserting elements.

context-menu for element insertion

context-menu for element insertion

For efficient use the whole editor can be driven by keyboard: elements can be navigated and re-sorted, new elements can be inserted or deleted and there is a popup window listing the most important shortcuts.

The current version is still basic and may contain bugs. But it’s functional and the commands ‘preview’, ‘save’ and ‘save as’ are working. Currently we concentrate on eliminating the last bugs, offer support for templates and improve the handling of mixed content which is sometimes still shown though it does not break the editors functionality.

Though already a big help for users that do not want to deal with the naked markup this version is still targetted at developers. A future version for end users will offer different modes to create a form. We keep you posted.

If you’d like to try what we got you have to checkout and build the development branch on GitHub. Instruction on building are found here. However if you like to have a online presentation please send a notice to info at betterform dot de and we’ll arrange a session for you.

Comments and suggestions welcome.

Entry filed under: Uncategorized. Tags: .

Aeronautical Information Services (AIS) and XForms 2011 in review

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Trackback this post  |  Subscribe to the comments via RSS Feed


Recent Posts

betterFORM tweets


%d bloggers like this: