Removing the use of private CoreGraphics APIs to draw shadows, and replacing with...
[ITKit.git] / ITCoreGraphicsHacks.h
1 /*
2  *      ITKit
3  *      ITCoreGraphicsHacks.h
4  *
5  *      Header to import to work with private CoreGraphics API.
6  *
7  *      Copyright (c) 2005 iThink Software
8  *
9  */
10
11 typedef void * CGSGenericObj;
12 typedef CGSGenericObj CGSValueObj;
13 typedef void * CGSConnectionID;
14 typedef void * CGSWindowID;
15 typedef unsigned char CGSBoolean;
16 enum {
17         kCGSFalse = 0,
18         kCGSTrue = 1
19 };
20
21 typedef enum {
22         CGSTagExposeFade        = 0x0002,   // Fade out when Expose activates.
23         CGSTagNoShadow          = 0x0008,   // No window shadow.
24         CGSTagTransparent       = 0x0200,   // Transparent to mouse clicks.
25         CGSTagSticky            = 0x0800,   // Appears on all workspaces.
26 } CGSWindowTag;
27
28 extern void CGSReleaseObj(void *obj);
29 extern CGSValueObj CGSCreateCString(const char *string);
30 extern CGSValueObj CGSCreateBoolean(CGSBoolean boolean);
31 extern CGError CGSSetWindowProperty(const CGSConnectionID cid, CGSWindowID wid, const CGSValueObj key, const CGSValueObj value);
32
33 extern CGError CGSSetWindowWarp(const CGSConnectionID cid, CGSWindowID wid, int w,int h, float *mesh);
34 extern CGError CGSSetWindowTransform(const CGSConnectionID cid, CGSWindowID wid, CGAffineTransform transform);
35
36 extern OSStatus CGSGetWindowTags(const CGSConnectionID cid, const CGSWindowID wid, CGSWindowTag *tags, int thirtyTwo);
37 extern OSStatus CGSSetWindowTags(const CGSConnectionID cid, const CGSWindowID wid, CGSWindowTag *tags, int thirtyTwo);
38 extern OSStatus CGSClearWindowTags(const CGSConnectionID cid, const CGSWindowID wid, CGSWindowTag *tags, int thirtyTwo);
39
40 @interface NSApplication (ITCoreGraphicsHacks)
41 - (CGSConnectionID)contextID;
42 @end