This patch implements subwindow clipping as per Stephen Turnbull's
suggestion. I'm hoping this will nuke the endless tab redisplay problems so
am recommiting the tabs sync. Let me know if this does not fix the problems.
I will apply this to cvs.
andy
1999-09-13 Andy Piper <andy(a)xemacs.org>
* xlwtabs.c: Put in tabs sync because clipping should fix useability
problems.
1999-09-16 Andy Piper <andy(a)xemacs.org>
* redisplay-output.c (redisplay_output_subwindow): clip subwindows
that don't completely fit on-screen rather than just unmapping
them.
* glyphs.h: change signature of map_subwindow.
* glyphs.c (map_subwindow): add display_glyph_area to the
signature. make sure the mapped area saved in the subwindow_cachel
reflects this.
(Fforce_subwindow_map): make a no-op. I don't think this does
anything useful.
* glyphs-x.h (struct x_subwindow_data): save the Display rather
than the Screen. Add a clipwindow and clipwidget handle.
(IMAGE_INSTANCE_X_CLIPWINDOW): new accessor.
(IMAGE_INSTANCE_X_CLIPWIDGET): ditto.
(XIMAGE_INSTANCE_X_CLIPWIDGET): ditto.
(XIMAGE_INSTANCE_X_CLIPWINDOW): ditto.
* glyphs-x.c (x_finalize_image_instance): destroy the clipwidget
as well as the widget itself.
(x_unmap_subwindow): unmap the clipwindow and clipwidget rather
than the widgets and subwindows themselves. move the widget inside
the clipwidget.
(x_subwindow_instantiate): hold onto the Display rather than the
Screen. allocate a clipwindow to put the subwindow inside.
(x_resize_subwindow): use saved Display directly.
(x_widget_instantiate): allocate a clipwidget of type EmacsManager
to put widgets inside.
* glyphs-widget.c: remove group stuff.
* glyphs-msw.h (struct mswindows_subwindow_data): new structure to
hold the clipwindow.
(IMAGE_INSTANCE_MSWINDOWS_CLIPWINDOW): new accessor.
(XIMAGE_INSTANCE_MSWINDOWS_CLIPWINDOW): ditto.
* glyphs-msw.c: remove group stuff.
(mswindows_finalize_image_instance): destroy clipwindow as well as
the widget itself.
(mswindows_unmap_subwindow): unmap the clipwindow rather than the
widget.
(mswindows_map_subwindow): ditto. move the widget within the
clipwindow.
(mswindows_subwindow_instantiate): allocate and initialize
mswindows_subwindow_data. allocate a clipwindow with the subwindow
as a child.
(mswindows_widget_instantiate): ditto.
(mswindows_control_wnd_proc): new function that allows us to
propagate events from the widget to the main windows control loop.
* device-msw.c (mswindows_init_device): register new widget clip window
class.
* console.h (struct console_methods): add display_glyph_area to
map_window.
* console-msw.h: declare new window class and wnd proc for
widgets.
--------------------------------------------------------------
Dr Andy Piper
Senior Consultant Architect, BEA Systems Ltd