home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / lang / lisp / mcl / 1665 < prev    next >
Encoding:
Text File  |  1992-11-23  |  1.4 KB  |  46 lines

  1. Newsgroups: comp.lang.lisp.mcl
  2. Path: sparky!uunet!spool.mu.edu!agate!boulder!cambridge.apple.com!apple!usc!zaphod.mps.ohio-state.edu!darwin.sura.net!haven.umd.edu!mimsy!waander
  3. From: waander@cs.umd.edu (Bill Andersen)
  4. Subject: Basic color use in MCL
  5. Message-ID: <722536029.19873@news.Colorado.EDU>
  6. Lines: 30
  7. Sender: news
  8. Organization: U of Maryland, Dept. of Computer Science, Coll. Pk., MD 20742
  9. Distribution: co
  10. Date: 22 Nov 92 08:59:04 GMT
  11. Approved: news
  12. X-Note1: mail msgid was <62256@mimsy.umd.edu>
  13. X-Note2: message-id generated by recnews
  14. Lines: 30
  15.  
  16.  
  17.   I just want to draw some stuff in a view in various colors.  I have
  18. an application with a bunch of subviews inside a view inside a window.
  19. The stuff I want to draw is in the innermost subviews...
  20.  
  21.   I tried the following....
  22.  
  23. (defclass my-view (view) ())
  24.  
  25. (defmethod view-draw-contents ((self my-view))
  26.   (with-focused-view self ; maybe this is redundant
  27.     (with-fore-color *fancy-color*
  28.       (with-pstrs ((str "Hello!"))
  29.         (#_DrawString str)))))
  30.  
  31.   But the string just gets drawn in the default foreground
  32. color of the outermost window.  What's the deal?  Could someone
  33. supply some examples of how to do stuff with colors??  Maybe
  34. post it to the archive????
  35.  
  36.   Thanks...
  37.  
  38.  
  39.   ...bill
  40.  
  41. -- 
  42.    / Bill Andersen (waander@cs.umd.edu) /
  43.   / University of Maryland             /
  44.  / Department of Computer Science     /
  45. / College Park, Maryland  20742      /
  46.