[Panel-devel] [PATCH] Beginnings of a panel implementation for discussion
Percy Leonhardt
mailings at eris23.de
Thu Aug 23 20:31:47 CEST 2007
On Thursday 23 August 2007, Matt Broadstone wrote:
> Looks good to me, but while you're at it get rid of that code dupe and
> move it into BoxLayout.
But
hintHeight = qMax(hint.height(), hintHeight);
hintWidth += hint.width() + spacing();
and
hintWidth = qMax(hint.width(), hintWidth);
hintHeight += hint.height() + spacing();
are not really the same code. Only the second half of the functions are the
same:
hintWidth += 2 * margin();
hintHeight += 2 * margin();
Or should I go a step further and do what Aaron suggested:
> they have been mostly. it's "just" the layout method that remains duplicated
> and that would be pretty easy to fix with a member variable in BoxLayout
> that records whether it is going horizontally or vertically, then HBox and
> VBox just because convenience classes more or less. iow, exactly how qt
> does it.
If wanted I can try that.
Percy
More information about the Panel-devel
mailing list