summaryrefslogtreecommitdiff
path: root/redo/textfield_darwin.go
diff options
context:
space:
mode:
Diffstat (limited to 'redo/textfield_darwin.go')
-rw-r--r--redo/textfield_darwin.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/redo/textfield_darwin.go b/redo/textfield_darwin.go
index cbe5f8b..89711d4 100644
--- a/redo/textfield_darwin.go
+++ b/redo/textfield_darwin.go
@@ -81,7 +81,9 @@ func (t *textfield) allocate(x int, y int, width int, height int, d *sizing) []*
}
func (t *textfield) preferredSize(d *sizing) (width, height int) {
- return basepreferredSize(t, d)
+ _, height = basepreferredSize(t, d)
+ // the returned width is based on the contents; use this instead
+ return C.textfieldWidth, height
}
func (t *textfield) commitResize(a *allocation, d *sizing) {