home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / sys / mac / programm / 14347 < prev    next >
Encoding:
Internet Message Format  |  1992-08-21  |  1.8 KB

  1. Path: sparky!uunet!usc!sdd.hp.com!elroy.jpl.nasa.gov!ames!agate!dog.ee.lbl.gov!network.ucsd.edu!ucsbcsl!mcl!scott
  2. From: scott@mcl.ucsb.edu (Scott Bronson)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: Re: CDEF question
  5. Message-ID: <scott.714443466@mcl>
  6. Date: 22 Aug 92 00:31:06 GMT
  7. References: <1992Aug5.002604.10741@samba.oit.unc.edu> <1992Aug5.175619.4425@ctr.columbia.edu>
  8. Sender: root@ucsbcsl.ucsb.edu
  9. Lines: 31
  10.  
  11. >>I am looking for a CDEF for the up/down arrow control that is used in
  12. >>the Color picker.  ... (the control makes an integer step
  13. >>up and down in set increments.) 
  14.  
  15. >I don't think it's a CDEF.  The PICT for the up/down arrow is in the
  16. >System as ID -5760.  Just put the PICT in your dialog, and when somebody
  17. >clicks on it, compare the mouse down point with the PICT's rectangle to
  18. >see if they clicked on the top half or the bottom half, and then take the
  19. >appropriate action.
  20.  
  21. Rather than using the system's PICT in your dialog (would you bet the
  22. future of your program on whether or not Apple is going to leave that
  23. PICT for all future systems--that's not a good bet) you should copy
  24. the PICT into your application's resource fork (it's small) and give
  25. it an ID greater than 127.
  26.  
  27. This gives me a great idea for a CDEF: make a complete number entry
  28. control.  Use TextEdit, and have the control make sure the number is
  29. valid.  The value of the control is the number in the text box.
  30. Everything else is automatic.  Should be relatively easy, too.  I'd
  31. do it, but I have no need for one right now.
  32.  
  33. >+------------------------------------+
  34. >| Bonus question:  Which of these    |
  35. >|   two statements is correct?       |
  36. >|     A) Statement "B" is false.     |
  37. >|     B) Statement "A" is true.      |
  38. >+------------------------------------+
  39.  
  40. Bonus question II:  Their are three errs in this sentence.  Can you find them?
  41.  
  42.