summaryrefslogtreecommitdiff
path: root/view.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-02-09 04:03:48 -0600
committerJeff Carr <[email protected]>2025-02-09 04:03:48 -0600
commit955afcb1a98c87dfd51182fa03a25b8ad6495254 (patch)
treeb04fe2a58148a74331301fc6c87bf9278888dc67 /view.go
parentaf3fec6f2073b2d184c2f7ecb10d24658ad2970c (diff)
text boxes are forced 5 spaces wide
Diffstat (limited to 'view.go')
-rw-r--r--view.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/view.go b/view.go
index b518d59..d9ec8a6 100644
--- a/view.go
+++ b/view.go
@@ -23,6 +23,13 @@ func (tk *guiWidget) textResize() {
h += 1
}
+ // todo: fix all this old code
+ if tk.node.WidgetType == widget.Textbox {
+ if w < 5 {
+ w = 5
+ }
+ }
+
// this is old code. now move this somewhere smarter
tk.gocuiSize.w1 = tk.gocuiSize.w0 + w + me.FramePadW // TODO: move this FramePadW out of here
tk.gocuiSize.h1 = tk.gocuiSize.h0 + h + me.FramePadH // TODO: fix this size computation