Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
fbd6baed
Commit
fbd6baed
authored
Nov 19, 1996
by
Geoff Voelker
Browse files
Change identifiers of the form win32* to w32*.
parent
0f7d64d2
Changes
24
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
574 additions
and
574 deletions
+574
-574
lisp/term/w32-win.el
lisp/term/w32-win.el
+11
-11
src/emacs.c
src/emacs.c
+5
-5
src/frame.c
src/frame.c
+5
-5
src/frame.h
src/frame.h
+5
-5
src/keyboard.c
src/keyboard.c
+2
-2
src/s/ms-w32.h
src/s/ms-w32.h
+1
-1
src/termhooks.h
src/termhooks.h
+1
-1
src/unexw32.c
src/unexw32.c
+1
-1
src/w32.c
src/w32.c
+28
-28
src/w32.h
src/w32.h
+1
-1
src/w32console.c
src/w32console.c
+6
-6
src/w32faces.c
src/w32faces.c
+16
-16
src/w32fns.c
src/w32fns.c
+419
-419
src/w32heap.c
src/w32heap.c
+4
-4
src/w32heap.h
src/w32heap.h
+4
-4
src/w32inevt.c
src/w32inevt.c
+11
-11
src/w32inevt.h
src/w32inevt.h
+4
-4
src/w32menu.c
src/w32menu.c
+22
-22
src/w32proc.c
src/w32proc.c
+26
-26
src/w32reg.c
src/w32reg.c
+2
-2
No files found.
lisp/term/w32-win.el
View file @
fbd6baed
...
...
@@ -81,7 +81,7 @@
;; with the standard X scroll-bars, we don't try to use the normal
;; scroll bar routines.
(
defun
w
in
32-handle-scroll-bar-event
(
event
)
(
defun
w32-handle-scroll-bar-event
(
event
)
"Handle Win32 scroll bar events to do normal Window style scrolling."
(
interactive
"e"
)
(
let
((
old-window
(
selected-window
)))
...
...
@@ -107,9 +107,9 @@
(
select-window
old-window
))))
;; The following definition is used for debugging.
;(defun w
in
32-handle-scroll-bar-event (event) (interactive "e") (princ event))
;(defun w32-handle-scroll-bar-event (event) (interactive "e") (princ event))
(
global-set-key
[vertical-scroll-bar
mouse-1]
'w
in
32-handle-scroll-bar-event
)
(
global-set-key
[vertical-scroll-bar
mouse-1]
'w32-handle-scroll-bar-event
)
;; (scroll-bar-mode nil)
...
...
@@ -521,7 +521,7 @@ This is in addition to the primary selection.")
(
defun
x-select-text
(
text
&optional
push
)
(
if
x-select-enable-clipboard
(
w
in
32-set-clipboard-data
text
))
(
w32-set-clipboard-data
text
))
(
setq
x-last-selected-text
text
))
;;; Return the value of the current selection.
...
...
@@ -532,8 +532,8 @@ This is in addition to the primary selection.")
(
let
(
text
)
;; Don't die if x-get-selection signals an error.
(
condition-case
c
(
setq
text
(
w
in
32-get-clipboard-data
))
(
error
(
message
"w
in
32-get-clipboard-data:%s"
c
)))
(
setq
text
(
w32-get-clipboard-data
))
(
error
(
message
"w32-get-clipboard-data:%s"
c
)))
(
if
(
string=
text
""
)
(
setq
text
nil
))
(
cond
((
not
text
)
nil
)
...
...
@@ -576,7 +576,7 @@ This is in addition to the primary selection.")
(
setq
x-cut-buffer-max
(
min
(
-
(
/
(
x-server-max-request-size
)
2
)
100
)
x-cut-buffer-max
))
;; W
in
32 expects the menu bar cut and paste commands to use the clipboard.
;; W32 expects the menu bar cut and paste commands to use the clipboard.
;; This has ,? to match both on Sunos and on Solaris.
(
menu-bar-enable-clipboard
)
...
...
@@ -628,7 +628,7 @@ This is in addition to the primary selection.")
(
setq
interprogram-cut-function
'x-select-text
)
(
setq
interprogram-paste-function
'x-get-selection-value
)
;;; Turn off window-splitting optimization; w
in
32 is usually fast enough
;;; Turn off window-splitting optimization; w32 is usually fast enough
;;; that this is only annoying.
(
setq
split-window-keep-point
t
)
...
...
@@ -638,7 +638,7 @@ This is in addition to the primary selection.")
;;; Set to a system sound if you want a fancy bell.
(
set-message-beep
'ok
)
;; Remap some functions to call w
in
32 common dialogs
;; Remap some functions to call w32 common dialogs
(
defun
internal-face-interactive
(
what
&optional
bool
)
(
let*
((
fn
(
intern
(
concat
"face-"
what
)))
...
...
@@ -658,10 +658,10 @@ This is in addition to the primary selection.")
default
)))))
(
list
face
(
if
(
equal
value
""
)
nil
value
))))
;; Redefine the font selection to use the Win32 dialog
;; Redefine the font selection to use the
standard
Win32 dialog
(
defun
mouse-set-font
(
&rest
fonts
)
(
interactive
)
(
set-default-font
(
w
in
32-select-font
)))
(
set-default-font
(
w32-select-font
)))
;;; win32-win.el ends here
src/emacs.c
View file @
fbd6baed
...
...
@@ -979,11 +979,11 @@ the Bugs section of the Emacs manual or the file BUGS.", argv[0]);
#endif
#ifdef HAVE_NTGUI
syms_of_w
in
32term
();
syms_of_w
in
32fns
();
syms_of_w
in
32faces
();
syms_of_w
in
32select
();
syms_of_w
in
32menu
();
syms_of_w32term
();
syms_of_w32fns
();
syms_of_w32faces
();
syms_of_w32select
();
syms_of_w32menu
();
#endif
/* HAVE_NTGUI */
#ifdef SYMS_SYSTEM
...
...
src/frame.c
View file @
fbd6baed
...
...
@@ -75,7 +75,7 @@ Lisp_Object Qunsplittable;
Lisp_Object
Qmenu_bar_lines
;
Lisp_Object
Qwidth
;
Lisp_Object
Qx
;
Lisp_Object
Qw
in
32
;
Lisp_Object
Qw32
;
Lisp_Object
Qpc
;
Lisp_Object
Qvisible
;
Lisp_Object
Qbuffer_predicate
;
...
...
@@ -112,8 +112,8 @@ syms_of_frame_1 ()
staticpro
(
&
Qwidth
);
Qx
=
intern
(
"x"
);
staticpro
(
&
Qx
);
Qw
in
32
=
intern
(
"w
in
32"
);
staticpro
(
&
Qw
in
32
);
Qw32
=
intern
(
"w32"
);
staticpro
(
&
Qw32
);
Qpc
=
intern
(
"pc"
);
staticpro
(
&
Qpc
);
Qvisible
=
intern
(
"visible"
);
...
...
@@ -221,8 +221,8 @@ See also `frame-live-p'.")
return
Qt
;
case
output_x_window
:
return
Qx
;
case
output_w
in
32
:
return
Qw
in
32
;
case
output_w32
:
return
Qw32
;
case
output_msdos_raw
:
return
Qpc
;
default:
...
...
src/frame.h
View file @
fbd6baed
...
...
@@ -33,7 +33,7 @@ extern int message_buf_print;
/* The structure representing a frame. */
enum
output_method
{
output_termcap
,
output_x_window
,
output_msdos_raw
,
output_w
in
32
};
{
output_termcap
,
output_x_window
,
output_msdos_raw
,
output_w32
};
enum
vertical_scroll_bar_type
{
vertical_scroll_bar_none
,
vertical_scroll_bar_left
,
vertical_scroll_bar_right
};
...
...
@@ -181,9 +181,9 @@ struct frame
/* A structure of auxiliary data used for displaying the contents.
struct x_output is used for X window frames;
it is defined in xterm.h.
struct w
in
32_output is used for W
in
32 window frames;
struct w32_output is used for W32 window frames;
it is defined in w32term.h. */
union
output_data
{
struct
x_output
*
x
;
struct
w
in
32_output
*
w
in
32
;
int
nothing
;
}
output_data
;
union
output_data
{
struct
x_output
*
x
;
struct
w32_output
*
w32
;
int
nothing
;
}
output_data
;
#ifdef MULTI_KBOARD
/* A pointer to the kboard structure associated with this frame.
...
...
@@ -309,7 +309,7 @@ typedef struct frame *FRAME_PTR;
#define WINDOW_FRAME(w) (w)->frame
#define FRAME_X_P(f) ((f)->output_method == output_x_window)
#define FRAME_W
IN
32_P(f) ((f)->output_method == output_w
in
32)
#define FRAME_W32_P(f) ((f)->output_method == output_w32)
#define FRAME_MSDOS_P(f) ((f)->output_method == output_msdos_raw)
/* FRAME_WINDOW_P tests whether the frame is a window, and is
...
...
@@ -318,7 +318,7 @@ typedef struct frame *FRAME_PTR;
#define FRAME_WINDOW_P(f) FRAME_X_P (f)
#endif
#ifdef HAVE_NTGUI
#define FRAME_WINDOW_P(f) FRAME_W
IN
32_P (f)
#define FRAME_WINDOW_P(f) FRAME_W32_P (f)
#endif
#ifndef FRAME_WINDOW_P
#define FRAME_WINDOW_P(f) (0)
...
...
src/keyboard.c
View file @
fbd6baed
...
...
@@ -3920,7 +3920,7 @@ make_lispy_event (event)
}
#ifdef WINDOWSNT
case w
in
32_scroll_bar_click:
case w32_scroll_bar_click:
{
int button = event->code;
int is_double;
...
...
@@ -3948,7 +3948,7 @@ make_lispy_event (event)
Fcons (part, Qnil)))));
}
/* Always treat W
in
32 scroll bar events as clicks. */
/* Always treat W32 scroll bar events as clicks. */
event->modifiers |= click_modifier;
{
...
...
src/s/ms-w32.h
View file @
fbd6baed
...
...
@@ -319,7 +319,7 @@ Boston, MA 02111-1307, USA. */
#define rindex strrchr
#ifdef HAVE_NTGUI
#define abort w
in
32_abort
#define abort w32_abort
#endif
/* Defines that we need that aren't in the standard signal.h */
...
...
src/termhooks.h
View file @
fbd6baed
...
...
@@ -248,7 +248,7 @@ enum event_kind
.timestamp gives a timestamp (in
milliseconds) for the click. */
#ifdef WINDOWSNT
w
in
32_scroll_bar_click
,
/* as for scroll_bar_click, but only generated
w32_scroll_bar_click
,
/* as for scroll_bar_click, but only generated
by MS-Windows scroll bar controls. */
#endif
selection_request_event
,
/* Another X client wants a selection from us.
...
...
src/unexw32.c
View file @
fbd6baed
...
...
@@ -314,7 +314,7 @@ static unsigned long
get_section_size
(
PIMAGE_SECTION_HEADER
p_section
)
{
/* The section size is in different locations in the different versions. */
switch
(
get_
nt
_minor_version
())
switch
(
get_
w32
_minor_version
())
{
case
10
:
return
p_section
->
SizeOfRawData
;
...
...
src/w32.c
View file @
fbd6baed
...
...
@@ -122,7 +122,7 @@ static HANDLE dir_find_handle = INVALID_HANDLE_VALUE;
static
int
dir_is_fat
;
static
char
dir_pathname
[
MAXPATHLEN
+
1
];
extern
Lisp_Object
Vw
in
32_downcase_file_names
;
extern
Lisp_Object
Vw32_downcase_file_names
;
DIR
*
opendir
(
char
*
filename
)
...
...
@@ -199,7 +199,7 @@ readdir (DIR *dirp)
strcpy
(
dir_static
.
d_name
,
find_data
.
cFileName
);
if
(
dir_is_fat
)
_strlwr
(
dir_static
.
d_name
);
else
if
(
!
NILP
(
Vw
in
32_downcase_file_names
))
else
if
(
!
NILP
(
Vw32_downcase_file_names
))
{
register
char
*
p
;
for
(
p
=
dir_static
.
d_name
;
*
p
;
p
++
)
...
...
@@ -412,7 +412,7 @@ normalize_filename (fp, path_sep)
fp
+=
2
;
}
if
(
NILP
(
Vw
in
32_downcase_file_names
))
if
(
NILP
(
Vw32_downcase_file_names
))
{
while
(
*
fp
)
{
...
...
@@ -536,7 +536,7 @@ request_sigio (void)
#define REG_ROOT "SOFTWARE\\GNU\\Emacs"
LPBYTE
nt
_get_resource
(
key
,
lpdwtype
)
w32
_get_resource
(
key
,
lpdwtype
)
char
*
key
;
LPDWORD
lpdwtype
;
{
...
...
@@ -610,7 +610,7 @@ init_environment ()
for
(
i
=
0
;
i
<
(
sizeof
(
env_vars
)
/
sizeof
(
env_vars
[
0
]));
i
++
)
{
if
(
!
getenv
(
env_vars
[
i
])
&&
(
lpval
=
nt
_get_resource
(
env_vars
[
i
],
&
dwType
))
!=
NULL
)
(
lpval
=
w32
_get_resource
(
env_vars
[
i
],
&
dwType
))
!=
NULL
)
{
if
(
dwType
==
REG_EXPAND_SZ
)
{
...
...
@@ -691,7 +691,7 @@ get_emacs_configuration (void)
os
=
(
GetVersion
()
&
0x80000000
)
?
"win95"
:
"nt"
;
sprintf
(
configuration_buffer
,
"%s-%s-%s%d.%d"
,
arch
,
oem
,
os
,
get_
nt
_major_version
(),
get_
nt
_minor_version
());
get_
w32
_major_version
(),
get_
w32
_minor_version
());
return
configuration_buffer
;
}
...
...
@@ -714,7 +714,7 @@ gettimeofday (struct timeval *tv, struct timezone *tz)
}
/* ------------------------------------------------------------------------- */
/* IO support and wrapper functions for W
in
32 API. */
/* IO support and wrapper functions for W32 API. */
/* ------------------------------------------------------------------------- */
/* Place a wrapper around the MSVC version of ctime. It returns NULL
...
...
@@ -818,7 +818,7 @@ is_fat_volume (const char * name, const char ** pPath)
/* Map filename to a legal 8.3 name if necessary. */
const
char
*
map_w
in
32_filename
(
const
char
*
name
,
const
char
**
pPath
)
map_w32_filename
(
const
char
*
name
,
const
char
**
pPath
)
{
static
char
shortname
[
MAX_PATH
];
char
*
str
=
shortname
;
...
...
@@ -922,25 +922,25 @@ map_win32_filename (const char * name, const char ** pPath)
int
sys_access
(
const
char
*
path
,
int
mode
)
{
return
_access
(
map_w
in
32_filename
(
path
,
NULL
),
mode
);
return
_access
(
map_w32_filename
(
path
,
NULL
),
mode
);
}
int
sys_chdir
(
const
char
*
path
)
{
return
_chdir
(
map_w
in
32_filename
(
path
,
NULL
));
return
_chdir
(
map_w32_filename
(
path
,
NULL
));
}
int
sys_chmod
(
const
char
*
path
,
int
mode
)
{
return
_chmod
(
map_w
in
32_filename
(
path
,
NULL
),
mode
);
return
_chmod
(
map_w32_filename
(
path
,
NULL
),
mode
);
}
int
sys_creat
(
const
char
*
path
,
int
mode
)
{
return
_creat
(
map_w
in
32_filename
(
path
,
NULL
),
mode
);
return
_creat
(
map_w32_filename
(
path
,
NULL
),
mode
);
}
FILE
*
...
...
@@ -980,7 +980,7 @@ sys_fopen(const char * path, const char * mode)
}
else
break
;
fd
=
_open
(
map_w
in
32_filename
(
path
,
NULL
),
oflag
|
_O_NOINHERIT
,
0644
);
fd
=
_open
(
map_w32_filename
(
path
,
NULL
),
oflag
|
_O_NOINHERIT
,
0644
);
if
(
fd
<
0
)
return
NULL
;
...
...
@@ -997,7 +997,7 @@ sys_link (const char * path1, const char * path2)
int
sys_mkdir
(
const
char
*
path
)
{
return
_mkdir
(
map_w
in
32_filename
(
path
,
NULL
));
return
_mkdir
(
map_w32_filename
(
path
,
NULL
));
}
/* Because of long name mapping issues, we need to implement this
...
...
@@ -1054,7 +1054,7 @@ int
sys_open
(
const
char
*
path
,
int
oflag
,
int
mode
)
{
/* Force all file handles to be non-inheritable. */
return
_open
(
map_w
in
32_filename
(
path
,
NULL
),
oflag
|
_O_NOINHERIT
,
mode
);
return
_open
(
map_w32_filename
(
path
,
NULL
),
oflag
|
_O_NOINHERIT
,
mode
);
}
int
...
...
@@ -1076,7 +1076,7 @@ sys_rename (const char * oldname, const char * newname)
So, on Win95 we always rename through a temp name, and we make sure
the temp name has a long extension to ensure correct renaming. */
strcpy
(
temp
,
map_w
in
32_filename
(
oldname
,
NULL
));
strcpy
(
temp
,
map_w32_filename
(
oldname
,
NULL
));
if
(
GetVersion
()
&
0x80000000
)
{
...
...
@@ -1091,7 +1091,7 @@ sys_rename (const char * oldname, const char * newname)
/* Force temp name to require a manufactured 8.3 alias - this
seems to make the second rename work properly. */
strcat
(
temp
,
".long"
);
if
(
rename
(
map_w
in
32_filename
(
oldname
,
NULL
),
temp
)
<
0
)
if
(
rename
(
map_w32_filename
(
oldname
,
NULL
),
temp
)
<
0
)
return
-
1
;
}
...
...
@@ -1099,7 +1099,7 @@ sys_rename (const char * oldname, const char * newname)
(at least if it is a file; don't do this for directories).
However, don't do this if we are just changing the case of the file
name - we will end up deleting the file we are trying to rename! */
newname
=
map_w
in
32_filename
(
newname
,
NULL
);
newname
=
map_w32_filename
(
newname
,
NULL
);
if
(
stricmp
(
newname
,
temp
)
!=
0
&&
(
attr
=
GetFileAttributes
(
newname
))
!=
-
1
&&
(
attr
&
FILE_ATTRIBUTE_DIRECTORY
)
==
0
)
...
...
@@ -1114,13 +1114,13 @@ sys_rename (const char * oldname, const char * newname)
int
sys_rmdir
(
const
char
*
path
)
{
return
_rmdir
(
map_w
in
32_filename
(
path
,
NULL
));
return
_rmdir
(
map_w32_filename
(
path
,
NULL
));
}
int
sys_unlink
(
const
char
*
path
)
{
return
_unlink
(
map_w
in
32_filename
(
path
,
NULL
));
return
_unlink
(
map_w32_filename
(
path
,
NULL
));
}
static
FILETIME
utc_base_ft
;
...
...
@@ -1218,7 +1218,7 @@ generate_inode_val (const char * name)
GetFullPathName
(
name
,
sizeof
(
fullname
),
fullname
,
&
p
);
get_volume_info
(
fullname
,
&
p
);
/* Normal W
in
32 filesystems are still case insensitive. */
/* Normal W32 filesystems are still case insensitive. */
_strlwr
(
p
);
hash
=
hashval
(
p
);
return
(
_ino_t
)
(
hash
^
(
hash
>>
16
));
...
...
@@ -1243,7 +1243,7 @@ stat (const char * path, struct stat * buf)
return
-
1
;
}
name
=
(
char
*
)
map_w
in
32_filename
(
path
,
&
path
);
name
=
(
char
*
)
map_w32_filename
(
path
,
&
path
);
/* must be valid filename, no wild cards */
if
(
strchr
(
name
,
'*'
)
||
strchr
(
name
,
'?'
))
{
...
...
@@ -1340,7 +1340,7 @@ stat (const char * path, struct stat * buf)
buf
->
st_uid
=
the_passwd
.
pw_uid
;
buf
->
st_gid
=
the_passwd
.
pw_gid
;
/* volume_info is set indirectly by map_w
in
32_filename */
/* volume_info is set indirectly by map_w32_filename */
buf
->
st_dev
=
volume_info
.
serialnum
;
buf
->
st_rdev
=
volume_info
.
serialnum
;
...
...
@@ -1932,7 +1932,7 @@ sys_pipe (int * phandles)
}
/* From ntproc.c */
extern
Lisp_Object
Vw
in
32_pipe_read_delay
;
extern
Lisp_Object
Vw32_pipe_read_delay
;
/* Function to do blocking read of one byte, needed to implement
select. It is only allowed on sockets and pipes. */
...
...
@@ -1969,11 +1969,11 @@ _sys_read_ahead (int fd)
connects DOS programs to pipes by making the pipe appear to be
the normal console stdout - as a result most DOS programs will
write to stdout without buffering, ie. one character at a
time. Even some W
in
32 programs do this - "dir" in a command
time. Even some W32 programs do this - "dir" in a command
shell on NT is very slow if we don't do this. */
if
(
rc
>
0
)
{
int
wait
=
XINT
(
Vw
in
32_pipe_read_delay
);
int
wait
=
XINT
(
Vw32_pipe_read_delay
);
if
(
wait
>
0
)
Sleep
(
wait
);
...
...
@@ -2165,7 +2165,7 @@ init_ntproc ()
#ifdef HAVE_SOCKETS
/* Initialise the socket interface now if available and requested by
the user by defining PRELOAD_WINSOCK; otherwise loading will be
delayed until open-network-stream is called (w
in
32-has-winsock can
delayed until open-network-stream is called (w32-has-winsock can
also be used to dynamically load or reload winsock).
Conveniently, init_environment is called before us, so
...
...
@@ -2238,7 +2238,7 @@ init_ntproc ()
}
/* Restrict Emacs to running only one DOS program at a time (with any
number of W
in
32 programs). This is to prevent the user from
number of W32 programs). This is to prevent the user from
running into problems with DOS programs being run in the same VDM
under both Windows 95 and Windows NT.
...
...
src/w32.h
View file @
fbd6baed
...
...
@@ -119,7 +119,7 @@ extern void reset_standard_handles (int in, int out,
int
err
,
HANDLE
handles
[
4
]);
/* Return the string resource associated with KEY of type TYPE. */
extern
LPBYTE
nt
_get_resource
(
char
*
key
,
LPDWORD
type
);
extern
LPBYTE
w32
_get_resource
(
char
*
key
,
LPDWORD
type
);
extern
void
init_ntproc
();
extern
void
term_ntproc
();
...
...
src/w32console.c
View file @
fbd6baed
...
...
@@ -58,7 +58,7 @@ static void reassert_line_highlight (int, int);
static
void
insert_glyphs
(
GLYPH
*
start
,
int
len
);
static
void
write_glyphs
(
GLYPH
*
string
,
int
len
);
static
void
delete_glyphs
(
int
n
);
void
nt
_ring_bell
(
void
);
void
w32_sys
_ring_bell
(
void
);
static
void
reset_terminal_modes
(
void
);
static
void
set_terminal_modes
(
void
);
static
void
set_terminal_window
(
int
size
);
...
...
@@ -193,7 +193,7 @@ ins_del_lines (int vpos, int n)
ScrollConsoleScreenBuffer
(
cur_screen
,
&
scroll
,
NULL
,
dest
,
&
fill
);
/* Here we have to deal with a w
in
32 console flake: If the scroll
/* Here we have to deal with a w32 console flake: If the scroll
region looks like abc and we scroll c to a and fill with d we get
cbd... if we scroll block c one line at a time to a, we get cdd...
Emacs expects cdd consistently... So we have to deal with that
...
...
@@ -418,7 +418,7 @@ delete_glyphs (int n)
static
unsigned
int
sound_type
=
0xFFFFFFFF
;
void
nt
_ring_bell
(
void
)
w32_sys
_ring_bell
(
void
)
{
if
(
sound_type
==
0xFFFFFFFF
)
Beep
(
666
,
100
);
...
...
@@ -554,15 +554,15 @@ initialize_win_nt_display (void)
insert_glyphs_hook
=
(
term_hook
)
insert_glyphs
;
write_glyphs_hook
=
(
term_hook
)
write_glyphs
;
delete_glyphs_hook
=
(
term_hook
)
delete_glyphs
;
ring_bell_hook
=
(
term_hook
)
nt
_ring_bell
;
ring_bell_hook
=
(
term_hook
)
w32_sys
_ring_bell
;
reset_terminal_modes_hook
=
(
term_hook
)
reset_terminal_modes
;
set_terminal_modes_hook
=
(
term_hook
)
set_terminal_modes
;
set_terminal_window_hook
=
(
term_hook
)
set_terminal_window
;
update_begin_hook
=
(
term_hook
)
update_begin
;
update_end_hook
=
(
term_hook
)
update_end
;
read_socket_hook
=
w
in
32_read_socket
;
mouse_position_hook
=
w
in
32_mouse_position
;
read_socket_hook
=
w32
_console
_read_socket
;
mouse_position_hook
=
w32_mouse_position
;
prev_screen
=
GetStdHandle
(
STD_OUTPUT_HANDLE
);
...
...
src/w32faces.c
View file @
fbd6baed
/* "Face" primitives.
/* "Face" primitives
under the Win32 API
.
Copyright (C) 1993, 1994, 1995 Free Software Foundation.
This file is part of GNU Emacs.
...
...
@@ -18,7 +18,7 @@ along with GNU Emacs; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* Ported xfaces.c for w
in
32 - Kevin Gallo */
/* Ported xfaces.c for w32 - Kevin Gallo */
#include <sys/types.h>
#include <sys/stat.h>
...
...
@@ -227,7 +227,7 @@ load_font (f, name)
CHECK_STRING
(
name
,
0
);
BLOCK_INPUT
;
font
=
w
in
32_load_font
(
FRAME_W
IN
32_DISPLAY_INFO
(
f
),
(
char
*
)
XSTRING
(
name
)
->
data
);
font
=
w32_load_font
(
FRAME_W32_DISPLAY_INFO
(
f
),
(
char
*
)
XSTRING
(
name
)
->
data
);
UNBLOCK_INPUT
;
if
(
!
font
)
...
...
@@ -245,7 +245,7 @@ unload_font (f, font)
return
;
BLOCK_INPUT
;
w
in
32_unload_font
(
FRAME_W
IN
32_DISPLAY_INFO
(
f
),
font
);
w32_unload_font
(
FRAME_W32_DISPLAY_INFO
(
f
),
font
);
UNBLOCK_INPUT
;
}
...
...
@@ -379,7 +379,7 @@ init_frame_faces (f)
result
=
Qnil
;
FOR_EACH_FRAME
(
tail
,
frame
)
if
(
FRAME_W
IN
32_P
(
XFRAME
(
frame
))
if
(
FRAME_W32_P
(
XFRAME
(
frame
))
&&
XFRAME
(
frame
)
!=
f
)
{
result
=
frame
;
...
...
@@ -546,21 +546,21 @@ frame_update_line_height (f)
FRAME_PTR
f
;
{
int
i
;
int
biggest
=
FONT_HEIGHT
(
f
->
output_data
.
w
in
32
->
font
);
int
biggest
=
FONT_HEIGHT
(
f
->
output_data
.
w32
->
font
);
for
(
i
=
0
;
i
<
f
->
output_data
.
w
in
32
->
n_param_faces
;
i
++
)
if
(
f
->
output_data
.
w
in
32
->
param_faces
[
i
]
!=
0
&&
f
->
output_data
.
w
in
32
->
param_faces
[
i
]
->
font
!=
(
XFontStruct
*
)
FACE_DEFAULT
)
for
(
i
=
0
;
i
<
f
->
output_data
.
w32
->
n_param_faces
;
i
++
)
if
(
f
->
output_data
.
w32
->
param_faces
[
i
]
!=
0
&&
f
->
output_data
.
w32
->
param_faces
[
i
]
->
font
!=
(
XFontStruct
*
)
FACE_DEFAULT
)
{
int
height
=
FONT_HEIGHT
(
f
->
output_data
.
w
in
32
->
param_faces
[
i
]
->
font
);
int
height
=
FONT_HEIGHT
(
f
->
output_data
.
w32
->
param_faces
[
i
]
->
font
);
if
(
height
>
biggest
)
biggest
=
height
;
}
if
(
biggest
==
f
->
output_data
.
w
in
32
->
line_height
)
if
(
biggest
==
f
->
output_data
.
w32
->
line_height
)
return
0
;
f
->
output_data
.
w
in
32
->
line_height
=
biggest
;
f
->
output_data
.
w32
->
line_height
=
biggest
;
return
1
;
}
...
...
@@ -902,7 +902,7 @@ DEFUN ("make-face-internal", Fmake_face_internal, Smake_face_internal, 1, 1, 0,
FOR_EACH_FRAME
(
rest
,
frame
)
{
if
(
FRAME_W
IN
32_P
(
XFRAME
(
frame
)))
if
(
FRAME_W32_P
(
XFRAME
(
frame
)))
ensure_face_ready
(
XFRAME
(
frame
),
id
);
}
return
Qnil
;
...
...
@@ -929,7 +929,7 @@ DEFUN ("set-face-attribute-internal", Fset_face_attribute_internal,
if
(
id
<
0
||
id
>=
next_face_id
)
error
(
"Face id out of range"
);
if
(
!
FRAME_W
IN
32_P
(
f
))
if
(
!
FRAME_W32_P
(
f
))
return
Qnil
;
ensure_face_ready
(
f
,
id
);
...
...
@@ -938,7 +938,7 @@ DEFUN ("set-face-attribute-internal", Fset_face_attribute_internal,
if
(
EQ
(
attr_name
,
intern
(
"font"
)))
{
XFontStruct
*
font
=
load_font
(
f
,
attr_value
);
if
(
face
->
font
!=
f
->
output_data
.
w
in
32
->
font
)
if
(
face
->
font
!=
f
->
output_data
.
w32
->
font
)
unload_font
(
f
,
face
->
font
);
face
->
font
=
font
;
if
(
frame_update_line_height
(
f
))
...
...
@@ -1024,7 +1024,7 @@ face_name_id_number (f, name)
/* Emacs initialization. */
void
syms_of_w
in
32faces
()
syms_of_w32faces
()
{
Qface
=
intern
(
"face"
);
staticpro
(
&
Qface
);
...
...
src/w32fns.c
View file @
fbd6baed
This diff is collapsed.
Click to expand it.
src/w32heap.c
View file @
fbd6baed
...
...
@@ -38,8 +38,8 @@ int edata;
int
etext
;
/* The major and minor versions of NT. */
int
nt
_major_version
;
int
nt
_minor_version
;
int
w32
_major_version
;
int
w32
_minor_version
;
/* Cache information describing the NT system for later use. */
void
...
...
@@ -58,8 +58,8 @@ cache_system_info (void)
/* Cache the version of the operating system. */
version
.
data
=
GetVersion
();
nt
_major_version
=
version
.
info
.
major
;
nt
_minor_version
=
version
.
info
.
minor
;
w32
_major_version
=
version
.
info
.
major
;
w32
_minor_version
=
version
.
info
.
minor
;
/* Cache page size, allocation unit, processor type, etc. */
GetSystemInfo
(
&
sysinfo_cache
);
...
...
src/w32heap.h
View file @
fbd6baed
...
...
@@ -36,8 +36,8 @@ Boston, MA 02111-1307, USA.
#define get_page_size() sysinfo_cache.dwPageSize
#define get_allocation_unit() sysinfo_cache.dwAllocationGranularity
#define get_processor_type() sysinfo_cache.dwProcessorType
#define get_
nt
_major_version()
nt
_major_version
#define get_
nt
_minor_version()
nt
_minor_version
#define get_
w32
_major_version()
w32
_major_version
#define get_
w32
_minor_version()
w32
_minor_version
extern
unsigned
char
*
get_data_start
();
extern
unsigned
char
*
get_data_end
();
...
...
@@ -45,8 +45,8 @@ extern unsigned long data_region_size;
extern
unsigned
long
reserved_heap_size
;
extern
SYSTEM_INFO
sysinfo_cache
;
extern
BOOL
need_to_recreate_heap
;
extern
int
nt
_major_version
;