home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / windows / x / 19427 < prev    next >
Encoding:
Text File  |  1992-11-20  |  1.6 KB  |  43 lines

  1. Newsgroups: comp.windows.x
  2. Path: sparky!uunet!haven.umd.edu!darwin.sura.net!spool.mu.edu!umn.edu!csus.edu!netcom.com!netcomsv!dlb!shawn!root
  3. From: root@shawn.uucp (Mark Jeghers -- UNIX/X/Motif Contractor)
  4. Subject: Re: XGetImage question
  5. Message-ID: <1992Nov21.074030.497@shawn.uucp>
  6. Organization: Mark Jeghers -- UNIX/X/Motif Contractor
  7. References: <1992Nov20.194122.854@elroy.jpl.nasa.gov>
  8. Date: Sat, 21 Nov 92 07:40:30 GMT
  9. Lines: 32
  10.  
  11. paul@elroy.Jpl.Nasa.Gov (Paul Asmar) writes:
  12.  
  13. >I am using XGetImage() to extract the pixmap of window which I am going
  14.                                        ^^^^^^?
  15.                                                I assume you mean "XImage"
  16.  
  17. >to convert to other formats (like Postscript for example).  However,
  18. >when the window is not completely visible, the unvisible parts have garbage
  19. >when using XGetImage().
  20.  
  21. Yes, this is the classic problem.  You cannot capture what does not exist.
  22. When you grab from a window, you essentially grab a region of your frame
  23. buffer (including overlap from other windows sometimes).
  24.  
  25. >I tried turning on backing store via XChangeWindowAttributes(), but that
  26. >didn't help much.
  27.  
  28. Backing store may save what you draw, but it's save *off* the screen,
  29. you are still capturing what is *on* the screen.  This is why it does
  30. not help.  Even if it did, backing store is not a portable bet.
  31.  
  32. >Is there a way
  33. >to extract the contents of window regardless of its visibility status?
  34.  
  35. No.  You must make the entire window *visible*.  Screen capture is
  36. literally that: the capture of the *screen*.  Sorry I can't give you
  37. a more elegant answer...
  38.  
  39. Mark Jeghers
  40. X/Motif Contractor
  41. 408/281-4823 [voicemail]
  42.  
  43.