summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorChristian Kolset <christian.kolset@gmail.com>2026-06-03 16:17:58 -0600
committerChristian Kolset <christian.kolset@gmail.com>2026-06-03 16:17:58 -0600
commit903df67b153ca4af877ba0b534d4802d74cf34df (patch)
tree9f0dcef93bf87979b7168d2c3f94fd395effc03a /core
parent216a278102e3f63f155d76d62790a3ca60fcec02 (diff)
Equalize tile sizes after every BSP tree operation
After each drag-drop, add, or remove, walk the tree and reset each split's ratio to left_leaves/(left_leaves+right_leaves). This distributes space equally per pane regardless of the prior tree structure. - _tree_equalize_ratios: recomputes all ratios bottom-up by leaf count - _tree_leaf_count: counts leaves in a subtree - _tree_grid_size: uses LCM of split denominators (capped at 12) instead of 2^depth, giving exact integer rowspans for equal distributions - _tree_default: balanced binary tree + equalize (not uneven chain) - Applied in _do_drop, _add_pane, _rm Result: 3 side-by-side panes → equal widths; any mixed layout → equal area. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'core')
0 files changed, 0 insertions, 0 deletions