Fix vertical cursor motion when the newline is covered by a display string.
[emacs.git] / src / s / msdos.h
blob29ca0629899b3fd0d56792719adda4d4614e8b10
1 /* System description file for MS-DOS
3 Copyright (C) 1993, 1996-1997, 2001-2011 Free Software Foundation, Inc.
5 This file is part of GNU Emacs.
7 GNU Emacs is free software: you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation, either version 3 of the License, or
10 (at your option) any later version.
12 GNU Emacs is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
20 /* Note: lots of stuff here was taken from s-msdos.h in demacs. */
23 /* Define symbols to identify the version of Unix this is.
24 Define all the symbols that apply correctly. */
25 #ifndef MSDOS
26 #define MSDOS
27 #endif
29 #ifndef __DJGPP__
30 You lose; /* Emacs for DOS must be compiled with DJGPP */
31 #endif
33 #define DOS_NT /* MSDOS or WINDOWSNT */
34 #undef BSD_SYSTEM
36 /* SYSTEM_TYPE should indicate the kind of system you are using.
37 It sets the Lisp variable system-type. */
38 #define SYSTEM_TYPE "ms-dos"
40 /* subprocesses should be defined if you want to have code for
41 asynchronous subprocesses (as used in M-x compile and M-x shell).
42 This is the only system that needs this. */
43 #undef subprocesses
45 /* Here, on a separate page, add any special hacks needed to make
46 Emacs work on this system. For example, you might define certain
47 system call names that don't exist on your system, or that do
48 different things on your system and must be used only through an
49 encapsulation (which you should place, by convention, in sysdep.c). */
51 /* Avoid incompatibilities between gmalloc.c and system header files
52 in how to declare valloc. */
53 #define GMALLOC_INHIBIT_VALLOC
55 /* This overrides the default value on editfns.c, since DJGPP
56 does not have pw->pw_gecos. */
57 #define USER_FULL_NAME (getenv ("NAME"))
59 /* setjmp and longjmp can safely replace _setjmp and _longjmp,
60 but they will run slower. */
61 #define _setjmp setjmp
62 #define _longjmp longjmp
64 #define DATA_START (&etext + 1)
66 #define _NAIVE_DOS_REGS
68 /* command.com does not understand `...` so we define this. */
69 #define SEPCHAR ';'
71 #define NULL_DEVICE "nul"
73 #define HAVE_INVERSE_HYPERBOLIC
74 #define FLOAT_CHECK_DOMAIN
76 /* Start of gnulib-related stuff */
78 /* lib/ftoastr.c wants strtold, but DJGPP only has _strtold. DJGPP >
79 2.03 has it, but it also has _strtold as a stub that jumps to
80 strtold, so use _strtold in all versions. */
81 #define strtold _strtold
83 #if __DJGPP__ > 2 || __DJGPP_MINOR__ > 3
84 # define HAVE_LSTAT 1
85 #else
86 # define lstat stat
87 #endif
89 /* End of gnulib-related stuff. */
91 /* When $TERM is "internal" then this is substituted: */
92 #define INTERNAL_TERMINAL "pc|bios|IBM PC with color display:\
93 :co#80:li#25:Co#16:pa#256:km:ms:cm=<CM>:cl=<CL>:ce=<CE>:\
94 :se=</SO>:so=<SO>:us=<UL>:ue=</UL>:md=<BD>:mh=<DIM>:mb=<BL>:mr=<RV>:me=<NV>:\
95 :AB=<BG %d>:AF=<FG %d>:op=<DefC>:"
97 /* Define this to a function (Fdowncase, Fupcase) if your file system
98 likes that. */
99 #define FILE_SYSTEM_CASE Fmsdos_downcase_filename
101 /* Define this to be the separator between devices and paths. */
102 #define DEVICE_SEP ':'
104 /* We'll support either convention on MSDOG. */
105 #define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\')
106 #define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP (_c_))
109 /* Mode line description of a buffer's type. */
110 #define MODE_LINE_BINARY_TEXT(buf) (NILP(B_(buf,buffer_file_type)) ? "T" : "B")
112 /* We have (the code to control) a mouse. */
113 #define HAVE_MOUSE
115 /* We can use mouse menus. */
116 #define HAVE_MENUS
118 /* Define one of these for easier conditionals. */
119 #ifdef HAVE_X_WINDOWS
120 /* We need a little extra space, see ../../lisp/loadup.el and the
121 commentary below, in the non-X branch. The 140KB number was
122 measured on GNU/Linux and on MS-WIndows. */
123 #define SYSTEM_PURESIZE_EXTRA (-170000+140000)
124 #else
125 /* We need a little extra space, see ../../lisp/loadup.el.
126 As of 20091024, DOS-specific files use up 62KB of pure space. But
127 overall, we end up wasting 130KB of pure space, because
128 BASE_PURESIZE starts at 1.47MB, while we need only 1.3MB (including
129 non-DOS specific files and load history; the latter is about 55K,
130 but depends on the depth of the top-level Emacs directory in the
131 directory tree). Given the unknown policy of different DPMI
132 hosts regarding loading of untouched pages, I'm not going to risk
133 enlarging Emacs footprint by another 100+ KBytes. */
134 #define SYSTEM_PURESIZE_EXTRA (-170000+65000)
135 #endif
137 /* Tell the garbage collector that setjmp is known to save all
138 registers relevant for conservative garbage collection in the jmp_buf. */
139 #define GC_SETJMP_WORKS 1
140 #define GC_MARK_STACK GC_MAKE_GCPROS_NOOPS