OSDN Git Service

19909ca97a89bc2f64b6642e4642d28d672190af
[localjavascript/localJS-dev.git] / xaw.h
1 #ifndef JS_XAW
2 #define JS_XAW
3
4 #include <X11/StringDefs.h>
5
6 #include <X11/Intrinsic.h>
7 #include <X11/Xaw/Form.h>
8 #include <X11/Xaw/Label.h>
9 #include <X11/Xaw/Command.h>
10 #include <X11/Xaw/AsciiText.h>
11
12 #include <assert.h>
13
14 #include "js.h"
15
16
17 typedef struct  /* XawのWindowを構造体として定義 */
18 {
19         XtAppContext* Context;
20         int argc;
21         char **argv;
22         char* Name;
23         XtOrientation Direction;
24 } xawWindow;
25
26
27 typedef struct  /* XawのWidetを構造体として定義 */
28 {
29         char* Name;
30         WidgetClass Type;
31         Widget Parent;
32         char* Text;
33         int Width;//x
34         int Height;//y
35         int Left;//x
36         int Top;//y
37         int Border;
38         JSContextRef* Context;
39         JSValueRef* CallbackFunction;
40 } xawWidet;
41
42 typedef struct  /* XawのWidetを構造体として定義 */
43 {
44         XtAppContext* Context;
45         int argc;
46         char **argv;
47         char* Name;
48         
49 } jsXawContext;
50
51 typedef struct  /* JSにイベントを渡すための構造体 */
52 {
53         JSGlobalContextRef* Context;
54         JSObjectRef Function;
55 } jsCallbackInfo;
56
57 char *resources[] = {
58         "*international: True",
59         "*fontList: -adobe-helvetica-bold-r-normal-*-*-120-75-75-*-*-iso8859-1", 
60         "*preeditType: OverTheSpot,OffTheSpot,Root", 
61         "*inputMethod: kinput2",
62         "*background: gray70",
63         "*foregound: black",
64         NULL
65 };
66
67 #endif