Debian Codegraph @

garglk/sysmac.h

raw symbols SCIP
1 // Copyright (C) 2006-2009 by Tor Andersson, Jesse McGrew.
2 // Copyright (C) 2010 by Ben Cressey, Chris Spiegel.
3 //
4 // This file is part of Gargoyle.
5 //
6 // Gargoyle is free software; you can redistribute it and/or modify
7 // it under the terms of the GNU General Public License as published by
8 // the Free Software Foundation; either version 2 of the License, or
9 // (at your option) any later version.
10 //
11 // Gargoyle is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 //
16 // You should have received a copy of the GNU General Public License
17 // along with Gargoyle; if not, write to the Free Software
18 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19
20 #ifndef GARGLK_SYSMAC_M
21 #define GARGLK_SYSMAC_M
22
23 #include <Cocoa/Cocoa.h>
24
25 #ifdef __ppc__
26 #define UTF32StringEncoding NSUTF32BigEndianStringEncoding
27 #else
28 #define UTF32StringEncoding NSUTF32LittleEndianStringEncoding
29 #endif
30
31 #define BACKING_SCALE_FACTOR 2.0
32
33 #define NSKEY_LEFT 0x7b
34 #define NSKEY_RIGHT 0x7c
35 #define NSKEY_DOWN 0x7d
36 #define NSKEY_UP 0x7e
37
38 #define NSKEY_A 0x00
39 #define NSKEY_B 0x0b
40 #define NSKEY_C 0x08
41 #define NSKEY_D 0x02
42 #define NSKEY_E 0x0e
43 #define NSKEY_F 0x03
44 #define NSKEY_H 0x04
45 #define NSKEY_N 0x2d
46 #define NSKEY_P 0x23
47 #define NSKEY_S 0x01
48 #define NSKEY_T 0x11
49 #define NSKEY_U 0x20
50 #define NSKEY_V 0x09
51 #define NSKEY_X 0x07
52
53 #define NSKEY_PERIOD 0x2f
54
55 #define NSKEY_PGUP 0x74
56 #define NSKEY_PGDN 0x79
57 #define NSKEY_HOME 0x73
58 #define NSKEY_END 0x77
59 #define NSKEY_DEL 0x75
60 #define NSKEY_BACK 0x33
61 #define NSKEY_ESC 0x35
62
63 #define NSKEY_F1 0x7a
64 #define NSKEY_F2 0x78
65 #define NSKEY_F3 0x63
66 #define NSKEY_F4 0x76
67 #define NSKEY_F5 0x60
68 #define NSKEY_F6 0x61
69 #define NSKEY_F7 0x62
70 #define NSKEY_F8 0x64
71 #define NSKEY_F9 0x65
72 #define NSKEY_F10 0x6d
73 #define NSKEY_F11 0x67
74 #define NSKEY_F12 0x6f
75
76 @protocol GargoyleApp
77
78 - (BOOL) initWindow: (pid_t) processID
79 move: (BOOL) move
80 x: (unsigned int) x
81 y: (unsigned int) y
82 width: (unsigned int) width
83 height: (unsigned int) height
84 fullscreen: (BOOL) fullscreen
85 backgroundColor: (NSColor *) backgroundColor;
86
87 - (NSEvent *) getWindowEvent: (pid_t) processID;
88
89 - (NSRect) updateBackingSize: (pid_t) processID;
90
91 - (CGFloat) getBackingScaleFactor: (pid_t) processID;
92
93 - (NSPoint) getWindowPoint: (pid_t) processID
94 forEvent: (NSEvent *) event;
95
96 - (NSString *) getWindowCharString: (pid_t) processID;
97
98 - (BOOL) clearWindowCharString: (pid_t) processID;
99
100 - (BOOL) setWindow: (pid_t) processID
101 charString: (NSEvent *) event;
102
103 - (BOOL) setWindow: (pid_t) processID
104 title: (NSString *) title;
105
106 - (BOOL) setWindow: (pid_t) processID
107 contents: (NSData *) frame
108 width: (unsigned int) width
109 height: (unsigned int) height;
110
111 - (void) closeWindow: (pid_t) processID;
112
113 - (NSString *) openWindowDialog: (pid_t) processID
114 prompt: (NSString *) prompt
115 filter: (FileFilter) filter
116 savedir: (NSString *) savedir;
117
118 - (NSString *) saveWindowDialog: (pid_t) processID
119 prompt: (NSString *) prompt
120 filter: (FileFilter) filter
121 savedir: (NSString *) savedir;
122
123 - (void) abortWindowDialog: (pid_t) processID
124 prompt: (NSString *) prompt;
125
126 - (void) setCursor: (unsigned int) cursor;
127
128 - (BOOL) isFullScreen: (pid_t) processID;
129 - (void) toggleFullScreen: (pid_t) processID;
130
131 @end
132
133 NSString *get_qt_plist_path();
134
135 #endif