enthought/enaml — pull request #133 by rkern (2012-04-02 14:54:22+00:00)
Title: Fix box strength

`hbox` and `vbox` use `FlexSpacers` on either orthogonal sides of their items. These specify both inequality and equality constraints to request a certain minimum space (`strength=medium, weight=1.5`) and to request that there be no more than that minimum space if possible (`strength=medium, weight=1.25`). Having both of these be `medium` caused problems once you had enough varying-sized items in a box. Eventually, there would be enough smaller items to make the solver try to trade off the error from the inequality constraint on the largest item to reduce the error on the equality constraints of the several smaller items.

I realized that the inequality constraints are really best treated as `required` since they more or less define the boundaries of the box. The items inside of a box should never be outside of the box. I don't really recall why I used `medium` for both initially. Probably a poorly executed experiment had bad results, and I misattributed the cause.

Request for feedback: This change uses `required` for the inequality constraints in the `FlexSpacer`s used by `LinearBoxHelper`. This does not change the default for `FlexSpacer`. Should it?