Le 24/11/2015 01:48, Uwe Stöhr a écrit :
Am 23.11.2015 um 18:05 schrieb Jean-Marc Lasgouttes:
Can I commit this first patch?
The patch looks reasonable but why is this change necessary?:
- dim = Dimension(10, 10, 10);
+ dim = Dimension(5, 10, 10);
Maybe the reason for the values should be documented in a comment.
The two last 10 are ascent and descent. For the first one (the width),
the old code read:
if (pm.hfillExpansion(row, cit->pos))
cit->dim.wid = int(cit->pos >= body_pos ?
max(hfill, 5.0) : row.label_hfill);
else
cit->dim.wid = 5;
So, as you can see the width of a non-expanded hfill is set to 5. So the
initial value of 10 is not used. It is better to initialize it properly
from the start.
As for the reason for the values, I don't know. I'd say they are
arbitrary :)
JMarc