diff --git a/pd/nw/pdgui.js b/pd/nw/pdgui.js
index e91e9fae7fee6ac984f601bb554eac7f6f8633a2..b9d3e4d1290495860a547bda90e55944f5374654 100644
--- a/pd/nw/pdgui.js
+++ b/pd/nw/pdgui.js
@@ -6119,7 +6119,7 @@ function gui_textarea(cid, tag, type, x, y, width_spec, height_spec, text,
                     (width_spec < 0 ? (-width_spec) - 2 + "px" : width_spec + "ch")));
 
         if (is_gop == 1) {
-            p.style.setProperty("min-height", height_spec - 5 + "px");
+            p.style.setProperty("min-height", height_spec - 4 + "px");
         }
         // set backgroundimage for message box
         if (type === "msg") {