comparison src/console-w32.h @ 209:41ff10fd062f r20-4b3

Import from CVS: tag r20-4b3
author cvs
date Mon, 13 Aug 2007 10:04:58 +0200
parents
children
comparison
equal deleted inserted replaced
208:f427b8ec4379 209:41ff10fd062f
1 /* Define win32 specific console, device, and frame object for XEmacs.
2 Copyright (C) 1989, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
3 Copyright (C) 1994, 1995 Board of Trustees, University of Illinois.
4
5 This file is part of XEmacs.
6
7 XEmacs is free software; you can redistribute it and/or modify it
8 under the terms of the GNU General Public License as published by the
9 Free Software Foundation; either version 2, or (at your option) any
10 later version.
11
12 XEmacs is distributed in the hope that it will be useful, but WITHOUT
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15 for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with XEmacs; see the file COPYING. If not, write to
19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 Boston, MA 02111-1307, USA. */
21
22 /* Synched up with: Not in FSF. */
23
24
25 /* Authorship:
26
27 Ultimately based on FSF, then later on JWZ work for Lemacs.
28 Rewritten over time by Ben Wing and Chuck Thompson.
29 Rewritten for win32 by Jonathan Harris, November 1997 for 20.4.
30 */
31
32 #ifndef _XEMACS_CONSOLE_W32_H_
33 #define _XEMACS_CONSOLE_W32_H_
34
35 #include "console.h"
36
37 #include "windows.h"
38
39 DECLARE_CONSOLE_TYPE (w32);
40
41 struct w32_console
42 {
43 int infd, outfd;
44 };
45
46
47 struct w32_device
48 {
49 int logpixelsx, logpixelsy;
50 int planes, cells;
51 int horzres, vertres; /* Size in pixels */
52 int horzsize, vertsize; /* Size in mm */
53 };
54
55 #define DEVICE_W32_DATA(d) DEVICE_TYPE_DATA (d, w32)
56 #define DEVICE_W32_LOGPIXELSX(d) (DEVICE_W32_DATA (d)->logpixelsx)
57 #define DEVICE_W32_LOGPIXELSY(d) (DEVICE_W32_DATA (d)->logpixelsy)
58 #define DEVICE_W32_PLANES(d) (DEVICE_W32_DATA (d)->planes)
59 #define DEVICE_W32_CELLS(d) (DEVICE_W32_DATA (d)->cells)
60 #define DEVICE_W32_HORZRES(d) (DEVICE_W32_DATA (d)->horzres)
61 #define DEVICE_W32_VERTRES(d) (DEVICE_W32_DATA (d)->vertres)
62 #define DEVICE_W32_HORZSIZE(d) (DEVICE_W32_DATA (d)->horzsize)
63 #define DEVICE_W32_VERTSIZE(d) (DEVICE_W32_DATA (d)->vertsize)
64
65
66 struct w32_frame
67 {
68 /* win32 window handle */
69 HWND hwnd;
70
71 /* DC for this win32 window */
72 HDC hdc;
73 };
74
75 #define FRAME_W32_DATA(f) FRAME_TYPE_DATA (f, w32)
76
77 #define FRAME_W32_HANDLE(f) (FRAME_W32_DATA (f)->hwnd)
78 #define FRAME_W32_DC(f) (FRAME_W32_DATA (f)->hdc)
79
80
81 /*
82 * Redisplay functions
83 */
84 void w32_redraw_exposed_area (struct frame *f, int x, int y,
85 int width, int height);
86
87 #endif /* _XEMACS_CONSOLE_W32_H_ */