From b9c8218ca4ce03c9cad338141946c32acedc47e5 Mon Sep 17 00:00:00 2001 From: vsariola <5684185+vsariola@users.noreply.github.com> Date: Thu, 11 Feb 2021 10:58:41 +0200 Subject: [PATCH] fix(tracker): numeric up down crashed when its height was small --- tracker/numericupdown.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tracker/numericupdown.go b/tracker/numericupdown.go index 8f42c77..52585c5 100644 --- a/tracker/numericupdown.go +++ b/tracker/numericupdown.go @@ -119,6 +119,9 @@ func (s NumericUpDownStyle) button(height int, icon *widget.Icon, delta int, cli if height < size { size = height } + if size < 1 { + size = 1 + } if icon != nil { icon.Color = s.IconColor return icon.Layout(gtx, unit.Px(float32(size)))