shithub: patch

Download patch

ref: 801c6e1167653f01779b5643a3e3870e2de56dee
parent: f0a44de6920f4fd1102fb67be08993504b691718
author: qwx <qwx@sciops.net>
date: Tue Apr 27 03:50:10 EDT 2021

swedish samterm: fix minimum window dimensions too small

this prevents a lockup.  vanilla samterm is even more conservative,
but it might make more sense to base the minimum on font dimensions.

--- a/samterm-fullfrontalnudity
+++ b/samterm-fullfrontalnudity
@@ -103,7 +103,7 @@
 +	*r = getrect(3, mousectl);
 +	if(eqrect(*r, Rect(0,0,0,0)))
 +		return 0;
-+	if(Dx(*r) < 5 && Dy(*r) < 5)
++	if(Dx(*r) < 8*font->width && Dy(*r) < 2*font->height)
 +		*r = inflatepoint(r->min);
 +	if(rectclip(r, screen->r) == 0)
 +		*r = defaultrect();