[comp.windows.x] R3/R4 twm zooming is quite broken

iand@labtam.oz (Ian Donaldson) (03/06/90)

Abstract:
	The 'Zoom' feature of twm is very broken and may draw garbage
	in unexpected places when opening/closing icons/windows.

	In addition, garbage may be left on windows that are actively
	drawing things (eg: a scrolling xterm)
Repeat-By:
	set 'Zoom 5000' in your '.twmrc' and then run twm.  Start
	an xterm and then iconify it.

	Note that during the iconify process, nothing visible happens
	except for a flashing border of the window for quite a few seconds, 
	then suddenly the window is iconified: 
	
	This is due to dx/dy being zero in the Zoom() routine in twm.
	All lines are drawn on top of each other.
		
	Set 'Zoom 500' in your .twmrc, then then run twm.  Start
	and xterm and then iconfiy it.

	Note that the zooming process doesn't necessarily draw consistent
	rectangles from the window to the icon.  The rectangles don't
	get drawn across the root background to the icon either.  They
	only get drawn in the window.

	Set 'Zoom 50' in your .twmrc, then then run twm.  Start
	and xterm and then iconfiy it.

	If you have a scrolling xterm in the middle of the screen
	and you close a window whereby the icon is on the left
	of this xterm and the window is on the right, then garbage
	is drawn on the xterm and it then scrolls up.

	A window refresh is needed to fix it.
	Presumably, twm should grab the server for the duration of
	the zoom so that xterm isn't scribbled on permanently.

	Look at the code in Zoom() in "util.c" in the twm source to see
	why all this happens.  It uses integer arithmetic and the
	algorithm is quite wrong for all but a few common cases.

Work-Around:
	Do a refresh when it mucks the screen up.