[comp.windows.x] How can I dump a LARGE window to a file?

tony@tui.marcam.dsir.govt.nz (Tony Cooper) (04/04/91)

xwd, xsnap, xgrabsc all dump windows to a file but they all suffer from
the problem that they only dump the part of a window that is visible on
the screen. I have also tried these programs under the two virtual
window managers tvtwm and vtwm and even then all that gets dumped is
the part of the window that is visible on the screen.

I would like to dump a window that is larger than my screen and I want
all the window, not just the part that is visible on the screen. Any
ideas?

Thanks,
Tony Cooper
sramtrc@albert.dsir.govt.nz

klee@wsl.dec.com (Ken Lee) (04/04/91)

In article <1991Apr4.012212.7135@am.dsir.govt.nz>, tony@tui.marcam.dsir.govt.nz (Tony Cooper) writes:
|> xwd, xsnap, xgrabsc all dump windows to a file but they all suffer from
|> the problem that they only dump the part of a window that is visible on
|> the screen.

Unless you have backing store on, the contents of the not visible parts
of a window are undefined.

-- 
Ken Lee
DEC Western Software Laboratory, Palo Alto, Calif.
Internet: klee@wsl.dec.com
uucp: uunet!decwrl!klee

garyo@think.com (Gary Oberbrunner) (04/04/91)

In article <1991Apr3.175607@wsl.dec.com> klee@wsl.dec.com (Ken Lee) writes:

   In article <1991Apr4.012212.7135@am.dsir.govt.nz>, tony@tui.marcam.dsir.govt.nz (Tony Cooper) writes:
   |> xwd, xsnap, xgrabsc all dump windows to a file but they all suffer from
   |> the problem that they only dump the part of a window that is visible on
   |> the screen.

   Unless you have backing store on, the contents of the not visible parts
   of a window are undefined.

   -- 
   Ken Lee
   DEC Western Software Laboratory, Palo Alto, Calif.
   Internet: klee@wsl.dec.com
   uucp: uunet!decwrl!klee

You could, of course, write a window dump program that put the target
window on top, snarfed as much as was visible, then moved the target window
around (and allowed it to do whatever expose processing it was going to do)
taking snapshots and compositing them together to form an image of what the
whole window would look like if it were all visible.  True, it wouldn't
work in all cases (especially if the display is dynamic in any way), but it
would work for most sensible cases.

				- Gary Oberbrunner
				Thinking Machines Corporation
				245 First St
				Cambridge, MA 02142
				garyo@think.com

steven@pacific.csl.uiuc.edu (Steven Parkes) (04/05/91)

|> You could, of course, write a window dump program that put the target
|> window on top, snarfed as much as was visible, then moved the target window
|> around (and allowed it to do whatever expose processing it was going to do)
|> taking snapshots and compositing them together to form an image of what the
|> whole window would look like if it were all visible.

Shades of how Daisy printed schematics

mouse@lightning.mcrcim.mcgill.EDU (der Mouse) (04/07/91)

>>> xwd, xsnap, xgrabsc all dump windows to a file but they all suffer
>>> from the problem that they only dump the part of a window that is
>>> visible on the screen.
>> Unless you have backing store on, the contents of the not visible
>> parts of a window are undefined.
> You could, of course, write a window dump program that put the target
> window on top, snarfed as much as was visible, then moved the target
> window around (and allowed it to do whatever expose processing it was
> going to do)

Except that there's no way for the snapshot program to tell when the
client program is finished doing expose processing.  (Aside from all
the other objections - for example, the window manager may not let you
raise the window all the way to the top; at least some versions tvtwm
won't let you raise it above sticky windows, for example.)

					der Mouse

			old: mcgill-vision!mouse
			new: mouse@larry.mcrcim.mcgill.edu