diff options
| author | Kim F. Storm | 1995-10-11 11:48:52 +0000 |
|---|---|---|
| committer | Kim F. Storm | 1995-10-11 11:48:52 +0000 |
| commit | c429518802207e533958cfeeb7d7b7c6ddc257f7 (patch) | |
| tree | cd5bf9675f7b63b0b1af5a36ac617fd6de9854e8 /src | |
| parent | 3cdde0fbb462282584e04ec3faca043157058fa6 (diff) | |
| download | emacs-c429518802207e533958cfeeb7d7b7c6ddc257f7.tar.gz emacs-c429518802207e533958cfeeb7d7b7c6ddc257f7.zip | |
(init_sys_modes) [!HAVE_X_WINDOWS (MSDOS)]: Always call set_terminal_modes.
(reset_sys_modes) [MSDOS]: Do not look at EMACSCOLORS.
Diffstat (limited to 'src')
| -rw-r--r-- | src/sysdep.c | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/src/sysdep.c b/src/sysdep.c index 0b46d965f25..dc47a4a2a0f 100644 --- a/src/sysdep.c +++ b/src/sysdep.c | |||
| @@ -1469,7 +1469,11 @@ init_sys_modes () | |||
| 1469 | #else | 1469 | #else |
| 1470 | setbuf (stdout, _sobuf); | 1470 | setbuf (stdout, _sobuf); |
| 1471 | #endif | 1471 | #endif |
| 1472 | #ifdef HAVE_X_WINDOWS | ||
| 1473 | /* Emacs' window system on MSDOG uses the `internal terminal' and therefore | ||
| 1474 | needs the initialization code below. */ | ||
| 1472 | if (! read_socket_hook && EQ (Vwindow_system, Qnil)) | 1475 | if (! read_socket_hook && EQ (Vwindow_system, Qnil)) |
| 1476 | #endif | ||
| 1473 | set_terminal_modes (); | 1477 | set_terminal_modes (); |
| 1474 | 1478 | ||
| 1475 | if (term_initted && no_redraw_on_reenter) | 1479 | if (term_initted && no_redraw_on_reenter) |
| @@ -1615,19 +1619,6 @@ reset_sys_modes () | |||
| 1615 | return; | 1619 | return; |
| 1616 | #endif | 1620 | #endif |
| 1617 | cursor_to (FRAME_HEIGHT (selected_frame) - 1, 0); | 1621 | cursor_to (FRAME_HEIGHT (selected_frame) - 1, 0); |
| 1618 | #ifdef MSDOS | ||
| 1619 | if (!EQ (Vwindow_system, Qnil)) | ||
| 1620 | { | ||
| 1621 | char *colors = getenv("EMACSCOLORS"); | ||
| 1622 | int color = 0x07; /* Change to white on black */ | ||
| 1623 | if (colors && strlen (colors) >= 5 && colors[2] == ';') | ||
| 1624 | color = ((colors[4] & 0x07) << 4) || (colors[3] & 0x07); | ||
| 1625 | if ((stdout)->_cnt < 3) fflush(stdout); /* avoid call to _flsbuf */ | ||
| 1626 | putchar ('\e'); | ||
| 1627 | putchar ('A'); | ||
| 1628 | putchar (color); | ||
| 1629 | } | ||
| 1630 | #endif | ||
| 1631 | clear_end_of_line (FRAME_WIDTH (selected_frame)); | 1622 | clear_end_of_line (FRAME_WIDTH (selected_frame)); |
| 1632 | /* clear_end_of_line may move the cursor */ | 1623 | /* clear_end_of_line may move the cursor */ |
| 1633 | cursor_to (FRAME_HEIGHT (selected_frame) - 1, 0); | 1624 | cursor_to (FRAME_HEIGHT (selected_frame) - 1, 0); |