Relates :
|
|
Relates :
|
|
Relates :
|
|
Relates :
|
Baseline offset calculation in Node depends on layout bounds which are calculated during layout for resizable nodes. This creates cyclic dependency - because the value of baseline offset is used during layout. This may lead to some strange situations e.g. in the first layout pass, the baseline offset of child is 0 (the child hasn't been laid out yet). During the layout pass, the height of the child is calculated which changes baseline offset. In the next pass, the baseline offset is not 0 anymore and this can lead to different layout - now the calculated height of the child may be different -> baseline offset is different again and the layout will again be different in subsequent layout pass etc. Current proposal is to use new symbolic constant (-1 or -Infinity, or NaN) for baseline offset of resizable nodes which currently use layout bounds. The constant would have similar meaning as USE_COMPUTED_SIZE in Region. The actual baseline offset would be calculated during layout pass. Of course, the baseline offset of nodes which can calculate it from their properties (Label etc.) should do so (and they already do), this only applies to resizable nodes which don't have a proper way to calculate it and fall back to implementation in Node.
|