From 47b7dc5ccd77bc247ab15cfab3a7a8f955771c70 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Igor=20B=C3=B6hm?= Date: Tue, 4 Jan 2022 19:11:07 +0000 Subject: acme: fix window and scrollbar display glitches at bottom fringe of column MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The following patch fixes acme display glitches at the bottom fringe of columns when adding/moving/resizing windows. Here an example of an easy to reproduce case: • https://invidio.xamh.de/watch?v=iLekQrxycaM …opening acme and resizing a column to the right is all that is needed. The functions winresize(…) and textresize(…) are extended with an additional parameter `fillfringe` to indicate if a window/tag shall fill a potential fringe area that would otherwise remain white. The changes have been inspired by the approach taken in plan9port acme. --- sys/src/cmd/acme/dat.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'sys/src/cmd/acme/dat.h') diff --git a/sys/src/cmd/acme/dat.h b/sys/src/cmd/acme/dat.h index dfdb2413c..1c1a57572 100644 --- a/sys/src/cmd/acme/dat.h +++ b/sys/src/cmd/acme/dat.h @@ -213,7 +213,7 @@ uint textload(Text*, uint, char*, int); Rune textreadc(Text*, uint); void textredraw(Text*, Rectangle, Font*, Image*, int); void textreset(Text*); -int textresize(Text*, Rectangle); +int textresize(Text*, Rectangle, int); void textscrdraw(Text*); void textscroll(Text*, int); void textselect(Text*); @@ -245,7 +245,6 @@ struct Window uchar dirty; uchar indent[NINDENT]; uchar showdel; - uint noredraw; int id; Range addr; Range limit; @@ -290,7 +289,7 @@ void winsetname(Window*, Rune*, int); void winsettag(Window*); void winsettag1(Window*); void wincommit(Window*, Text*); -int winresize(Window*, Rectangle, int); +int winresize(Window*, Rectangle, int, int); void winclose(Window*); void windelete(Window*); int winclean(Window*, int); -- cgit v1.2.3