home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 3 / AACD03.BIN / AACD / Programming / ClassFree / CFbuttonclass / CFbutton.doc next >
Text File  |  1998-06-09  |  2KB  |  88 lines

  1. Class:                  CFbuttonclass
  2. Author:                 Anders E. Andersen <andersa@fys.ku.dk>
  3. Superclass:             gadgetclass
  4. Desciption:             GadTools button gadget replacement
  5. Include File:           "CDbutton.h"
  6.  
  7.  
  8.  
  9. New Methods:
  10. ------------
  11.  
  12. None
  13.  
  14.  
  15. Changed Methods:
  16. ----------------
  17.  
  18. GM_HITTEST - Allways returns GMR_GADGETHIT
  19.  
  20. GM_GOACTIVE - Sets gadget flag GFLG_SELECTED, renders
  21. gadget and returns GMR_MEACTIVE.
  22.  
  23. GM_HANDLEINPUT - Handles gadget rendering according to
  24. mouse movements, checks for gadget abort in two ways,
  25. MENUDOWN and SELECTUP with mousepointer outside gadget.
  26. Also checks for GACT_RELVERIFY to see if IDCMP_GADGETUP
  27. should be sent.
  28.  
  29.  
  30. GM_GOINACTIVE - If GFLG_SELECTED is set, it clears it
  31. and renders the gadget.
  32.  
  33.  
  34. Attributes:
  35. -----------
  36.  
  37.  All attributes are passed directly to gadgetclass. The
  38. following attributes are used by CFbuttonclass:
  39.  
  40. GA_Left, GA_Top, GA_Width, GA_Height
  41.  
  42.  Positions and sizes the button.
  43.  
  44.  
  45. GA_Text
  46.  
  47.  NULL terminated C string. Automatically centered, truncated
  48. (if needed) and displayed.
  49.  
  50.  
  51. GA_RelVerify
  52.  
  53.  Determines if IDCMP_GADGETUP messages should be sent.
  54.  
  55.  
  56. CFBU_Textposflags
  57.  
  58.  Excepts position flags to determine how text should be
  59. positioned inside the button. 'Or' the flags together.
  60.  The accepted flags are:
  61.  
  62.  POS_CENTER    - No flags set, text is centered. DEFAULT.
  63.  POS_HORLEFT   - Text is positioned as far to the left as
  64.                   possible.
  65.  POS_HORRIGHT  - As far to the right as posible.
  66.  POS_VERTOP    - Position as far to the top of the
  67.                   button as possible.
  68.  POS_VERBOTTOM - Position text in the bottom of the gadget.
  69.  
  70.  POS_HORLEFT and POS_VERTOP takes precedence over
  71.   POS_HORRIGHT and POS_VERBOTTOM.
  72.  
  73. CFBU_Imageposflags
  74.  
  75.  Has the same meaning for gadget images as flags as
  76. CFBU_Textposflags has for gadgettext.
  77.  (But it doesn't work, because CFbuttonclass can't handle
  78. images yet..)
  79.  
  80.  
  81. CFBU_Textrestraint
  82.  
  83.  Maximum lenght in pixels that the gadgettext can be.
  84. CFbuttonclass cuts the gadget text string in case it would
  85. display outside the bounds of this attribute.
  86.  Defaults to a reasonable value within the bounds of the
  87. gadget.
  88.