Mercurial > projects > dstep
annotate dstep/appkit/NSGraphicsContext.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 |
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.NSGraphicsContext; |
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.AppKitDefines; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
10 import dstep.appkit.NSBitmapImageRep; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
11 import dstep.appkit.NSGraphics; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
12 import dstep.appkit.NSWindow; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
13 import dstep.foundation.NSDictionary; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
14 import dstep.foundation.NSGeometry; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
15 import dstep.foundation.NSObjCRuntime; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
16 import dstep.foundation.NSObject; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
17 import dstep.foundation.NSString; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
18 import dstep.objc.bridge.Bridge; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
19 import dstep.objc.objc; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
20 import dstep.quartzcore.CIContext; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
21 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
22 import bindings = dstep.appkit.NSGraphicsContext_bindings; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
23 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
24 typedef NSUInteger NSImageInterpolation; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
25 typedef NSInteger NSColorRenderingIntent; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
26 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
27 private |
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 NSString NSGraphicsContextDestinationAttributeName_; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
30 NSString NSGraphicsContextRepresentationFormatAttributeName_; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
31 NSString NSGraphicsContextPSFormat_; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
32 NSString NSGraphicsContextPDFFormat_; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
33 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
34 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
35 NSString NSGraphicsContextDestinationAttributeName () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
36 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
37 if (NSGraphicsContextDestinationAttributeName_) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
38 return NSGraphicsContextDestinationAttributeName_; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
39 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
40 return NSGraphicsContextDestinationAttributeName_ = new NSString(bindings.NSGraphicsContextDestinationAttributeName); |
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 NSString NSGraphicsContextRepresentationFormatAttributeName () |
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 if (NSGraphicsContextRepresentationFormatAttributeName_) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
46 return NSGraphicsContextRepresentationFormatAttributeName_; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
47 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
48 return NSGraphicsContextRepresentationFormatAttributeName_ = new NSString(bindings.NSGraphicsContextRepresentationFormatAttributeName); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
49 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
50 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
51 NSString NSGraphicsContextPSFormat () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
52 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
53 if (NSGraphicsContextPSFormat_) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
54 return NSGraphicsContextPSFormat_; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
55 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
56 return NSGraphicsContextPSFormat_ = new NSString(bindings.NSGraphicsContextPSFormat); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
57 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
58 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
59 NSString NSGraphicsContextPDFFormat () |
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 if (NSGraphicsContextPDFFormat_) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
62 return NSGraphicsContextPDFFormat_; |
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 return NSGraphicsContextPDFFormat_ = new NSString(bindings.NSGraphicsContextPDFFormat); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
65 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
66 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
67 enum |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
68 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
69 NSImageInterpolationDefault, |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
70 NSImageInterpolationNone, |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
71 NSImageInterpolationLow, |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
72 NSImageInterpolationHigh |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
73 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
74 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
75 enum |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
76 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
77 NSColorRenderingIntentDefault, |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
78 NSColorRenderingIntentAbsoluteColorimetric, |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
79 NSColorRenderingIntentRelativeColorimetric, |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
80 NSColorRenderingIntentPerceptual, |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
81 NSColorRenderingIntentSaturation |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
82 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
83 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
84 const TNSQuartzCoreAdditions = ` |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
85 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
86 CIContext CIContext_ () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
87 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
88 return invokeObjcSelf!(CIContext, "CIContext"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
89 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
90 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
91 //mixin ObjcBindMethod!(CIContext_, "CIContext"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
92 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
93 `; |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
94 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
95 const TNSGraphicsContext_RenderingOptions = ` |
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 void setShouldAntialias (bool antialias) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
98 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
99 return invokeObjcSelf!(void, "setShouldAntialias:", bool)(antialias); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
100 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
101 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
102 bool shouldAntialias () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
103 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
104 return invokeObjcSelf!(bool, "shouldAntialias"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
105 } |
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 void setImageInterpolation (uint interpolation) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
108 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
109 return invokeObjcSelf!(void, "setImageInterpolation:", uint)(interpolation); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
110 } |
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 uint imageInterpolation () |
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 return invokeObjcSelf!(uint, "imageInterpolation"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
115 } |
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 void setPatternPhase (NSPoint phase) |
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 return invokeObjcSelf!(void, "setPatternPhase:", NSPoint)(phase); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
120 } |
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 NSPoint patternPhase () |
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 return invokeObjcSelf!(NSPoint, "patternPhase"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
125 } |
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 void setCompositingOperation (uint operation) |
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 return invokeObjcSelf!(void, "setCompositingOperation:", uint)(operation); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
130 } |
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 uint compositingOperation () |
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 return invokeObjcSelf!(uint, "compositingOperation"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
135 } |
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 int colorRenderingIntent () |
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 return invokeObjcSelf!(int, "colorRenderingIntent"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
140 } |
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 void setColorRenderingIntent (int renderingIntent) |
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 return invokeObjcSelf!(void, "setColorRenderingIntent:", int)(renderingIntent); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
145 } |
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 //mixin ObjcBindMethod!(setShouldAntialias, "setShouldAntialias:"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
148 //mixin ObjcBindMethod!(shouldAntialias, "shouldAntialias"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
149 //mixin ObjcBindMethod!(setImageInterpolation, "setImageInterpolation:"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
150 //mixin ObjcBindMethod!(imageInterpolation, "imageInterpolation"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
151 //mixin ObjcBindMethod!(setPatternPhase, "setPatternPhase:"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
152 //mixin ObjcBindMethod!(patternPhase, "patternPhase"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
153 //mixin ObjcBindMethod!(setCompositingOperation, "setCompositingOperation:"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
154 //mixin ObjcBindMethod!(compositingOperation, "compositingOperation"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
155 //mixin ObjcBindMethod!(colorRenderingIntent, "colorRenderingIntent"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
156 //mixin ObjcBindMethod!(setColorRenderingIntent, "setColorRenderingIntent:"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
157 |
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 class NSGraphicsContext : NSObject |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
161 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
162 mixin (ObjcWrap); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
163 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
164 static NSGraphicsContext graphicsContextWithAttributes (NSDictionary attributes) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
165 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
166 return invokeObjcSelfClass!(NSGraphicsContext, "graphicsContextWithAttributes:", NSDictionary)(attributes); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
167 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
168 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
169 static NSGraphicsContext graphicsContextWithWindow (NSWindow window) |
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 return invokeObjcSelfClass!(NSGraphicsContext, "graphicsContextWithWindow:", NSWindow)(window); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
174 static NSGraphicsContext graphicsContextWithBitmapImageRep (NSBitmapImageRep bitmapRep) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
175 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
176 return invokeObjcSelfClass!(NSGraphicsContext, "graphicsContextWithBitmapImageRep:", NSBitmapImageRep)(bitmapRep); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
177 } |
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 static NSGraphicsContext graphicsContextWithGraphicsPort (void* graphicsPort, bool initialFlippedState) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
180 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
181 return invokeObjcSelfClass!(NSGraphicsContext, "graphicsContextWithGraphicsPort:flipped:", void*, bool)(graphicsPort, initialFlippedState); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
182 } |
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 static NSGraphicsContext currentContext () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
185 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
186 return invokeObjcSelfClass!(NSGraphicsContext, "currentContext"); |
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 static void setCurrentContext (NSGraphicsContext context) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
190 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
191 return invokeObjcSelfClass!(void, "setCurrentContext:", NSGraphicsContext)(context); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
192 } |
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 static bool currentContextDrawingToScreen () |
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 return invokeObjcSelfClass!(bool, "currentContextDrawingToScreen"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
197 } |
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 static void saveGraphicsState_static () |
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 return invokeObjcSelfClass!(void, "saveGraphicsState"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
202 } |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
203 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
204 static void restoreGraphicsState_static () |
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 return invokeObjcSelfClass!(void, "restoreGraphicsState"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
207 } |
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 static void setGraphicsState (NSInteger gState) |
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 invokeObjcSelfClass!(void, "setGraphicsState:", NSInteger)(gState); |
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 NSDictionary attributes () |
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!(NSDictionary, "attributes"); |
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 bool isDrawingToScreen () |
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!(bool, "isDrawingToScreen"); |
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 saveGraphicsState () |
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, "saveGraphicsState"); |
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 void restoreGraphicsState () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
230 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
231 return invokeObjcSelf!(void, "restoreGraphicsState"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
232 } |
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 void flushGraphics () |
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 return invokeObjcSelf!(void, "flushGraphics"); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
239 Object focusStack () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
240 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
241 return invokeObjcSelf!(Object, "focusStack"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
242 } |
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 void setFocusStack (Object stack) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
245 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
246 return invokeObjcSelf!(void, "setFocusStack:", Object)(stack); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
247 } |
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 void* graphicsPort () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
250 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
251 return invokeObjcSelf!(void*, "graphicsPort"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
252 } |
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 bool isFlipped () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
255 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
256 return invokeObjcSelf!(bool, "isFlipped"); |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
257 } |
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 // NSQuartzCoreAdditions |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
260 CIContext CIContext_ () |
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!(CIContext, "CIContext"); |
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 // NSGraphicsContext_RenderingOptions |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
266 void setShouldAntialias (bool antialias) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
267 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
268 return invokeObjcSelf!(void, "setShouldAntialias:", bool)(antialias); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
271 bool shouldAntialias () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
272 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
273 return invokeObjcSelf!(bool, "shouldAntialias"); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
276 void setImageInterpolation (uint interpolation) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
277 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
278 return invokeObjcSelf!(void, "setImageInterpolation:", uint)(interpolation); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
281 uint imageInterpolation () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
282 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
283 return invokeObjcSelf!(uint, "imageInterpolation"); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
286 void setPatternPhase (NSPoint phase) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
287 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
288 return invokeObjcSelf!(void, "setPatternPhase:", NSPoint)(phase); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
291 NSPoint patternPhase () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
292 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
293 return invokeObjcSelf!(NSPoint, "patternPhase"); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
296 void setCompositingOperation (uint operation) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
297 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
298 return invokeObjcSelf!(void, "setCompositingOperation:", uint)(operation); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
301 uint compositingOperation () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
302 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
303 return invokeObjcSelf!(uint, "compositingOperation"); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
306 int colorRenderingIntent () |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
307 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
308 return invokeObjcSelf!(int, "colorRenderingIntent"); |
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 |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
311 void setColorRenderingIntent (int renderingIntent) |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
312 { |
19885b43130e
Huge update, the bridge actually works now
Jacob Carlborg <doob@me.com>
parents:
diff
changeset
|
313 return invokeObjcSelf!(void, "setColorRenderingIntent:", int)(renderingIntent); |
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 } |