NSTabViewItem.inc 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. { Parsed from AppKit.framework NSTabViewItem.h }
  2. {$ifdef TYPES}
  3. type
  4. NSTabViewItemPtr = ^NSTabViewItem;
  5. {$endif}
  6. {$ifdef TYPES}
  7. type
  8. NSTabState = NSUInteger;
  9. NSTabStatePtr = ^NSTabState;
  10. const
  11. NSSelectedTab = 0;
  12. NSBackgroundTab = 1;
  13. NSPressedTab = 2;
  14. {$endif}
  15. {$ifdef CLASSES}
  16. type
  17. NSTabViewItem = objcclass external (NSObject, NSCodingProtocol)
  18. private
  19. _identifier: id;
  20. __label: NSString;
  21. _view: NSView;
  22. __initialFirstResponder: NSView;
  23. __color: NSColor;
  24. _tabView: NSTabView;
  25. _tabState: NSTabState;
  26. _lastKeyView: NSView;
  27. _tviFlags: bitpacked record
  28. case byte of
  29. 0: (_anonBitField__tviFlags0: cuint);
  30. 1: (
  31. hasCustomColor: 0..1;
  32. labelSizeIsValid: 0..1;
  33. autoGeneratedIFR: 0..1;
  34. isTabDisabled: 0..1;
  35. isActive: 0..1;
  36. RESERVED: 0..((1 shl 27)-1);
  37. );
  38. end;
  39. _labelSize: NSSize;
  40. _tabRect: NSRect;
  41. _tabToolTipTag: NSToolTipTag;
  42. _auxiliaryStorage: id;
  43. public
  44. class function tabViewItemWithViewController (viewController: NSViewController): instancetype; message 'tabViewItemWithViewController:'; { available in 10_10 }
  45. function initWithIdentifier (identifier: id): instancetype; message 'initWithIdentifier:';
  46. procedure setIdentifier(newValue: id); message 'setIdentifier:';
  47. function identifier: id; message 'identifier';
  48. procedure setColor(newValue: NSColor); message 'setColor:';
  49. function color: NSColor; message 'color';
  50. procedure setLabel(newValue: NSString); message 'setLabel:';
  51. function label_: NSString; message 'label';
  52. procedure setImage(newValue: NSImage); message 'setImage:';
  53. function image: NSImage; message 'image';
  54. procedure setView(newValue: NSView); message 'setView:';
  55. function view: NSView; message 'view';
  56. procedure setViewController(newValue: NSViewController); message 'setViewController:';
  57. function viewController: NSViewController; message 'viewController';
  58. function tabState: NSTabState; message 'tabState';
  59. function tabView: NSTabView; message 'tabView';
  60. procedure setInitialFirstResponder(newValue: NSView); message 'setInitialFirstResponder:';
  61. function initialFirstResponder: NSView; message 'initialFirstResponder';
  62. procedure setToolTip(newValue: NSString); message 'setToolTip:';
  63. function toolTip: NSString; message 'toolTip';
  64. procedure drawLabel_inRect (shouldTruncateLabel: ObjCBOOL; labelRect: NSRect); message 'drawLabel:inRect:';
  65. function sizeOfLabel (computeMin: ObjCBOOL): NSSize; message 'sizeOfLabel:';
  66. { Adopted protocols }
  67. procedure encodeWithCoder (aCoder: NSCoder); message 'encodeWithCoder:';
  68. function initWithCoder (aDecoder: NSCoder): id; message 'initWithCoder:';
  69. end;
  70. {$endif}