- I have bought a brand new notebook (for those interested: that's a Sony VAIO Z)!
- It's taken me a long time to have DesignGridLayout tests run on both my old notebook (Windows XP) and my new one (Vista)
- I have plaid with Hudson on my old notebook to setup a continuous build for DesignGridLayout
Where do we stand?
Version 1.2, which I am currently working on, shall have the following features:
- alignment synchronization of multiple panels (all using DesignGridLayout): particularly useful to make smooth panels transitions in Tab panes and Wizards.
- optional consistent baselines spacing between consecutive rows (only for fixed height rows).
- addition of a new API to notify DesignGridLayout of special components behavior with regards to vertical resize.
Enhancement #2 above is already implemented in Subversion trunk, here are 2 screenshots comparing the same layout with and without consistent baseline spacing, respectively:
Note the consistent spacing between labels baselines for all rows but the second one (because it has variable height) and the last one (because it has an emptyRow() before it to visually separate that row from the previous one).
Without consistent baselines spacing, all vertical gaps conform to the values provided by the installed look & feel, but due to different heights of components and different vertical gaps, the inter-row spacing doesn't look consistent and is not very eye-friendly (this is particularly true when observing the column of labels).
Regarding synchronization of alignments between different panels (enhancement #1 above), the following screenshots help showing what works today (excerpts from DesignGridLayout automatic tests).
The example below is a dialog with a tabbed pane, embedding two different tabs. The first 2 screenshots show both tabs, built with DesignGridLayout, without synchronization.
Please note that there are no horizontal or vertical alignments between both tabs, this is particularly noticeable when running the application and changing from one tab to the other.
Now, let's add just one line of code to the layout building code, as follows:
Synchronizer.synchronize(layout1, layout2).alignGrids().alignRows();Then the screenshots become different (note that I have put the 2nd tab both on the right side and on the bottom of the first tab so that you can easily check alignments in both directions):
You can notice the alignment of the origins of both columns of fields, and you can also check that all rows baselines from both tabs are aligned with one another.
This example is particularly interesting due to the use of Java -default- Metal look & feel, in which different kinds of components have different heights (compare the heights of JTextField and JComboBox); other look & feels may have consistent heights for all components, which would not show the difficulty of aligning each and every row from one tab to its matching row in the other tab. I am not sure other LayoutManagers can do that, I haven't checked yet though.
Back to DesignGridLayout V1.2 schedule, I still have some work with:
- baseline synchronization
- new API for vertical resize behavior customization (point #3 above)
- layout calculation optimization (avoid multiple recalculation)
- End May: 1.2 beta 1 out, beta testing will last one month
- End June: 1.2 rc 1 out, followed by final release after 2 weeks (or 2 weeks after latest rc if bugs are reported)
Later, for V1.3, I foresee enhancements to non-grid rows API & functionality:
- possibility to separate 2 components with unrelated gaps
- smart positioning of standard buttons (OK, Cancel...) based on the runtime platform
- make component sizes consistent across several rows (currently, sizes are consistent inside individual rows only)