This week only. Pastebin PRO Accounts Christmas Special! Don't miss out!Want more features on Pastebin? Sign Up, it's FREE!
Guest

Looking for info on custom drawing of interface components (Cocoa)

By: a guest on Feb 27th, 2012  |  syntax: None  |  size: 0.31 KB  |  views: 16  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. + (Class) cellClass
  2. {
  3.     return [OurButtonCell class];
  4. }
  5.  
  6. - (void)drawRect:(NSRect)rect
  7. {
  8.     // first get the cell to draw inside our bounds
  9.     // then draw a focus ring if that's appropriate
  10. }
  11.        
  12. - (void)drawInteriorWithFrame: (NSRect) rect inView: (NSView *) controlView
  13. {
  14.     // a bunch of drawing code
  15. }
clone this paste RAW Paste Data