das-developers / das2java

The original das2 library. Provides interactive publication-ready 2-D plotting
https://das2.org
GNU Lesser General Public License v3.0
4 stars 0 forks source link

DasRow and DasColumn minLayout and maxLayout properties #82

Closed jbfaden closed 8 months ago

jbfaden commented 8 months ago

I've added the properties maxLayout and minLayout to Das2's DasColumn and DasRow objects, so that Autoplot can simply bind to these and the problem of managing layout is all in one class. The problem with the old method is that it requires three transactions to set the position, each firing events. Then, an a locking mechanism was added to suppress the firing. This would all be resolved if control strings like "100%-2em+3px" were used to control.

Last, I keep thinking of using fractions instead of percents, so to make a stack of five plots you could say "3/5-2em" instead of "60%-2em". Having a control string would allow more flexibility because it separates the controls from the Java API (setNormal, setEmOffset, etc). Something to consider...

jbfaden commented 8 months ago

This seems to be working fine