Needed for the contents of the option arguments JPanel.
This contents is a sequence of widgets for data input (or groups
thereof!), and they should "flow" in the lines which make up a block
in the right half of the top-level "grid-bag".
(The normal "FlowLayout" from javax.swing does not respect a maximum size,
but makes the container above grow beyond all limits, so no line break would ever
happen.)
WE FOUND THIS CODE SOMEWHERE IN THE NET, BUT DID NOT MEMORIZE !?!?!
We tried to find it again (for reasons of acknowledgement), but failed.
((There is a DIFFERENT approach with the same name at
Copyright (c) 2007, Distributed Computing Group (DCG)
ETH Zurich
Switzerland
dcg.ethz.ch
))
There is another alternative at http://softech.informatik.uni-kl.de/twiki/pub/Homepage/ProgrammBeispieleBuch/Programme-KooP-Buch/kap5/layoutManagen/TextLayout.java
Finally:
https://svn2.assembla.com/svn/savant/MedSavant/branches/b5/MedSavant/src/org/ut/biolab/medsavant/view/swing/WrapLayout.java
This seems derived from the same source as ours, but no acknowledgement either !?