diff options
| author | Jeff Carr <[email protected]> | 2025-03-25 11:31:16 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-03-25 13:17:00 -0500 |
| commit | bf250b5ac6c13e721ee27c0ad138d43318dd5c5d (patch) | |
| tree | 95fb5d9f903ba989d64288198ab9d6991ffd5026 | |
| parent | aaebb4c5d993aafe8b290055296c9aaa1fb1ea93 (diff) | |
always make protobuf tables dense
| -rw-r--r-- | place.go | 12 |
1 files changed, 9 insertions, 3 deletions
@@ -167,6 +167,14 @@ func (tk *guiWidget) placeWidgets(startW int, startH int) (int, int) { return 0, 0 } +func (tk *guiWidget) isDense() bool { + if tk.node.InTable() { + return true + } + + return tk.isWindowDense() +} + func (tk *guiWidget) isWindowDense() bool { if tk.WidgetType() == widget.Window { return tk.window.dense @@ -193,8 +201,6 @@ func (w *guiWidget) placeGrid(startW int, startH int) (int, int) { return 0, 0 } - dense := w.isWindowDense() - w.full.w0 = startW w.full.h0 = startH @@ -209,7 +215,7 @@ func (w *guiWidget) placeGrid(startW int, startH int) (int, int) { if w.heights[child.GridH()] < childH { w.heights[child.GridH()] = childH } - if dense { + if child.isDense() { if w.heights[child.GridH()] > 0 { w.heights[child.GridH()] = 1 } else { |
