13434
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
1 /* Definitions and headers for communication with Win32 GUI.
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
2 Copyright (C) 1995 Free Software Foundation, Inc.
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
3
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
4 This file is part of GNU Emacs.
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
5
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
6 GNU Emacs is free software; you can redistribute it and/or modify
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
7 it under the terms of the GNU General Public License as published by
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
8 the Free Software Foundation; either version 2, or (at your option)
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
9 any later version.
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
10
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
11 GNU Emacs is distributed in the hope that it will be useful,
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
14 GNU General Public License for more details.
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
15
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
16 You should have received a copy of the GNU General Public License
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
17 along with GNU Emacs; see the file COPYING. If not, write to
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
18 the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
19
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
20 #ifndef __WIN32_H__
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
21 #define __WIN32_H__
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
22
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
23 #include <windows.h>
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
24
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
25 typedef struct W32FontStruct {
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
26 TEXTMETRIC tm;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
27 HFONT hfont;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
28 } W32FontStruct;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
29
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
30 typedef HBITMAP Pixmap;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
31 typedef HBITMAP Bitmap;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
32 typedef struct W32FontStruct XFontStruct;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
33 typedef HDC GC;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
34 typedef COLORREF Color;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
35 typedef DWORD Time;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
36 typedef HWND Window;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
37 typedef HCURSOR Cursor;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
38
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
39 #define FACE_DEFAULT (~0)
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
40
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
41 extern HINSTANCE hinst;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
42 extern HINSTANCE hprevinst;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
43 extern LPSTR lpCmdLine;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
44 extern int nCmdShow;
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
45
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
46 /* Bit Gravity */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
47
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
48 #define ForgetGravity 0
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
49 #define NorthWestGravity 1
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
50 #define NorthGravity 2
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
51 #define NorthEastGravity 3
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
52 #define WestGravity 4
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
53 #define CenterGravity 5
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
54 #define EastGravity 6
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
55 #define SouthWestGravity 7
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
56 #define SouthGravity 8
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
57 #define SouthEastGravity 9
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
58 #define StaticGravity 10
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
59
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
60 #define NoValue 0x0000
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
61 #define XValue 0x0001
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
62 #define YValue 0x0002
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
63 #define WidthValue 0x0004
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
64 #define HeightValue 0x0008
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
65 #define AllValues 0x000F
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
66 #define XNegative 0x0010
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
67 #define YNegative 0x0020
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
68
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
69 #define USPosition (1L << 0) /* user specified x, y */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
70 #define USSize (1L << 1) /* user specified width, height */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
71
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
72 #define PPosition (1L << 2) /* program specified position */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
73 #define PSize (1L << 3) /* program specified size */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
74 #define PMinSize (1L << 4) /* program specified minimum size */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
75 #define PMaxSize (1L << 5) /* program specified maximum size */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
76 #define PResizeInc (1L << 6) /* program specified resize increments */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
77 #define PAspect (1L << 7) /* program specified min and max aspect ratios */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
78 #define PBaseSize (1L << 8) /* program specified base for incrementing */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
79 #define PWinGravity (1L << 9) /* program specified window gravity */
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
80
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
81 extern int XParseGeometry ();
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
82
|
Geoff Voelker <voelker@cs.washington.edu>
parents:
diff
changeset
|
83 #endif
|