Announcement Announcement Module
No announcement yet.
abstractForm formatting Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • abstractForm formatting

    I am confused about AbstractForm formating using string atributes such as "colGrId=label colSpec=leftref" etc.

    What type of language is used here for and can I find some docs with all available atributes?

    Thank you for help,

  • #2
    I assume you are probably talking about the use of one of the implementations of AbstractFormBuilder within the createFormControl method in your form. From the example you've given you are using the TableFormBuilder to create the form panel. The JavaDocs can be found here:

    TableLayoutBuilder talks about the layout and how it is similar to using HTML tables and JGoodies FormLayout. A builder that works more closely with the way JGoodies FormLayout works is FormLayoutFormBuilder, and the documentation for FormLayout can be found here:

    If you are not a fan of either of those there is also a GridBagLayoutBuilder, but I would recommend one of the other two. If you want to know why, look at the JGoodies whitepaper pdf pages 10 and 11. If you are not familiar with JGoodies FormLayout or its successor MigLayout, I would highly recommend you give them a look, you will thank yourself later. Imagine, never having to nest a bunch of panels to get a screen to look like you want it to, and each screen has only one layout. Beautiful, elegant, human readable, and much easier to maintain if you need to modify an existing layout. You could also of course create your own implementation of AbstractFormBuilder if you wanted using your layout manager of choice, such as MigLayout, TableLayout, GroupLayout, etc.