[comp.windows.x] window dump WITH menus

davids@gdfwc3 (David Reed Smith) (05/30/91)

I am looking for an X application that will allow me to dump the image
of a window WITH it's menus displayed.  I have read the FAQ for
comp.windows.x (and retrieved xsnap, xgrabsc, and PBMPLUS) but I can't
seem to figure out how to get the image of a window with it's menus
displayed.

Is this possible?  If so, with what tool and how?

Thank you.

--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
David Smith					davids@gdfwc3,
General Dynamics,	 			gdfwc3!davids@central.sun.com,
Fort Worth Division				or uunet!texsun!gdfwc3!davids
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

cristy@eplrx7.uucp (John Cristy) (05/30/91)

Try import or XtoPS from contrib/ImageMagick.tar.Z on
export.lcs.mit.edu.  They have a '-screen' option where you can obtain
pieces of other windows that overlap the specified window, and more
importantly, you can capture menus or other popups that are independent
windows but appear over the specified window.

cristy@dupont.com
--
The UUCP Mailer

ddavey@kiwi.uucp (Doug Davey) (06/04/91)

The key that unlocked capturing screen images with pulldown menus for me
was setting the "saveUnder" resource to False.  (Thanks for the tip Andrew.)

For example:
1) Kick off your X application as follows:
   yourxapp -xrm "*saveUnder: False"

2) Then use xlswins to find the window id that you want.
   In this example we will use: 0x30016d

3) Then use sleep and xwd to dump the window.
   sleep 10 ; xwd -id 0x30016d >foo.xwd

While the sleep is counting down, pull down the menu in your application,
keep the menu pulled down, and smile.

If you have ever taken a picture of yourself with a timer on a camera,
this should all feel familiar.  :-)  Hope this helps.
-- 
------------------------------------------------------------------------
  Doug Davey   bellcore!bae!ddavey   ddavey@bae.bellcore.com

davids@gdfwc3 (David Reed Smith) (06/07/91)

In article <1991Jun4.023017.10894@bellcore.bellcore.com> ddavey@kiwi.uucp (Doug Davey) writes:

   Path: gdfwc3!jassys!egsner!convex!uunet!bellcore!kiwi!ddavey
   From: ddavey@kiwi.uucp (Doug Davey)
   Newsgroups: comp.windows.x
   Date: 4 Jun 91 02:30:17 GMT
   References: <DAVIDS.91May29143459@nimitz.gdfwc3>

   The key that unlocked capturing screen images with pulldown menus for me
   was setting the "saveUnder" resource to False.  (Thanks for the tip Andrew.)

   For example:
   1) Kick off your X application as follows:
      yourxapp -xrm "*saveUnder: False"

   2) Then use xlswins to find the window id that you want.
      In this example we will use: 0x30016d

   3) Then use sleep and xwd to dump the window.
      sleep 10 ; xwd -id 0x30016d >foo.xwd

   While the sleep is counting down, pull down the menu in your application,
   keep the menu pulled down, and smile.

   ------------------------------------------------------------------------
     Doug Davey   bellcore!bae!ddavey   ddavey@bae.bellcore.com

Thanks Doug (and everyone else) for the info.  Doug's article brings
up an annoying bug/feature in xwd.  You can use the '-id' option, or
the '-frame' option, but not both.  That is, both

xwd -frame -id 0xID > foo.xwd
xwd -id 0xID -frame > foo.xwd

Will get the correct window but without the frame.  This happens to me
on a Sun 3/50 and on a SGI 4D/20.  Comments, solutions, denials? ...
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
David Smith					davids@gdfwc3,
General Dynamics,	 			gdfwc3!davids@central.sun.com,
Fort Worth Division				or uunet!texsun!gdfwc3!davids
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~