annotate dstep/appkit/NSButtonCell.d @ 16:19885b43130e

Huge update, the bridge actually works now
author Jacob Carlborg <doob@me.com>
date Sun, 03 Jan 2010 22:06:11 +0100
parents
children b9de51448c6b
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
16
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
1 /**
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
2 * Copyright: Copyright (c) 2009 Jacob Carlborg.
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
3 * Authors: Jacob Carlborg
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
4 * Version: Initial created: Sep 24, 2009
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
5 * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost Software License 1.0)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
6 */
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
7 module dstep.appkit.NSButtonCell;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
8
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
9 import dstep.appkit.NSActionCell;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
10 import dstep.appkit.NSAttributedString;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
11 import dstep.appkit.NSColor;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
12 import dstep.appkit.NSEvent;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
13 import dstep.appkit.NSFont;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
14 import dstep.appkit.NSImage;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
15 import dstep.appkit.NSSound;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
16 import dstep.appkit.NSView;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
17 import dstep.applicationservices.coregraphics.CGBase;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
18 import dstep.foundation.NSAttributedString;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
19 import dstep.foundation.NSGeometry;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
20 import dstep.foundation.NSObjCRuntime;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
21 import dstep.foundation.NSString;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
22 import dstep.objc.bridge.Bridge;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
23 import dstep.objc.objc;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
24
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
25 alias NSUInteger NSButtonType;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
26 alias NSUInteger NSBezelStyle;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
27 alias NSUInteger NSGradientType;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
28
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
29 enum
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
30 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
31 NSMomentaryLightButton = 0,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
32 NSPushOnPushOffButton = 1,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
33 NSToggleButton = 2,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
34 NSSwitchButton = 3,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
35 NSRadioButton = 4,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
36 NSMomentaryChangeButton = 5,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
37 NSOnOffButton = 6,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
38 NSMomentaryPushInButton = 7,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
39 NSMomentaryPushButton = 0,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
40 NSMomentaryLight = 7
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
41 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
42
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
43 enum
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
44 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
45 NSRoundedBezelStyle = 1,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
46 NSRegularSquareBezelStyle = 2,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
47 NSThickSquareBezelStyle = 3,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
48 NSThickerSquareBezelStyle = 4,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
49 NSDisclosureBezelStyle = 5,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
50 NSShadowlessSquareBezelStyle = 6,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
51 NSCircularBezelStyle = 7,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
52 NSTexturedSquareBezelStyle = 8,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
53 NSHelpButtonBezelStyle = 9,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
54 NSSmallSquareBezelStyle = 10,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
55 NSTexturedRoundedBezelStyle = 11,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
56 NSRoundRectBezelStyle = 12,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
57 NSRecessedBezelStyle = 13,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
58 NSRoundedDisclosureBezelStyle = 14,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
59 NSSmallIconButtonBezelStyle = 2
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
60 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
61
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
62 enum
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
63 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
64 NSGradientNone = 0,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
65 NSGradientConcaveWeak = 1,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
66 NSGradientConcaveStrong = 2,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
67 NSGradientConvexWeak = 3,
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
68 NSGradientConvexStrong = 4
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
69 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
70
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
71 struct _BCFlags
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
72 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
73 uint alternateMnemonicLocation;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
74 uint useButtonImageSource;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
75 uint gradientType;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
76 uint doesNotDimImage;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
77 uint inset;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
78 uint transparent;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
79 uint lastState;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
80 uint hasKeyEquivalentInsteadOfImage;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
81 uint imageSizeDiff;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
82 uint imageAndText;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
83 uint bottomOrLeft;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
84 uint horizontal;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
85 uint imageOverlaps;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
86 uint bordered;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
87 uint drawing;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
88 uint lightByGray;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
89 uint lightByBackground;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
90 uint lightByContents;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
91 uint changeGray;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
92 uint changeBackground;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
93 uint changeContents;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
94 uint pushIn;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
95 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
96
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
97
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
98 struct _BCFlags2
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
99 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
100 uint bezelStyle;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
101 uint showsBorderOnlyWhileMouseInside;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
102 uint mouseInside;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
103 uint bezelStyle2;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
104 uint imageScaling;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
105 uint keyEquivalentModifierMask;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
106 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
107
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
108 const TNSButtonCellExtensions = `
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
109
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
110 uint gradientType ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
111 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
112 return invokeObjcSelf!(uint, "gradientType");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
113 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
114
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
115 void setGradientType (uint type)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
116 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
117 return invokeObjcSelf!(void, "setGradientType:", uint)(type);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
118 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
119
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
120 void setImageDimsWhenDisabled (bool flag)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
121 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
122 return invokeObjcSelf!(void, "setImageDimsWhenDisabled:", bool)(flag);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
123 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
124
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
125 bool imageDimsWhenDisabled ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
126 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
127 return invokeObjcSelf!(bool, "imageDimsWhenDisabled");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
128 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
129
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
130 void setShowsBorderOnlyWhileMouseInside (bool show)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
131 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
132 return invokeObjcSelf!(void, "setShowsBorderOnlyWhileMouseInside:", bool)(show);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
133 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
134
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
135 bool showsBorderOnlyWhileMouseInside ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
136 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
137 return invokeObjcSelf!(bool, "showsBorderOnlyWhileMouseInside");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
138 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
139
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
140 void mouseEntered (NSEvent event)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
141 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
142 return invokeObjcSelf!(void, "mouseEntered:", NSEvent)(event);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
143 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
144
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
145 void mouseExited (NSEvent event)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
146 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
147 return invokeObjcSelf!(void, "mouseExited:", NSEvent)(event);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
148 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
149
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
150 NSColor backgroundColor ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
151 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
152 return invokeObjcSelf!(NSColor, "backgroundColor");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
153 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
154
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
155 void setBackgroundColor (NSColor color)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
156 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
157 return invokeObjcSelf!(void, "setBackgroundColor:", NSColor)(color);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
158 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
159
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
160 //mixin ObjcBindMethod!(gradientType, "gradientType");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
161 //mixin ObjcBindMethod!(setGradientType, "setGradientType:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
162 //mixin ObjcBindMethod!(setImageDimsWhenDisabled, "setImageDimsWhenDisabled:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
163 //mixin ObjcBindMethod!(imageDimsWhenDisabled, "imageDimsWhenDisabled");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
164 //mixin ObjcBindMethod!(setShowsBorderOnlyWhileMouseInside, "setShowsBorderOnlyWhileMouseInside:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
165 //mixin ObjcBindMethod!(showsBorderOnlyWhileMouseInside, "showsBorderOnlyWhileMouseInside");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
166 //mixin ObjcBindMethod!(mouseEntered, "mouseEntered:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
167 //mixin ObjcBindMethod!(mouseExited, "mouseExited:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
168 //mixin ObjcBindMethod!(backgroundColor, "backgroundColor");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
169 //mixin ObjcBindMethod!(setBackgroundColor, "setBackgroundColor:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
170
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
171 `;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
172
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
173 const TNSButtonCellBezelStyles = `
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
174
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
175 void setBezelStyle (uint bezelStyle)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
176 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
177 return invokeObjcSelf!(void, "setBezelStyle:", uint)(bezelStyle);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
178 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
179
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
180 uint bezelStyle ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
181 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
182 return invokeObjcSelf!(uint, "bezelStyle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
183 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
184
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
185 //mixin ObjcBindMethod!(setBezelStyle, "setBezelStyle:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
186 //mixin ObjcBindMethod!(bezelStyle, "bezelStyle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
187
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
188 `;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
189
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
190 const TNSButtonCellSoundExtensions = `
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
191
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
192 void setSound (NSSound aSound)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
193 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
194 return invokeObjcSelf!(void, "setSound:", NSSound)(aSound);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
195 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
196
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
197 NSSound sound ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
198 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
199 return invokeObjcSelf!(NSSound, "sound");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
200 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
201
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
202 //mixin ObjcBindMethod!(setSound, "setSound:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
203 //mixin ObjcBindMethod!(sound, "sound");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
204
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
205 `;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
206
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
207 const TNSButtonCellAttributedStringMethods = `
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
208
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
209 NSAttributedString attributedTitle ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
210 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
211 return invokeObjcSelf!(NSAttributedString, "attributedTitle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
212 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
213
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
214 void setAttributedTitle (NSAttributedString obj)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
215 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
216 return invokeObjcSelf!(void, "setAttributedTitle:", NSAttributedString)(obj);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
217 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
218
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
219 NSAttributedString attributedAlternateTitle ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
220 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
221 return invokeObjcSelf!(NSAttributedString, "attributedAlternateTitle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
222 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
223
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
224 void setAttributedAlternateTitle (NSAttributedString obj)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
225 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
226 return invokeObjcSelf!(void, "setAttributedAlternateTitle:", NSAttributedString)(obj);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
227 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
228
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
229 //mixin ObjcBindMethod!(attributedTitle, "attributedTitle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
230 //mixin ObjcBindMethod!(setAttributedTitle, "setAttributedTitle:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
231 //mixin ObjcBindMethod!(attributedAlternateTitle, "attributedAlternateTitle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
232 //mixin ObjcBindMethod!(setAttributedAlternateTitle, "setAttributedAlternateTitle:");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
233
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
234 `;
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
235
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
236 class NSButtonCell : NSActionCell
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
237 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
238 mixin (ObjcWrap);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
239
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
240 NSString title ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
241 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
242 return invokeObjcSelf!(NSString, "title");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
243 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
244
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
245 void setTitle (NSString aString)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
246 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
247 return invokeObjcSelf!(void, "setTitle:", NSString)(aString);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
248 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
249
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
250 NSString alternateTitle ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
251 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
252 return invokeObjcSelf!(NSString, "alternateTitle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
253 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
254
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
255 void setAlternateTitle (NSString aString)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
256 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
257 return invokeObjcSelf!(void, "setAlternateTitle:", NSString)(aString);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
258 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
259
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
260 NSImage alternateImage ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
261 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
262 return invokeObjcSelf!(NSImage, "alternateImage");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
263 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
264
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
265 void setAlternateImage (NSImage image)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
266 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
267 return invokeObjcSelf!(void, "setAlternateImage:", NSImage)(image);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
268 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
269
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
270 uint imagePosition ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
271 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
272 return invokeObjcSelf!(uint, "imagePosition");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
273 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
274
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
275 void setImagePosition (uint aPosition)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
276 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
277 return invokeObjcSelf!(void, "setImagePosition:", uint)(aPosition);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
278 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
279
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
280 uint imageScaling ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
281 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
282 return invokeObjcSelf!(uint, "imageScaling");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
283 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
284
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
285 void setImageScaling (uint scaling)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
286 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
287 return invokeObjcSelf!(void, "setImageScaling:", uint)(scaling);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
288 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
289
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
290 NSInteger highlightsBy ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
291 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
292 return invokeObjcSelf!(NSInteger, "highlightsBy");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
293 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
294
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
295 void setHighlightsBy (NSInteger aType)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
296 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
297 return invokeObjcSelf!(void, "setHighlightsBy:", NSInteger)(aType);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
298 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
299
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
300 NSInteger showsStateBy ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
301 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
302 return invokeObjcSelf!(NSInteger, "showsStateBy");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
303 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
304
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
305 void setShowsStateBy (NSInteger aType)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
306 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
307 return invokeObjcSelf!(void, "setShowsStateBy:", NSInteger)(aType);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
308 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
309
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
310 void setButtonType (uint aType)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
311 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
312 return invokeObjcSelf!(void, "setButtonType:", uint)(aType);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
313 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
314
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
315 bool isOpaque ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
316 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
317 return invokeObjcSelf!(bool, "isOpaque");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
318 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
319
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
320 void setFont (NSFont fontObj)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
321 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
322 return invokeObjcSelf!(void, "setFont:", NSFont)(fontObj);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
323 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
324
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
325 bool isTransparent ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
326 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
327 return invokeObjcSelf!(bool, "isTransparent");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
328 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
329
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
330 void setTransparent (bool flag)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
331 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
332 return invokeObjcSelf!(void, "setTransparent:", bool)(flag);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
333 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
334
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
335 void setPeriodicDelay (float delay, float interval)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
336 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
337 return invokeObjcSelf!(void, "setPeriodicDelay:interval:", float, float)(delay, interval);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
338 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
339
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
340 void getPeriodicDelay (float* delay, float* interval)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
341 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
342 return invokeObjcSelf!(void, "getPeriodicDelay:interval:", float*, float*)(delay, interval);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
343 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
344
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
345 NSString keyEquivalent ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
346 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
347 return invokeObjcSelf!(NSString, "keyEquivalent");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
348 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
349
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
350 void setKeyEquivalent (NSString aKeyEquivalent)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
351 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
352 return invokeObjcSelf!(void, "setKeyEquivalent:", NSString)(aKeyEquivalent);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
353 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
354
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
355 NSUInteger keyEquivalentModifierMask ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
356 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
357 return invokeObjcSelf!(NSUInteger, "keyEquivalentModifierMask");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
358 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
359
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
360 void setKeyEquivalentModifierMask (NSUInteger mask)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
361 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
362 return invokeObjcSelf!(void, "setKeyEquivalentModifierMask:", NSUInteger)(mask);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
363 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
364
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
365 NSFont keyEquivalentFont ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
366 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
367 return invokeObjcSelf!(NSFont, "keyEquivalentFont");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
368 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
369
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
370 void setKeyEquivalentFont (NSFont fontObj)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
371 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
372 return invokeObjcSelf!(void, "setKeyEquivalentFont:", NSFont)(fontObj);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
373 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
374
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
375 void setKeyEquivalentFont (NSString fontName, CGFloat fontSize)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
376 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
377 return invokeObjcSelf!(void, "setKeyEquivalentFont:size:", NSString, CGFloat)(fontName, fontSize);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
378 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
379
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
380 void performClick (Object sender)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
381 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
382 return invokeObjcSelf!(void, "performClick:", Object)(sender);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
383 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
384
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
385 void drawImage (NSImage image, NSRect frame, NSView controlView)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
386 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
387 return invokeObjcSelf!(void, "drawImage:withFrame:inView:", NSImage, NSRect, NSView)(image, frame, controlView);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
388 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
389
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
390 NSRect drawTitle (NSAttributedString title, NSRect frame, NSView controlView)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
391 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
392 return invokeObjcSelf!(NSRect, "drawTitle:withFrame:inView:", NSAttributedString, NSRect, NSView)(title, frame, controlView);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
393 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
394
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
395 void drawBezelWithFrame (NSRect frame, NSView controlView)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
396 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
397 return invokeObjcSelf!(void, "drawBezelWithFrame:inView:", NSRect, NSView)(frame, controlView);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
398 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
399
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
400 // NSButtonCellExtensions
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
401 uint gradientType ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
402 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
403 return invokeObjcSelf!(uint, "gradientType");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
404 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
405
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
406 void setGradientType (uint type)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
407 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
408 return invokeObjcSelf!(void, "setGradientType:", uint)(type);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
409 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
410
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
411 void setImageDimsWhenDisabled (bool flag)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
412 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
413 return invokeObjcSelf!(void, "setImageDimsWhenDisabled:", bool)(flag);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
414 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
415
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
416 bool imageDimsWhenDisabled ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
417 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
418 return invokeObjcSelf!(bool, "imageDimsWhenDisabled");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
419 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
420
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
421 void setShowsBorderOnlyWhileMouseInside (bool show)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
422 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
423 return invokeObjcSelf!(void, "setShowsBorderOnlyWhileMouseInside:", bool)(show);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
424 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
425
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
426 bool showsBorderOnlyWhileMouseInside ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
427 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
428 return invokeObjcSelf!(bool, "showsBorderOnlyWhileMouseInside");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
429 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
430
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
431 void mouseEntered (NSEvent event)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
432 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
433 return invokeObjcSelf!(void, "mouseEntered:", NSEvent)(event);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
434 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
435
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
436 void mouseExited (NSEvent event)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
437 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
438 return invokeObjcSelf!(void, "mouseExited:", NSEvent)(event);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
439 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
440
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
441 NSColor backgroundColor ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
442 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
443 return invokeObjcSelf!(NSColor, "backgroundColor");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
444 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
445
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
446 void setBackgroundColor (NSColor color)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
447 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
448 return invokeObjcSelf!(void, "setBackgroundColor:", NSColor)(color);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
449 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
450
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
451 // NSButtonCellBezelStyles
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
452 void setBezelStyle (uint bezelStyle)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
453 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
454 return invokeObjcSelf!(void, "setBezelStyle:", uint)(bezelStyle);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
455 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
456
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
457 uint bezelStyle ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
458 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
459 return invokeObjcSelf!(uint, "bezelStyle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
460 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
461
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
462 // NSButtonCellSoundExtensions
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
463 void setSound (NSSound aSound)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
464 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
465 return invokeObjcSelf!(void, "setSound:", NSSound)(aSound);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
466 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
467
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
468 NSSound sound ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
469 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
470 return invokeObjcSelf!(NSSound, "sound");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
471 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
472
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
473 // NSButtonCellAttributedStringMethods
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
474 NSAttributedString attributedTitle ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
475 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
476 return invokeObjcSelf!(NSAttributedString, "attributedTitle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
477 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
478
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
479 void setAttributedTitle (NSAttributedString obj)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
480 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
481 return invokeObjcSelf!(void, "setAttributedTitle:", NSAttributedString)(obj);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
482 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
483
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
484 NSAttributedString attributedAlternateTitle ()
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
485 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
486 return invokeObjcSelf!(NSAttributedString, "attributedAlternateTitle");
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
487 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
488
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
489 void setAttributedAlternateTitle (NSAttributedString obj)
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
490 {
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
491 return invokeObjcSelf!(void, "setAttributedAlternateTitle:", NSAttributedString)(obj);
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
492 }
19885b43130e Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff changeset
493 }