Search
Wednesday, 19th of September 2018, 20:23:37 UTC
5:26:21
beach
Good morning everyone!
6:44:01
jackdaniel
currently our make-space-requirements asserts, that <= 0 min-width width max-width (and similar for height)
6:44:18
jackdaniel
I think we should clamp values instead
6:44:42
jackdaniel
example: sometimes we compbine space requirements where component knows only its minimal width/height
6:45:10
jackdaniel
so let's say, we call space-requirement-combine with only min-width set to 100
6:45:29
jackdaniel
with other space requirement, where min-width is 0, width is 1 and max-width is +fill+
6:46:02
jackdaniel
result of such combination is min-width=100, width=1, max-width=+fill+, what leads to assertion dropping us in the debugger
6:46:35
jackdaniel
imho this should be adjusted if these criteria can be met like: min-width=100, width=100, max-width=+fill+
6:46:49
jackdaniel
(because these space requirements are essentially compatible)
6:47:28
jackdaniel
or we could enforce that in the combine function
6:47:37
jackdaniel
either way, I don't think we should error on such occasions
8:04:58
beach
I agree. Space requirements, even max and min, can't always be honored.
8:05:13
loke
beach: had ttime to read it yet?
8:09:12
jackdaniel
honoring it (or not) is a different (however close) issue. I'm speaking about combining compatible space requirements (when you have requirement [0;10;100] and [20;*;120] then combination should be [20;20;100] (and not [20;10;100] what leads to an error) where [min;optimal;max]
8:11:34
jackdaniel
I've hit the problem when I've tried to specify only a min-width and min-height for text-pane (to be one-column/line-height size)
8:12:18
beach
loke: I don't see any problem with your proposed solution.
8:14:13
beach
jackdaniel: I see. It seems reasonable to me to always have (<= min size max).
8:14:32
jackdaniel
that combined with default space requirements yielded [min>0; 0; +fill+] which failed on assertion
8:14:51
beach
Yes, that's not so good.
8:14:55
jackdaniel
imho we should clamp width to min;max boundries instead of signalling the assertion
8:15:04
jackdaniel
asserting the relation*
Thursday, 20th of September 2018, 8:23:37 UTC