home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / windows / x / 19195 < prev    next >
Encoding:
Internet Message Format  |  1992-11-16  |  1.5 KB

  1. Path: sparky!uunet!think.com!ames!agate!dog.ee.lbl.gov!epb11.lbl.gov!envbvs
  2. From: envbvs@epb11.lbl.gov (Brian V. Smith)
  3. Newsgroups: comp.windows.x
  4. Subject: Re: Updating pixmaps in label widgets
  5. Date: 16 Nov 1992 19:02:08 GMT
  6. Organization: lbl
  7. Lines: 23
  8. Distribution: world
  9. Message-ID: <27481@dog.ee.lbl.gov>
  10. References: <9211131740.AA00262@spike.ora.com>
  11. NNTP-Posting-Host: 128.3.12.123
  12.  
  13. In article <9211131740.AA00262@spike.ora.com>, adrian@ora.COM (adrian) writes:
  14. |> 
  15. |> Someone asked a few days ago how to make a Label widget redraw its
  16. |> pixmap.  The problem comes up when you want the Label widget to
  17. |> display a pixmap that is changing.  Since the pixmap ID remains
  18. |> constant, there is no way for the widget to know the pixmap has
  19. |> been written to.
  20.  
  21. This is a problem that keeps coming up in xfig.  I assumed that the Intrinsics
  22. would know that an XSetValues() call to set the pixmap of the widget should 
  23. send the widget an expose event, but it doesn't.  My solution was to call
  24. XSetValues twice, once with backgroundPixmap ID of 0 then with the correct ID.
  25.  
  26. The very strange thing is that the top and side rulers work excatly the same
  27. way (a pixmap in a label widget), but only in version 2.1.5 does the problem
  28. that the pixmap doesn't get updated occur, and ONLY in the side ruler.  The
  29. top ruler and side ruler code is virtually identical, but only one exhibits
  30. the problem.  
  31.  
  32. -- 
  33. Brian V. Smith    (bvsmith@lbl.gov)
  34. Lawrence Berkeley Laboratory
  35. I don't speak for LBL; they don't pay me enough for that.
  36.