Re: SwiXML and FormLayout
[email protected] Fri, 24 Jun 2005 09:04:43 +0200
| Newsgroups | gmane.comp.embedded.carlsbad-cubes |
|---|---|
| Message-ID | <[email protected]> |
Hello
First of all .. thanks for swixml ..
I very much like the swixml-forms "hack".
I am trying to rewrite it so it can be plugged in into swixml but I am
afraid this will requires some changes to swixml. The current aproach I have chosen is to create new classes
for the LayoutConverter to support the the fromlayout and the ConstraintsConverter to support
formlayout constraints and then registering them to swixml
my now working xml looks like this
<panel layout="formlayout('pref,2dlu,pref,min','pref,2dlu,pref')">
<label labelfor="name" text="Date format" constraints="xy(1,1)"/>
..shorted...
</panel>
I have managed to overide the LayoutConverter by registering it a as LayoutManager converter.
ConverterLibrary.getInstance().register(LayoutManager.class,new FormLayoutConverter());
but for the ConstraintsConverter I can not do the same since that class is not a real converter
(doen't implement the interface and is not registered in the converters).
Therefore I had to change the Parser.java so it uses my "overidden" ConstraintsConverter.
Whould the swixml author accept a patch so that the
ConstraintsConverter can also be plugged in?
greetings
P.S. It looks like that when you use a frame as container it is not possible to change the layoutmanager of the frame you eeded to put a panel in the frame.