diff options
Diffstat (limited to 'size.go')
| -rw-r--r-- | size.go | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -76,7 +76,7 @@ func (tk *guiWidget) Size() (int, int) { case widget.Label: return len(tk.String()) + 2, 1 case widget.Textbox: - return len(tk.String()) + 2, 3 // TODO: compute this based on 'window dense' + return len(tk.String()) + 10, 3 // TODO: compute this based on 'window dense' case widget.Checkbox: return len(tk.String()) + 2, 3 // TODO: compute this based on 'window dense' } @@ -341,9 +341,13 @@ func (tk *guiWidget) getFullSize() rectType { // the full size is exactly what gocui uses switch tk.node.WidgetType { case widget.Label: - return tk.buttonFullSize() + r := tk.buttonFullSize() + r.w1 += 5 + return r case widget.Button: - return tk.buttonFullSize() + r := tk.buttonFullSize() + r.w1 += 5 + return r case widget.Checkbox: return tk.buttonFullSize() case widget.Dropdown: |
