diff options
| author | Miles Bader | 2007-10-27 09:12:07 +0000 |
|---|---|---|
| committer | Miles Bader | 2007-10-27 09:12:07 +0000 |
| commit | 18cd1f1a08833b0baad21c1d7b13a6845d95cf57 (patch) | |
| tree | 03f33df7513d15bd5de0348aec35ef82bd061508 /src | |
| parent | 74863e7a78b1c8da1094a8250660a009c3b23015 (diff) | |
| parent | fdc9061358d3654e14bfc1419632e1d6c6c5c13e (diff) | |
| download | emacs-18cd1f1a08833b0baad21c1d7b13a6845d95cf57.tar.gz emacs-18cd1f1a08833b0baad21c1d7b13a6845d95cf57.zip | |
Merge from emacs--devo--0
Patches applied:
* emacs--devo--0 (patch 902-908)
- Update from CVS
- Merge from emacs--rel--22
* emacs--rel--22 (patch 131-137)
- Update from CVS
- Merge from gnus--rel--5.10
* gnus--rel--5.10 (patch 261-262)
- Update from CVS
Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-278
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 120 | ||||
| -rw-r--r-- | src/alloc.c | 75 | ||||
| -rw-r--r-- | src/callproc.c | 2 | ||||
| -rw-r--r-- | src/data.c | 6 | ||||
| -rw-r--r-- | src/dispnew.c | 6 | ||||
| -rw-r--r-- | src/doc.c | 24 | ||||
| -rw-r--r-- | src/emacs.c | 11 | ||||
| -rw-r--r-- | src/eval.c | 9 | ||||
| -rw-r--r-- | src/fileio.c | 10 | ||||
| -rw-r--r-- | src/frame.c | 53 | ||||
| -rw-r--r-- | src/frame.h | 94 | ||||
| -rw-r--r-- | src/keyboard.c | 11 | ||||
| -rw-r--r-- | src/keyboard.h | 6 | ||||
| -rw-r--r-- | src/lisp.h | 6 | ||||
| -rw-r--r-- | src/m/windowsnt.h | 125 | ||||
| -rw-r--r-- | src/macfns.c | 2 | ||||
| -rw-r--r-- | src/macterm.c | 20 | ||||
| -rw-r--r-- | src/macterm.h | 2 | ||||
| -rw-r--r-- | src/minibuf.c | 28 | ||||
| -rw-r--r-- | src/msdos.h | 1 | ||||
| -rw-r--r-- | src/print.c | 39 | ||||
| -rw-r--r-- | src/process.c | 2 | ||||
| -rw-r--r-- | src/s/ms-w32.h | 5 | ||||
| -rw-r--r-- | src/term.c | 1 | ||||
| -rw-r--r-- | src/w32.c | 2 | ||||
| -rw-r--r-- | src/w32fns.c | 7 | ||||
| -rw-r--r-- | src/w32term.c | 1 | ||||
| -rw-r--r-- | src/window.c | 12 | ||||
| -rw-r--r-- | src/xfns.c | 4 | ||||
| -rw-r--r-- | src/xterm.c | 1 | ||||
| -rw-r--r-- | src/xterm.h | 1 |
31 files changed, 361 insertions, 325 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index dda5d8e396d..36e6ca3b00d 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,121 @@ | |||
| 1 | 2007-10-26 Martin Rudalics <rudalics@gmx.at> | ||
| 2 | |||
| 3 | * window.c (window_min_size_2): Don't count header-line. | ||
| 4 | |||
| 5 | 2007-10-26 Dan Nicolaescu <dann@ics.uci.edu> | ||
| 6 | |||
| 7 | * frame.h (struct frame): Move all bit fields after the first bit | ||
| 8 | field to take advantage of the available space. Group all the | ||
| 9 | chars together to reduce wasted space due to padding. | ||
| 10 | |||
| 11 | 2007-10-26 Juanma Barranquero <lekktu@gmail.com> | ||
| 12 | |||
| 13 | * minibuf.c (Fread_minibuffer, Feval_minibuffer): Reflow docstrings. | ||
| 14 | |||
| 15 | * alloc.c (spare_memory, stack_copy, stack_copy_size, ignore_warnings) | ||
| 16 | (Vdead, dont_register_blocks, staticvec, staticidx, interval_block) | ||
| 17 | (n_interval_blocks, init_strings, check_string_bytes, check_sblock) | ||
| 18 | (init_float, free_float, n_cons_blocks, init_cons, all_vectors) | ||
| 19 | (n_vectors, symbol_block, symbol_block_index, symbol_free_list) | ||
| 20 | (n_symbol_blocks, init_symbol, marker_block, marker_free_list) | ||
| 21 | (n_marker_blocks, init_marker, valid_pointer_p, make_pure_float) | ||
| 22 | (last_marked, mark_object_loop_halt): Make static. | ||
| 23 | |||
| 24 | * frame.c (syms_of_frame) <delete-frame-functions>: | ||
| 25 | Fix typo in docstring. | ||
| 26 | |||
| 27 | 2007-10-25 Juanma Barranquero <lekktu@gmail.com> | ||
| 28 | |||
| 29 | * w32.c (init_environment): Fix tiny memory leak. | ||
| 30 | (w32_get_resource): Remove unused variable `ok'. | ||
| 31 | |||
| 32 | 2007-10-25 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 33 | |||
| 34 | Make `window-system' into a keyboard-local variable (rather than | ||
| 35 | frame-local as done originally by multi-tty). | ||
| 36 | |||
| 37 | * keyboard.h (struct kboard): Add Vwindow_system. | ||
| 38 | * keyboard.c (init_kboard): Set a default for Vwindow_system. | ||
| 39 | (mark_kboards): Mark Vwindow_system. | ||
| 40 | |||
| 41 | * dispnew.c (syms_of_display) <window-system>: Declare terminal-local. | ||
| 42 | (init_display): Don't set the obsolete `window-system' frame-param. | ||
| 43 | |||
| 44 | * xterm.c (x_term_init): | ||
| 45 | * w32term.c (w32_create_terminal): | ||
| 46 | * term.c (init_tty): Set Vwindow_system. | ||
| 47 | * macterm.c (mac_create_terminal): Set a keyboard (missing piece of the | ||
| 48 | multi-tty merge maybe?), copied from w32term.c. Set Vwindow_system. | ||
| 49 | |||
| 50 | * xfns.c (Fx_create_frame, x_create_tip_frame): | ||
| 51 | * w32fns.c (Fx_create_frame, x_create_tip_frame): | ||
| 52 | * macfns.c (Fx_create_frame): | ||
| 53 | Don't set the obsolete `window-system' frame-param. | ||
| 54 | |||
| 55 | * frame.h (Qwindow_system): Remove. | ||
| 56 | * frame.c (Qwindow_system): Remove. In `syms_of_frame' as well. | ||
| 57 | (Fmake_terminal_frame): Don't set obsolete `window-system' frame-param. | ||
| 58 | |||
| 59 | 2007-10-24 Richard Stallman <rms@gnu.org> | ||
| 60 | |||
| 61 | * frame.c (x_figure_window_size): For fullscreen case, | ||
| 62 | set USPosition | PPosition without clobbering rest of window_prompting. | ||
| 63 | |||
| 64 | * keyboard.c (Fcurrent_idle_time): Doc fix. | ||
| 65 | |||
| 66 | * print.c (Fwith_output_to_temp_buffer): Doc fix. | ||
| 67 | |||
| 68 | 2007-10-23 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 69 | |||
| 70 | * process.c (unwind_request_sigio): Only define if __ultrix__. | ||
| 71 | |||
| 72 | * callproc.c (child_setup): Remove spurious *. | ||
| 73 | |||
| 74 | * lisp.h (Fget_text_property): Declare. | ||
| 75 | (have_menus_p): Declare it here rather than in sys-dep header files. | ||
| 76 | * macterm.h (have_menus_p): | ||
| 77 | * msdos.h (have_menus_p): | ||
| 78 | * xterm.h (have_menus_p): Remove. | ||
| 79 | |||
| 80 | * data.c (Fmake_variable_buffer_local, Fmake_local_variable) | ||
| 81 | (Fmake_variable_frame_local): Just check the variable's const-ness | ||
| 82 | rather than checking nil or t. | ||
| 83 | |||
| 84 | 2007-10-22 Jason Rumney <jasonr@gnu.org> | ||
| 85 | |||
| 86 | * w32fns.c: Include math.h. | ||
| 87 | (w32_abort): Declaration moved to nt/config.nt. | ||
| 88 | |||
| 89 | * s/ms-w32.h (HAVE_STDLIB_H): Define. | ||
| 90 | (abort): Redefinition moved to nt/config.nt. | ||
| 91 | |||
| 92 | * m/windowsnt.h: Remove. | ||
| 93 | |||
| 94 | 2007-10-22 Juanma Barranquero <lekktu@gmail.com> | ||
| 95 | |||
| 96 | * emacs.c (Fdump_emacs): Fix typo in message. | ||
| 97 | (syms_of_emacs) <kill-emacs-hook>: Fix typo in docstring. | ||
| 98 | <installation-directory>: Reflow docstring. | ||
| 99 | |||
| 100 | 2007-10-22 Juri Linkov <juri@jurta.org> | ||
| 101 | |||
| 102 | * minibuf.c: Allow minibuffer default to be a list of default values. | ||
| 103 | With empty input use the first element of this list as returned default. | ||
| 104 | (string_to_object) | ||
| 105 | (read_minibuf_noninteractive): If defalt is cons, set val to its car. | ||
| 106 | (read_minibuf): If defalt is cons, set histstring to its car. | ||
| 107 | (Fread_string): If default_value is cons, set val to its car. | ||
| 108 | (Fread_buffer): If def is cons, use its car. | ||
| 109 | (Fcompleting_read): If defalt is cons, set val to its car. | ||
| 110 | |||
| 111 | 2007-10-21 Michael Albinus <michael.albinus@gmx.de> | ||
| 112 | |||
| 113 | * fileio.c (Fcopy_file): Call file name handler with preserve_uid_gid. | ||
| 114 | |||
| 115 | 2007-10-20 Juanma Barranquero <lekktu@gmail.com> | ||
| 116 | |||
| 117 | * doc.c (Fdocumentation): Check for advice in all cases. | ||
| 118 | |||
| 1 | 2007-10-19 Chong Yidong <cyd@stupidchicken.com> | 119 | 2007-10-19 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 120 | ||
| 3 | * Makefile.in [HAVE_LIBRESOLV]: Add -lresolv to linker flags. | 121 | * Makefile.in [HAVE_LIBRESOLV]: Add -lresolv to linker flags. |
| @@ -1011,7 +1129,7 @@ | |||
| 1011 | 1129 | ||
| 1012 | * term.c (tty_insert_glyphs): Add missing first parameter. | 1130 | * term.c (tty_insert_glyphs): Add missing first parameter. |
| 1013 | 1131 | ||
| 1014 | 2007-08-29 Karoly Lorentey <karoly@lorentey.hu> | 1132 | 2007-08-29 K,Aa(Broly L$,1 q(Brentey <karoly@lorentey.hu> |
| 1015 | 1133 | ||
| 1016 | * buffer.c (Fbuffer_list, Fbury_buffer): | 1134 | * buffer.c (Fbuffer_list, Fbury_buffer): |
| 1017 | Take frame->buried_buffer_list into account. | 1135 | Take frame->buried_buffer_list into account. |
diff --git a/src/alloc.c b/src/alloc.c index 295da59d026..80abe170748 100644 --- a/src/alloc.c +++ b/src/alloc.c | |||
| @@ -241,7 +241,7 @@ static int total_free_floats, total_floats; | |||
| 241 | out of memory. We keep one large block, four cons-blocks, and | 241 | out of memory. We keep one large block, four cons-blocks, and |
| 242 | two string blocks. */ | 242 | two string blocks. */ |
| 243 | 243 | ||
| 244 | char *spare_memory[7]; | 244 | static char *spare_memory[7]; |
| 245 | 245 | ||
| 246 | /* Amount of spare memory to keep in large reserve block. */ | 246 | /* Amount of spare memory to keep in large reserve block. */ |
| 247 | 247 | ||
| @@ -324,13 +324,13 @@ Lisp_Object Vmemory_signal_data; | |||
| 324 | 324 | ||
| 325 | /* Buffer in which we save a copy of the C stack at each GC. */ | 325 | /* Buffer in which we save a copy of the C stack at each GC. */ |
| 326 | 326 | ||
| 327 | char *stack_copy; | 327 | static char *stack_copy; |
| 328 | int stack_copy_size; | 328 | static int stack_copy_size; |
| 329 | 329 | ||
| 330 | /* Non-zero means ignore malloc warnings. Set during initialization. | 330 | /* Non-zero means ignore malloc warnings. Set during initialization. |
| 331 | Currently not used. */ | 331 | Currently not used. */ |
| 332 | 332 | ||
| 333 | int ignore_warnings; | 333 | static int ignore_warnings; |
| 334 | 334 | ||
| 335 | Lisp_Object Qgc_cons_threshold, Qchar_table_extra_slots; | 335 | Lisp_Object Qgc_cons_threshold, Qchar_table_extra_slots; |
| 336 | 336 | ||
| @@ -397,12 +397,12 @@ void refill_memory_reserve (); | |||
| 397 | /* A unique object in pure space used to make some Lisp objects | 397 | /* A unique object in pure space used to make some Lisp objects |
| 398 | on free lists recognizable in O(1). */ | 398 | on free lists recognizable in O(1). */ |
| 399 | 399 | ||
| 400 | Lisp_Object Vdead; | 400 | static Lisp_Object Vdead; |
| 401 | 401 | ||
| 402 | #ifdef GC_MALLOC_CHECK | 402 | #ifdef GC_MALLOC_CHECK |
| 403 | 403 | ||
| 404 | enum mem_type allocated_mem_type; | 404 | enum mem_type allocated_mem_type; |
| 405 | int dont_register_blocks; | 405 | static int dont_register_blocks; |
| 406 | 406 | ||
| 407 | #endif /* GC_MALLOC_CHECK */ | 407 | #endif /* GC_MALLOC_CHECK */ |
| 408 | 408 | ||
| @@ -502,12 +502,12 @@ struct gcpro *gcprolist; | |||
| 502 | /* Addresses of staticpro'd variables. Initialize it to a nonzero | 502 | /* Addresses of staticpro'd variables. Initialize it to a nonzero |
| 503 | value; otherwise some compilers put it into BSS. */ | 503 | value; otherwise some compilers put it into BSS. */ |
| 504 | 504 | ||
| 505 | #define NSTATICS 0x600 | 505 | #define NSTATICS 1280 |
| 506 | Lisp_Object *staticvec[NSTATICS] = {&Vpurify_flag}; | 506 | static Lisp_Object *staticvec[NSTATICS] = {&Vpurify_flag}; |
| 507 | 507 | ||
| 508 | /* Index of next unused slot in staticvec. */ | 508 | /* Index of next unused slot in staticvec. */ |
| 509 | 509 | ||
| 510 | int staticidx = 0; | 510 | static int staticidx = 0; |
| 511 | 511 | ||
| 512 | static POINTER_TYPE *pure_alloc P_ ((size_t, int)); | 512 | static POINTER_TYPE *pure_alloc P_ ((size_t, int)); |
| 513 | 513 | ||
| @@ -1417,7 +1417,7 @@ struct interval_block | |||
| 1417 | /* Current interval block. Its `next' pointer points to older | 1417 | /* Current interval block. Its `next' pointer points to older |
| 1418 | blocks. */ | 1418 | blocks. */ |
| 1419 | 1419 | ||
| 1420 | struct interval_block *interval_block; | 1420 | static struct interval_block *interval_block; |
| 1421 | 1421 | ||
| 1422 | /* Index in interval_block above of the next unused interval | 1422 | /* Index in interval_block above of the next unused interval |
| 1423 | structure. */ | 1423 | structure. */ |
| @@ -1434,7 +1434,7 @@ INTERVAL interval_free_list; | |||
| 1434 | 1434 | ||
| 1435 | /* Total number of interval blocks now in use. */ | 1435 | /* Total number of interval blocks now in use. */ |
| 1436 | 1436 | ||
| 1437 | int n_interval_blocks; | 1437 | static int n_interval_blocks; |
| 1438 | 1438 | ||
| 1439 | 1439 | ||
| 1440 | /* Initialize interval allocation. */ | 1440 | /* Initialize interval allocation. */ |
| @@ -1756,7 +1756,7 @@ static char string_overrun_cookie[GC_STRING_OVERRUN_COOKIE_SIZE] = | |||
| 1756 | 1756 | ||
| 1757 | /* Initialize string allocation. Called from init_alloc_once. */ | 1757 | /* Initialize string allocation. Called from init_alloc_once. */ |
| 1758 | 1758 | ||
| 1759 | void | 1759 | static void |
| 1760 | init_strings () | 1760 | init_strings () |
| 1761 | { | 1761 | { |
| 1762 | total_strings = total_free_strings = total_string_size = 0; | 1762 | total_strings = total_free_strings = total_string_size = 0; |
| @@ -1773,8 +1773,8 @@ init_strings () | |||
| 1773 | 1773 | ||
| 1774 | static int check_string_bytes_count; | 1774 | static int check_string_bytes_count; |
| 1775 | 1775 | ||
| 1776 | void check_string_bytes P_ ((int)); | 1776 | static void check_string_bytes P_ ((int)); |
| 1777 | void check_sblock P_ ((struct sblock *)); | 1777 | static void check_sblock P_ ((struct sblock *)); |
| 1778 | 1778 | ||
| 1779 | #define CHECK_STRING_BYTES(S) STRING_BYTES (S) | 1779 | #define CHECK_STRING_BYTES(S) STRING_BYTES (S) |
| 1780 | 1780 | ||
| @@ -1795,7 +1795,7 @@ string_bytes (s) | |||
| 1795 | 1795 | ||
| 1796 | /* Check validity of Lisp strings' string_bytes member in B. */ | 1796 | /* Check validity of Lisp strings' string_bytes member in B. */ |
| 1797 | 1797 | ||
| 1798 | void | 1798 | static void |
| 1799 | check_sblock (b) | 1799 | check_sblock (b) |
| 1800 | struct sblock *b; | 1800 | struct sblock *b; |
| 1801 | { | 1801 | { |
| @@ -1829,7 +1829,7 @@ check_sblock (b) | |||
| 1829 | non-zero means check all strings, otherwise check only most | 1829 | non-zero means check all strings, otherwise check only most |
| 1830 | recently allocated strings. Used for hunting a bug. */ | 1830 | recently allocated strings. Used for hunting a bug. */ |
| 1831 | 1831 | ||
| 1832 | void | 1832 | static void |
| 1833 | check_string_bytes (all_p) | 1833 | check_string_bytes (all_p) |
| 1834 | int all_p; | 1834 | int all_p; |
| 1835 | { | 1835 | { |
| @@ -2582,7 +2582,7 @@ struct Lisp_Float *float_free_list; | |||
| 2582 | 2582 | ||
| 2583 | /* Initialize float allocation. */ | 2583 | /* Initialize float allocation. */ |
| 2584 | 2584 | ||
| 2585 | void | 2585 | static void |
| 2586 | init_float () | 2586 | init_float () |
| 2587 | { | 2587 | { |
| 2588 | float_block = NULL; | 2588 | float_block = NULL; |
| @@ -2594,7 +2594,7 @@ init_float () | |||
| 2594 | 2594 | ||
| 2595 | /* Explicitly free a float cell by putting it on the free-list. */ | 2595 | /* Explicitly free a float cell by putting it on the free-list. */ |
| 2596 | 2596 | ||
| 2597 | void | 2597 | static void |
| 2598 | free_float (ptr) | 2598 | free_float (ptr) |
| 2599 | struct Lisp_Float *ptr; | 2599 | struct Lisp_Float *ptr; |
| 2600 | { | 2600 | { |
| @@ -2701,12 +2701,12 @@ struct Lisp_Cons *cons_free_list; | |||
| 2701 | 2701 | ||
| 2702 | /* Total number of cons blocks now in use. */ | 2702 | /* Total number of cons blocks now in use. */ |
| 2703 | 2703 | ||
| 2704 | int n_cons_blocks; | 2704 | static int n_cons_blocks; |
| 2705 | 2705 | ||
| 2706 | 2706 | ||
| 2707 | /* Initialize cons allocation. */ | 2707 | /* Initialize cons allocation. */ |
| 2708 | 2708 | ||
| 2709 | void | 2709 | static void |
| 2710 | init_cons () | 2710 | init_cons () |
| 2711 | { | 2711 | { |
| 2712 | cons_block = NULL; | 2712 | cons_block = NULL; |
| @@ -2903,11 +2903,11 @@ DEFUN ("make-list", Fmake_list, Smake_list, 2, 2, 0, | |||
| 2903 | 2903 | ||
| 2904 | /* Singly-linked list of all vectors. */ | 2904 | /* Singly-linked list of all vectors. */ |
| 2905 | 2905 | ||
| 2906 | struct Lisp_Vector *all_vectors; | 2906 | static struct Lisp_Vector *all_vectors; |
| 2907 | 2907 | ||
| 2908 | /* Total number of vector-like objects now in use. */ | 2908 | /* Total number of vector-like objects now in use. */ |
| 2909 | 2909 | ||
| 2910 | int n_vectors; | 2910 | static int n_vectors; |
| 2911 | 2911 | ||
| 2912 | 2912 | ||
| 2913 | /* Value is a pointer to a newly allocated Lisp_Vector structure | 2913 | /* Value is a pointer to a newly allocated Lisp_Vector structure |
| @@ -3157,21 +3157,21 @@ struct symbol_block | |||
| 3157 | /* Current symbol block and index of first unused Lisp_Symbol | 3157 | /* Current symbol block and index of first unused Lisp_Symbol |
| 3158 | structure in it. */ | 3158 | structure in it. */ |
| 3159 | 3159 | ||
| 3160 | struct symbol_block *symbol_block; | 3160 | static struct symbol_block *symbol_block; |
| 3161 | int symbol_block_index; | 3161 | static int symbol_block_index; |
| 3162 | 3162 | ||
| 3163 | /* List of free symbols. */ | 3163 | /* List of free symbols. */ |
| 3164 | 3164 | ||
| 3165 | struct Lisp_Symbol *symbol_free_list; | 3165 | static struct Lisp_Symbol *symbol_free_list; |
| 3166 | 3166 | ||
| 3167 | /* Total number of symbol blocks now in use. */ | 3167 | /* Total number of symbol blocks now in use. */ |
| 3168 | 3168 | ||
| 3169 | int n_symbol_blocks; | 3169 | static int n_symbol_blocks; |
| 3170 | 3170 | ||
| 3171 | 3171 | ||
| 3172 | /* Initialize symbol allocation. */ | 3172 | /* Initialize symbol allocation. */ |
| 3173 | 3173 | ||
| 3174 | void | 3174 | static void |
| 3175 | init_symbol () | 3175 | init_symbol () |
| 3176 | { | 3176 | { |
| 3177 | symbol_block = NULL; | 3177 | symbol_block = NULL; |
| @@ -3253,16 +3253,16 @@ struct marker_block | |||
| 3253 | struct marker_block *next; | 3253 | struct marker_block *next; |
| 3254 | }; | 3254 | }; |
| 3255 | 3255 | ||
| 3256 | struct marker_block *marker_block; | 3256 | static struct marker_block *marker_block; |
| 3257 | int marker_block_index; | 3257 | static int marker_block_index; |
| 3258 | 3258 | ||
| 3259 | union Lisp_Misc *marker_free_list; | 3259 | static union Lisp_Misc *marker_free_list; |
| 3260 | 3260 | ||
| 3261 | /* Total number of marker blocks now in use. */ | 3261 | /* Total number of marker blocks now in use. */ |
| 3262 | 3262 | ||
| 3263 | int n_marker_blocks; | 3263 | static int n_marker_blocks; |
| 3264 | 3264 | ||
| 3265 | void | 3265 | static void |
| 3266 | init_marker () | 3266 | init_marker () |
| 3267 | { | 3267 | { |
| 3268 | marker_block = NULL; | 3268 | marker_block = NULL; |
| @@ -4559,7 +4559,7 @@ mark_stack () | |||
| 4559 | 4559 | ||
| 4560 | 4560 | ||
| 4561 | /* Determine whether it is safe to access memory at address P. */ | 4561 | /* Determine whether it is safe to access memory at address P. */ |
| 4562 | int | 4562 | static int |
| 4563 | valid_pointer_p (p) | 4563 | valid_pointer_p (p) |
| 4564 | void *p; | 4564 | void *p; |
| 4565 | { | 4565 | { |
| @@ -4855,7 +4855,7 @@ pure_cons (car, cdr) | |||
| 4855 | 4855 | ||
| 4856 | /* Value is a float object with value NUM allocated from pure space. */ | 4856 | /* Value is a float object with value NUM allocated from pure space. */ |
| 4857 | 4857 | ||
| 4858 | Lisp_Object | 4858 | static Lisp_Object |
| 4859 | make_pure_float (num) | 4859 | make_pure_float (num) |
| 4860 | double num; | 4860 | double num; |
| 4861 | { | 4861 | { |
| @@ -5381,14 +5381,14 @@ mark_image_cache (f) | |||
| 5381 | all the references contained in it. */ | 5381 | all the references contained in it. */ |
| 5382 | 5382 | ||
| 5383 | #define LAST_MARKED_SIZE 500 | 5383 | #define LAST_MARKED_SIZE 500 |
| 5384 | Lisp_Object last_marked[LAST_MARKED_SIZE]; | 5384 | static Lisp_Object last_marked[LAST_MARKED_SIZE]; |
| 5385 | int last_marked_index; | 5385 | int last_marked_index; |
| 5386 | 5386 | ||
| 5387 | /* For debugging--call abort when we cdr down this many | 5387 | /* For debugging--call abort when we cdr down this many |
| 5388 | links of a list, in mark_object. In debugging, | 5388 | links of a list, in mark_object. In debugging, |
| 5389 | the call to abort will hit a breakpoint. | 5389 | the call to abort will hit a breakpoint. |
| 5390 | Normally this is zero and the check never goes off. */ | 5390 | Normally this is zero and the check never goes off. */ |
| 5391 | int mark_object_loop_halt; | 5391 | static int mark_object_loop_halt; |
| 5392 | 5392 | ||
| 5393 | /* Return non-zero if the object was not yet marked. */ | 5393 | /* Return non-zero if the object was not yet marked. */ |
| 5394 | static int | 5394 | static int |
| @@ -5403,7 +5403,7 @@ mark_vectorlike (ptr) | |||
| 5403 | VECTOR_MARK (ptr); /* Else mark it */ | 5403 | VECTOR_MARK (ptr); /* Else mark it */ |
| 5404 | if (size & PSEUDOVECTOR_FLAG) | 5404 | if (size & PSEUDOVECTOR_FLAG) |
| 5405 | size &= PSEUDOVECTOR_SIZE_MASK; | 5405 | size &= PSEUDOVECTOR_SIZE_MASK; |
| 5406 | 5406 | ||
| 5407 | /* Note that this size is not the memory-footprint size, but only | 5407 | /* Note that this size is not the memory-footprint size, but only |
| 5408 | the number of Lisp_Object fields that we should trace. | 5408 | the number of Lisp_Object fields that we should trace. |
| 5409 | The distinction is used e.g. by Lisp_Process which places extra | 5409 | The distinction is used e.g. by Lisp_Process which places extra |
| @@ -6251,6 +6251,7 @@ Frames, windows, buffers, and subprocesses count as vectors | |||
| 6251 | } | 6251 | } |
| 6252 | 6252 | ||
| 6253 | int suppress_checking; | 6253 | int suppress_checking; |
| 6254 | |||
| 6254 | void | 6255 | void |
| 6255 | die (msg, file, line) | 6256 | die (msg, file, line) |
| 6256 | const char *msg; | 6257 | const char *msg; |
diff --git a/src/callproc.c b/src/callproc.c index 8a8052c0019..567fe3a284d 100644 --- a/src/callproc.c +++ b/src/callproc.c | |||
| @@ -1276,7 +1276,7 @@ child_setup (in, out, err, new_argv, set_pgrp, current_dir) | |||
| 1276 | while (*p != 0) | 1276 | while (*p != 0) |
| 1277 | { | 1277 | { |
| 1278 | while (*q != 0 && strchr (*q, '=') == NULL) | 1278 | while (*q != 0 && strchr (*q, '=') == NULL) |
| 1279 | *q++; | 1279 | q++; |
| 1280 | *p = *q++; | 1280 | *p = *q++; |
| 1281 | if (*p != 0) | 1281 | if (*p != 0) |
| 1282 | p++; | 1282 | p++; |
diff --git a/src/data.c b/src/data.c index 3139af1e001..e02e22aa0e3 100644 --- a/src/data.c +++ b/src/data.c | |||
| @@ -1521,7 +1521,7 @@ The function `default-value' gets the default value and `set-default' sets it. | |||
| 1521 | variable = indirect_variable (variable); | 1521 | variable = indirect_variable (variable); |
| 1522 | 1522 | ||
| 1523 | valcontents = SYMBOL_VALUE (variable); | 1523 | valcontents = SYMBOL_VALUE (variable); |
| 1524 | if (EQ (variable, Qnil) || EQ (variable, Qt) || KBOARD_OBJFWDP (valcontents)) | 1524 | if (XSYMBOL (variable)->constant || KBOARD_OBJFWDP (valcontents)) |
| 1525 | error ("Symbol %s may not be buffer-local", SDATA (SYMBOL_NAME (variable))); | 1525 | error ("Symbol %s may not be buffer-local", SDATA (SYMBOL_NAME (variable))); |
| 1526 | 1526 | ||
| 1527 | if (BUFFER_OBJFWDP (valcontents)) | 1527 | if (BUFFER_OBJFWDP (valcontents)) |
| @@ -1578,7 +1578,7 @@ Instead, use `add-hook' and specify t for the LOCAL argument. */) | |||
| 1578 | variable = indirect_variable (variable); | 1578 | variable = indirect_variable (variable); |
| 1579 | 1579 | ||
| 1580 | valcontents = SYMBOL_VALUE (variable); | 1580 | valcontents = SYMBOL_VALUE (variable); |
| 1581 | if (EQ (variable, Qnil) || EQ (variable, Qt) || KBOARD_OBJFWDP (valcontents)) | 1581 | if (XSYMBOL (variable)->constant || KBOARD_OBJFWDP (valcontents)) |
| 1582 | error ("Symbol %s may not be buffer-local", SDATA (SYMBOL_NAME (variable))); | 1582 | error ("Symbol %s may not be buffer-local", SDATA (SYMBOL_NAME (variable))); |
| 1583 | 1583 | ||
| 1584 | if ((BUFFER_LOCAL_VALUEP (valcontents) | 1584 | if ((BUFFER_LOCAL_VALUEP (valcontents) |
| @@ -1733,7 +1733,7 @@ Buffer-local bindings take precedence over frame-local bindings. */) | |||
| 1733 | variable = indirect_variable (variable); | 1733 | variable = indirect_variable (variable); |
| 1734 | 1734 | ||
| 1735 | valcontents = SYMBOL_VALUE (variable); | 1735 | valcontents = SYMBOL_VALUE (variable); |
| 1736 | if (EQ (variable, Qnil) || EQ (variable, Qt) || KBOARD_OBJFWDP (valcontents) | 1736 | if (XSYMBOL (variable)->constant || KBOARD_OBJFWDP (valcontents) |
| 1737 | || BUFFER_OBJFWDP (valcontents)) | 1737 | || BUFFER_OBJFWDP (valcontents)) |
| 1738 | error ("Symbol %s may not be frame-local", SDATA (SYMBOL_NAME (variable))); | 1738 | error ("Symbol %s may not be frame-local", SDATA (SYMBOL_NAME (variable))); |
| 1739 | 1739 | ||
diff --git a/src/dispnew.c b/src/dispnew.c index 79bb81abfeb..fcf54652115 100644 --- a/src/dispnew.c +++ b/src/dispnew.c | |||
| @@ -6956,7 +6956,6 @@ For types not defined in VMS, use define emacs_term \"TYPE\".\n\ | |||
| 6956 | (*initial_terminal->delete_terminal_hook) (initial_terminal); | 6956 | (*initial_terminal->delete_terminal_hook) (initial_terminal); |
| 6957 | 6957 | ||
| 6958 | /* Update frame parameters to reflect the new type. */ | 6958 | /* Update frame parameters to reflect the new type. */ |
| 6959 | Fmodify_frame_parameters (selected_frame, Fcons (Fcons (Qwindow_system, Qnil), Qnil)); | ||
| 6960 | Fmodify_frame_parameters | 6959 | Fmodify_frame_parameters |
| 6961 | (selected_frame, Fcons (Fcons (Qtty_type, | 6960 | (selected_frame, Fcons (Fcons (Qtty_type, |
| 6962 | Ftty_type (selected_frame)), Qnil)); | 6961 | Ftty_type (selected_frame)), Qnil)); |
| @@ -7106,6 +7105,11 @@ It is up to you to set this variable if your terminal can do that. */); | |||
| 7106 | The value is a symbol--for instance, `x' for X windows. | 7105 | The value is a symbol--for instance, `x' for X windows. |
| 7107 | The value is nil if Emacs is using a text-only terminal. */); | 7106 | The value is nil if Emacs is using a text-only terminal. */); |
| 7108 | 7107 | ||
| 7108 | DEFVAR_KBOARD ("window-system", Vwindow_system, | ||
| 7109 | doc: /* Name of window system through which the selected frame is displayed. | ||
| 7110 | The value is a symbol--for instance, `x' for X windows. | ||
| 7111 | The value is nil if the selected frame is on a text-only-terminal. */); | ||
| 7112 | |||
| 7109 | DEFVAR_LISP ("window-system-version", &Vwindow_system_version, | 7113 | DEFVAR_LISP ("window-system-version", &Vwindow_system_version, |
| 7110 | doc: /* The version number of the window system in use. | 7114 | doc: /* The version number of the window system in use. |
| 7111 | For X windows, this is 10 or 11. */); | 7115 | For X windows, this is 10 or 11. */); |
| @@ -434,18 +434,6 @@ string is passed through `substitute-command-keys'. */) | |||
| 434 | doc = tem; | 434 | doc = tem; |
| 435 | else | 435 | else |
| 436 | return Qnil; | 436 | return Qnil; |
| 437 | |||
| 438 | /* Check for an advised function. Its doc string | ||
| 439 | has an `ad-advice-info' text property. */ | ||
| 440 | if (STRINGP (doc)) | ||
| 441 | { | ||
| 442 | Lisp_Object innerfunc; | ||
| 443 | innerfunc = Fget_text_property (make_number (0), | ||
| 444 | intern ("ad-advice-info"), | ||
| 445 | doc); | ||
| 446 | if (! NILP (innerfunc)) | ||
| 447 | doc = call1 (intern ("ad-make-advised-docstring"), innerfunc); | ||
| 448 | } | ||
| 449 | } | 437 | } |
| 450 | else if (EQ (funcar, Qmacro)) | 438 | else if (EQ (funcar, Qmacro)) |
| 451 | return Fdocumentation (Fcdr (fun), raw); | 439 | return Fdocumentation (Fcdr (fun), raw); |
| @@ -458,6 +446,18 @@ string is passed through `substitute-command-keys'. */) | |||
| 458 | xsignal1 (Qinvalid_function, fun); | 446 | xsignal1 (Qinvalid_function, fun); |
| 459 | } | 447 | } |
| 460 | 448 | ||
| 449 | /* Check for an advised function. Its doc string | ||
| 450 | has an `ad-advice-info' text property. */ | ||
| 451 | if (STRINGP (doc)) | ||
| 452 | { | ||
| 453 | Lisp_Object innerfunc; | ||
| 454 | innerfunc = Fget_text_property (make_number (0), | ||
| 455 | intern ("ad-advice-info"), | ||
| 456 | doc); | ||
| 457 | if (! NILP (innerfunc)) | ||
| 458 | doc = call1 (intern ("ad-make-advised-docstring"), innerfunc); | ||
| 459 | } | ||
| 460 | |||
| 461 | /* If DOC is 0, it's typically because of a dumped file missing | 461 | /* If DOC is 0, it's typically because of a dumped file missing |
| 462 | from the DOC file (bug in src/Makefile.in). */ | 462 | from the DOC file (bug in src/Makefile.in). */ |
| 463 | if (EQ (doc, make_number (0))) | 463 | if (EQ (doc, make_number (0))) |
diff --git a/src/emacs.c b/src/emacs.c index 94357bb69ce..db442c219a4 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -2260,10 +2260,10 @@ You must run Emacs in batch mode in order to dump it. */) | |||
| 2260 | { | 2260 | { |
| 2261 | fprintf (stderr, "**************************************************\n"); | 2261 | fprintf (stderr, "**************************************************\n"); |
| 2262 | fprintf (stderr, "Warning: Your system has a gap between BSS and the\n"); | 2262 | fprintf (stderr, "Warning: Your system has a gap between BSS and the\n"); |
| 2263 | fprintf (stderr, "heap (%lu byte). This usually means that exec-shield\n", | 2263 | fprintf (stderr, "heap (%lu bytes). This usually means that exec-shield\n", |
| 2264 | heap_bss_diff); | 2264 | heap_bss_diff); |
| 2265 | fprintf (stderr, "or something similar is in effect. The dump may\n"); | 2265 | fprintf (stderr, "or something similar is in effect. The dump may\n"); |
| 2266 | fprintf (stderr, "fail because of this. See the section about \n"); | 2266 | fprintf (stderr, "fail because of this. See the section about\n"); |
| 2267 | fprintf (stderr, "exec-shield in etc/PROBLEMS for more information.\n"); | 2267 | fprintf (stderr, "exec-shield in etc/PROBLEMS for more information.\n"); |
| 2268 | fprintf (stderr, "**************************************************\n"); | 2268 | fprintf (stderr, "**************************************************\n"); |
| 2269 | } | 2269 | } |
| @@ -2506,7 +2506,7 @@ Emacs is running. */); | |||
| 2506 | doc: /* Non-nil means Emacs is running without interactive terminal. */); | 2506 | doc: /* Non-nil means Emacs is running without interactive terminal. */); |
| 2507 | 2507 | ||
| 2508 | DEFVAR_LISP ("kill-emacs-hook", &Vkill_emacs_hook, | 2508 | DEFVAR_LISP ("kill-emacs-hook", &Vkill_emacs_hook, |
| 2509 | doc: /* Hook to be run when kill-emacs is called. | 2509 | doc: /* Hook to be run when `kill-emacs' is called. |
| 2510 | Since `kill-emacs' may be invoked when the terminal is disconnected (or | 2510 | Since `kill-emacs' may be invoked when the terminal is disconnected (or |
| 2511 | in other similar situations), functions placed on this hook should not | 2511 | in other similar situations), functions placed on this hook should not |
| 2512 | expect to be able to interact with the user. To ask for confirmation, | 2512 | expect to be able to interact with the user. To ask for confirmation, |
| @@ -2542,9 +2542,8 @@ The value is nil if that directory's name is not known. */); | |||
| 2542 | 2542 | ||
| 2543 | DEFVAR_LISP ("installation-directory", &Vinstallation_directory, | 2543 | DEFVAR_LISP ("installation-directory", &Vinstallation_directory, |
| 2544 | doc: /* A directory within which to look for the `lib-src' and `etc' directories. | 2544 | doc: /* A directory within which to look for the `lib-src' and `etc' directories. |
| 2545 | This is non-nil when we can't find those directories in their standard | 2545 | This is non-nil when we can't find those directories in their standard installed |
| 2546 | installed locations, but we can find them | 2546 | locations, but we can find them near where the Emacs executable was found. */); |
| 2547 | near where the Emacs executable was found. */); | ||
| 2548 | Vinstallation_directory = Qnil; | 2547 | Vinstallation_directory = Qnil; |
| 2549 | 2548 | ||
| 2550 | DEFVAR_LISP ("system-messages-locale", &Vsystem_messages_locale, | 2549 | DEFVAR_LISP ("system-messages-locale", &Vsystem_messages_locale, |
diff --git a/src/eval.c b/src/eval.c index eaa1a6855f6..7f5f58a2e81 100644 --- a/src/eval.c +++ b/src/eval.c | |||
| @@ -2194,7 +2194,14 @@ do_autoload (fundef, funname) | |||
| 2194 | /* Preserve the match data. */ | 2194 | /* Preserve the match data. */ |
| 2195 | record_unwind_save_match_data (); | 2195 | record_unwind_save_match_data (); |
| 2196 | 2196 | ||
| 2197 | /* Value saved here is to be restored into Vautoload_queue. */ | 2197 | /* If autoloading gets an error (which includes the error of failing |
| 2198 | to define the function being called), we use Vautoload_queue | ||
| 2199 | to undo function definitions and `provide' calls made by | ||
| 2200 | the function. We do this in the specific case of autoloading | ||
| 2201 | because autoloading is not an explicit request "load this file", | ||
| 2202 | but rather a request to "call this function". | ||
| 2203 | |||
| 2204 | The value saved here is to be restored into Vautoload_queue. */ | ||
| 2198 | record_unwind_protect (un_autoload, Vautoload_queue); | 2205 | record_unwind_protect (un_autoload, Vautoload_queue); |
| 2199 | Vautoload_queue = Qt; | 2206 | Vautoload_queue = Qt; |
| 2200 | Fload (Fcar (Fcdr (fundef)), Qnil, Qt, Qnil, Qt); | 2207 | Fload (Fcar (Fcdr (fundef)), Qnil, Qt, Qnil, Qt); |
diff --git a/src/fileio.c b/src/fileio.c index 8b6f5ef1a84..8155a6e981f 100644 --- a/src/fileio.c +++ b/src/fileio.c | |||
| @@ -2470,8 +2470,8 @@ uid and gid of FILE to NEWNAME. */) | |||
| 2470 | if (NILP (handler)) | 2470 | if (NILP (handler)) |
| 2471 | handler = Ffind_file_name_handler (newname, Qcopy_file); | 2471 | handler = Ffind_file_name_handler (newname, Qcopy_file); |
| 2472 | if (!NILP (handler)) | 2472 | if (!NILP (handler)) |
| 2473 | RETURN_UNGCPRO (call5 (handler, Qcopy_file, file, newname, | 2473 | RETURN_UNGCPRO (call6 (handler, Qcopy_file, file, newname, |
| 2474 | ok_if_already_exists, keep_time)); | 2474 | ok_if_already_exists, keep_time, preserve_uid_gid)); |
| 2475 | 2475 | ||
| 2476 | encoded_file = ENCODE_FILE (file); | 2476 | encoded_file = ENCODE_FILE (file); |
| 2477 | encoded_newname = ENCODE_FILE (newname); | 2477 | encoded_newname = ENCODE_FILE (newname); |
| @@ -4715,8 +4715,8 @@ variable `last-coding-system-used' to the coding system actually used. */) | |||
| 4715 | int opoint_byte = PT_BYTE; | 4715 | int opoint_byte = PT_BYTE; |
| 4716 | int oinserted = ZV - BEGV; | 4716 | int oinserted = ZV - BEGV; |
| 4717 | int ochars_modiff = CHARS_MODIFF; | 4717 | int ochars_modiff = CHARS_MODIFF; |
| 4718 | 4718 | ||
| 4719 | TEMP_SET_PT_BOTH (BEGV, BEGV_BYTE); | 4719 | TEMP_SET_PT_BOTH (BEGV, BEGV_BYTE); |
| 4720 | insval = call3 (Qformat_decode, | 4720 | insval = call3 (Qformat_decode, |
| 4721 | Qnil, make_number (oinserted), visit); | 4721 | Qnil, make_number (oinserted), visit); |
| 4722 | CHECK_NUMBER (insval); | 4722 | CHECK_NUMBER (insval); |
| @@ -4752,7 +4752,7 @@ variable `last-coding-system-used' to the coding system actually used. */) | |||
| 4752 | int opoint_byte = PT_BYTE; | 4752 | int opoint_byte = PT_BYTE; |
| 4753 | int oinserted = ZV - BEGV; | 4753 | int oinserted = ZV - BEGV; |
| 4754 | int ochars_modiff = CHARS_MODIFF; | 4754 | int ochars_modiff = CHARS_MODIFF; |
| 4755 | 4755 | ||
| 4756 | TEMP_SET_PT_BOTH (BEGV, BEGV_BYTE); | 4756 | TEMP_SET_PT_BOTH (BEGV, BEGV_BYTE); |
| 4757 | insval = call1 (XCAR (p), make_number (oinserted)); | 4757 | insval = call1 (XCAR (p), make_number (oinserted)); |
| 4758 | if (!NILP (insval)) | 4758 | if (!NILP (insval)) |
diff --git a/src/frame.c b/src/frame.c index 5c89c96a239..eecc6878c55 100644 --- a/src/frame.c +++ b/src/frame.c | |||
| @@ -114,7 +114,6 @@ Lisp_Object Qleft_fringe, Qright_fringe; | |||
| 114 | Lisp_Object Qbuffer_predicate, Qbuffer_list, Qburied_buffer_list; | 114 | Lisp_Object Qbuffer_predicate, Qbuffer_list, Qburied_buffer_list; |
| 115 | Lisp_Object Qtty_color_mode; | 115 | Lisp_Object Qtty_color_mode; |
| 116 | Lisp_Object Qtty, Qtty_type; | 116 | Lisp_Object Qtty, Qtty_type; |
| 117 | Lisp_Object Qwindow_system; | ||
| 118 | 117 | ||
| 119 | Lisp_Object Qfullscreen, Qfullwidth, Qfullheight, Qfullboth; | 118 | Lisp_Object Qfullscreen, Qfullwidth, Qfullheight, Qfullboth; |
| 120 | #ifdef USE_FONT_BACKEND | 119 | #ifdef USE_FONT_BACKEND |
| @@ -268,7 +267,7 @@ FRAME defaults to the currently selected frame. */) | |||
| 268 | return Qnil; | 267 | return Qnil; |
| 269 | else | 268 | else |
| 270 | return type; | 269 | return type; |
| 271 | } | 270 | } |
| 272 | 271 | ||
| 273 | struct frame * | 272 | struct frame * |
| 274 | make_frame (mini_p) | 273 | make_frame (mini_p) |
| @@ -530,6 +529,7 @@ make_initial_frame (void) | |||
| 530 | { | 529 | { |
| 531 | initial_kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); | 530 | initial_kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); |
| 532 | init_kboard (initial_kboard); | 531 | init_kboard (initial_kboard); |
| 532 | /* Leave Vwindow_system at its `t' default for now. */ | ||
| 533 | initial_kboard->next_kboard = all_kboards; | 533 | initial_kboard->next_kboard = all_kboards; |
| 534 | all_kboards = initial_kboard; | 534 | all_kboards = initial_kboard; |
| 535 | } | 535 | } |
| @@ -556,10 +556,10 @@ make_initial_frame (void) | |||
| 556 | f->terminal = terminal; | 556 | f->terminal = terminal; |
| 557 | f->terminal->reference_count++; | 557 | f->terminal->reference_count++; |
| 558 | f->output_data.nothing = 0; | 558 | f->output_data.nothing = 0; |
| 559 | 559 | ||
| 560 | FRAME_FOREGROUND_PIXEL (f) = FACE_TTY_DEFAULT_FG_COLOR; | 560 | FRAME_FOREGROUND_PIXEL (f) = FACE_TTY_DEFAULT_FG_COLOR; |
| 561 | FRAME_BACKGROUND_PIXEL (f) = FACE_TTY_DEFAULT_BG_COLOR; | 561 | FRAME_BACKGROUND_PIXEL (f) = FACE_TTY_DEFAULT_BG_COLOR; |
| 562 | 562 | ||
| 563 | FRAME_CAN_HAVE_SCROLL_BARS (f) = 0; | 563 | FRAME_CAN_HAVE_SCROLL_BARS (f) = 0; |
| 564 | FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_none; | 564 | FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_none; |
| 565 | 565 | ||
| @@ -621,10 +621,10 @@ make_terminal_frame (struct terminal *terminal) | |||
| 621 | f->terminal = terminal; | 621 | f->terminal = terminal; |
| 622 | f->terminal->reference_count++; | 622 | f->terminal->reference_count++; |
| 623 | create_tty_output (f); | 623 | create_tty_output (f); |
| 624 | 624 | ||
| 625 | FRAME_FOREGROUND_PIXEL (f) = FACE_TTY_DEFAULT_FG_COLOR; | 625 | FRAME_FOREGROUND_PIXEL (f) = FACE_TTY_DEFAULT_FG_COLOR; |
| 626 | FRAME_BACKGROUND_PIXEL (f) = FACE_TTY_DEFAULT_BG_COLOR; | 626 | FRAME_BACKGROUND_PIXEL (f) = FACE_TTY_DEFAULT_BG_COLOR; |
| 627 | 627 | ||
| 628 | FRAME_CAN_HAVE_SCROLL_BARS (f) = 0; | 628 | FRAME_CAN_HAVE_SCROLL_BARS (f) = 0; |
| 629 | FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_none; | 629 | FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_none; |
| 630 | 630 | ||
| @@ -632,10 +632,10 @@ make_terminal_frame (struct terminal *terminal) | |||
| 632 | if (FRAMEP (FRAME_TTY (f)->top_frame) | 632 | if (FRAMEP (FRAME_TTY (f)->top_frame) |
| 633 | && FRAME_LIVE_P (XFRAME (FRAME_TTY (f)->top_frame))) | 633 | && FRAME_LIVE_P (XFRAME (FRAME_TTY (f)->top_frame))) |
| 634 | XFRAME (FRAME_TTY (f)->top_frame)->async_visible = 2; /* obscured */ | 634 | XFRAME (FRAME_TTY (f)->top_frame)->async_visible = 2; /* obscured */ |
| 635 | 635 | ||
| 636 | FRAME_TTY (f)->top_frame = frame; | 636 | FRAME_TTY (f)->top_frame = frame; |
| 637 | } | 637 | } |
| 638 | 638 | ||
| 639 | #ifdef CANNOT_DUMP | 639 | #ifdef CANNOT_DUMP |
| 640 | FRAME_FOREGROUND_PIXEL(f) = FACE_TTY_DEFAULT_FG_COLOR; | 640 | FRAME_FOREGROUND_PIXEL(f) = FACE_TTY_DEFAULT_FG_COLOR; |
| 641 | FRAME_BACKGROUND_PIXEL(f) = FACE_TTY_DEFAULT_BG_COLOR; | 641 | FRAME_BACKGROUND_PIXEL(f) = FACE_TTY_DEFAULT_BG_COLOR; |
| @@ -719,7 +719,7 @@ affects all frames on the same terminal device. */) | |||
| 719 | #endif | 719 | #endif |
| 720 | #endif | 720 | #endif |
| 721 | #endif /* not MSDOS */ | 721 | #endif /* not MSDOS */ |
| 722 | 722 | ||
| 723 | { | 723 | { |
| 724 | Lisp_Object terminal; | 724 | Lisp_Object terminal; |
| 725 | 725 | ||
| @@ -730,9 +730,9 @@ affects all frames on the same terminal device. */) | |||
| 730 | t = get_terminal (terminal, 1); | 730 | t = get_terminal (terminal, 1); |
| 731 | } | 731 | } |
| 732 | } | 732 | } |
| 733 | 733 | ||
| 734 | if (!t) | 734 | if (!t) |
| 735 | { | 735 | { |
| 736 | char *name = 0, *type = 0; | 736 | char *name = 0, *type = 0; |
| 737 | Lisp_Object tty, tty_type; | 737 | Lisp_Object tty, tty_type; |
| 738 | 738 | ||
| @@ -746,7 +746,7 @@ affects all frames on the same terminal device. */) | |||
| 746 | strncpy (name, SDATA (tty), SBYTES (tty)); | 746 | strncpy (name, SDATA (tty), SBYTES (tty)); |
| 747 | name[SBYTES (tty)] = 0; | 747 | name[SBYTES (tty)] = 0; |
| 748 | } | 748 | } |
| 749 | 749 | ||
| 750 | tty_type = get_future_frame_param | 750 | tty_type = get_future_frame_param |
| 751 | (Qtty_type, parms, (FRAME_TERMCAP_P (XFRAME (selected_frame)) | 751 | (Qtty_type, parms, (FRAME_TERMCAP_P (XFRAME (selected_frame)) |
| 752 | ? FRAME_TTY (XFRAME (selected_frame))->type | 752 | ? FRAME_TTY (XFRAME (selected_frame))->type |
| @@ -768,13 +768,12 @@ affects all frames on the same terminal device. */) | |||
| 768 | get_tty_size (fileno (FRAME_TTY (f)->input), &width, &height); | 768 | get_tty_size (fileno (FRAME_TTY (f)->input), &width, &height); |
| 769 | change_frame_size (f, height, width, 0, 0, 0); | 769 | change_frame_size (f, height, width, 0, 0, 0); |
| 770 | } | 770 | } |
| 771 | 771 | ||
| 772 | adjust_glyphs (f); | 772 | adjust_glyphs (f); |
| 773 | calculate_costs (f); | 773 | calculate_costs (f); |
| 774 | XSETFRAME (frame, f); | 774 | XSETFRAME (frame, f); |
| 775 | Fmodify_frame_parameters (frame, Vdefault_frame_alist); | 775 | Fmodify_frame_parameters (frame, Vdefault_frame_alist); |
| 776 | Fmodify_frame_parameters (frame, parms); | 776 | Fmodify_frame_parameters (frame, parms); |
| 777 | Fmodify_frame_parameters (frame, Fcons (Fcons (Qwindow_system, Qnil), Qnil)); | ||
| 778 | Fmodify_frame_parameters (frame, Fcons (Fcons (Qtty_type, | 777 | Fmodify_frame_parameters (frame, Fcons (Fcons (Qtty_type, |
| 779 | build_string (t->display_info.tty->type)), | 778 | build_string (t->display_info.tty->type)), |
| 780 | Qnil)); | 779 | Qnil)); |
| @@ -784,7 +783,7 @@ affects all frames on the same terminal device. */) | |||
| 784 | Qnil)); | 783 | Qnil)); |
| 785 | else | 784 | else |
| 786 | Fmodify_frame_parameters (frame, Fcons (Fcons (Qtty, Qnil), Qnil)); | 785 | Fmodify_frame_parameters (frame, Fcons (Fcons (Qtty, Qnil), Qnil)); |
| 787 | 786 | ||
| 788 | /* Make the frame face alist be frame-specific, so that each | 787 | /* Make the frame face alist be frame-specific, so that each |
| 789 | frame could change its face definitions independently. */ | 788 | frame could change its face definitions independently. */ |
| 790 | f->face_alist = Fcopy_alist (sf->face_alist); | 789 | f->face_alist = Fcopy_alist (sf->face_alist); |
| @@ -1530,7 +1529,7 @@ The functions are run with one arg, the frame to be deleted. */) | |||
| 1530 | 1529 | ||
| 1531 | { | 1530 | { |
| 1532 | struct terminal *terminal = FRAME_TERMINAL (f); | 1531 | struct terminal *terminal = FRAME_TERMINAL (f); |
| 1533 | f->output_data.nothing = 0; | 1532 | f->output_data.nothing = 0; |
| 1534 | f->terminal = 0; /* Now the frame is dead. */ | 1533 | f->terminal = 0; /* Now the frame is dead. */ |
| 1535 | 1534 | ||
| 1536 | /* If needed, delete the terminal that this frame was on. | 1535 | /* If needed, delete the terminal that this frame was on. |
| @@ -2037,7 +2036,7 @@ doesn't support multiple overlapping frames, this function does nothing. */) | |||
| 2037 | CHECK_LIVE_FRAME (frame); | 2036 | CHECK_LIVE_FRAME (frame); |
| 2038 | 2037 | ||
| 2039 | f = XFRAME (frame); | 2038 | f = XFRAME (frame); |
| 2040 | 2039 | ||
| 2041 | /* Do like the documentation says. */ | 2040 | /* Do like the documentation says. */ |
| 2042 | Fmake_frame_visible (frame); | 2041 | Fmake_frame_visible (frame); |
| 2043 | 2042 | ||
| @@ -2057,14 +2056,14 @@ doesn't support multiple overlapping frames, this function does nothing. */) | |||
| 2057 | Lisp_Object frame; | 2056 | Lisp_Object frame; |
| 2058 | { | 2057 | { |
| 2059 | struct frame *f; | 2058 | struct frame *f; |
| 2060 | 2059 | ||
| 2061 | if (NILP (frame)) | 2060 | if (NILP (frame)) |
| 2062 | frame = selected_frame; | 2061 | frame = selected_frame; |
| 2063 | 2062 | ||
| 2064 | CHECK_LIVE_FRAME (frame); | 2063 | CHECK_LIVE_FRAME (frame); |
| 2065 | 2064 | ||
| 2066 | f = XFRAME (frame); | 2065 | f = XFRAME (frame); |
| 2067 | 2066 | ||
| 2068 | if (FRAME_TERMINAL (f)->frame_raise_lower_hook) | 2067 | if (FRAME_TERMINAL (f)->frame_raise_lower_hook) |
| 2069 | (*FRAME_TERMINAL (f)->frame_raise_lower_hook) (f, 0); | 2068 | (*FRAME_TERMINAL (f)->frame_raise_lower_hook) (f, 0); |
| 2070 | 2069 | ||
| @@ -2101,7 +2100,7 @@ The redirection lasts until `redirect-frame-focus' is called to change it. */) | |||
| 2101 | Lisp_Object frame, focus_frame; | 2100 | Lisp_Object frame, focus_frame; |
| 2102 | { | 2101 | { |
| 2103 | struct frame *f; | 2102 | struct frame *f; |
| 2104 | 2103 | ||
| 2105 | /* Note that we don't check for a live frame here. It's reasonable | 2104 | /* Note that we don't check for a live frame here. It's reasonable |
| 2106 | to redirect the focus of a frame you're about to delete, if you | 2105 | to redirect the focus of a frame you're about to delete, if you |
| 2107 | know what other frame should receive those keystrokes. */ | 2106 | know what other frame should receive those keystrokes. */ |
| @@ -2111,7 +2110,7 @@ The redirection lasts until `redirect-frame-focus' is called to change it. */) | |||
| 2111 | CHECK_LIVE_FRAME (focus_frame); | 2110 | CHECK_LIVE_FRAME (focus_frame); |
| 2112 | 2111 | ||
| 2113 | f = XFRAME (frame); | 2112 | f = XFRAME (frame); |
| 2114 | 2113 | ||
| 2115 | f->focus_frame = focus_frame; | 2114 | f->focus_frame = focus_frame; |
| 2116 | 2115 | ||
| 2117 | if (FRAME_TERMINAL (f)->frame_rehighlight_hook) | 2116 | if (FRAME_TERMINAL (f)->frame_rehighlight_hook) |
| @@ -3303,7 +3302,7 @@ x_set_fullscreen (f, new_value, old_value) | |||
| 3303 | else if (EQ (new_value, Qfullheight)) | 3302 | else if (EQ (new_value, Qfullheight)) |
| 3304 | f->want_fullscreen = FULLSCREEN_HEIGHT; | 3303 | f->want_fullscreen = FULLSCREEN_HEIGHT; |
| 3305 | 3304 | ||
| 3306 | if (FRAME_TERMINAL (f)->fullscreen_hook != NULL) | 3305 | if (FRAME_TERMINAL (f)->fullscreen_hook != NULL) |
| 3307 | FRAME_TERMINAL (f)->fullscreen_hook (f); | 3306 | FRAME_TERMINAL (f)->fullscreen_hook (f); |
| 3308 | } | 3307 | } |
| 3309 | 3308 | ||
| @@ -4291,7 +4290,7 @@ x_figure_window_size (f, parms, toolbar_p) | |||
| 4291 | int width, height; | 4290 | int width, height; |
| 4292 | 4291 | ||
| 4293 | /* It takes both for some WM:s to place it where we want */ | 4292 | /* It takes both for some WM:s to place it where we want */ |
| 4294 | window_prompting = USPosition | PPosition; | 4293 | window_prompting |= USPosition | PPosition; |
| 4295 | x_fullscreen_adjust (f, &width, &height, &top, &left); | 4294 | x_fullscreen_adjust (f, &width, &height, &top, &left); |
| 4296 | FRAME_COLS (f) = width; | 4295 | FRAME_COLS (f) = width; |
| 4297 | FRAME_LINES (f) = height; | 4296 | FRAME_LINES (f) = height; |
| @@ -4400,8 +4399,6 @@ syms_of_frame () | |||
| 4400 | staticpro (&Qtty); | 4399 | staticpro (&Qtty); |
| 4401 | Qtty_type = intern ("tty-type"); | 4400 | Qtty_type = intern ("tty-type"); |
| 4402 | staticpro (&Qtty_type); | 4401 | staticpro (&Qtty_type); |
| 4403 | Qwindow_system = intern ("window-system"); | ||
| 4404 | staticpro (&Qwindow_system); | ||
| 4405 | 4402 | ||
| 4406 | Qface_set_after_frame_default = intern ("face-set-after-frame-default"); | 4403 | Qface_set_after_frame_default = intern ("face-set-after-frame-default"); |
| 4407 | staticpro (&Qface_set_after_frame_default); | 4404 | staticpro (&Qface_set_after_frame_default); |
| @@ -4426,7 +4423,7 @@ syms_of_frame () | |||
| 4426 | staticpro (&Qterminal); | 4423 | staticpro (&Qterminal); |
| 4427 | Qterminal_live_p = intern ("terminal-live-p"); | 4424 | Qterminal_live_p = intern ("terminal-live-p"); |
| 4428 | staticpro (&Qterminal_live_p); | 4425 | staticpro (&Qterminal_live_p); |
| 4429 | 4426 | ||
| 4430 | { | 4427 | { |
| 4431 | int i; | 4428 | int i; |
| 4432 | 4429 | ||
| @@ -4528,7 +4525,7 @@ Note that functions in this list may be called twice on the same | |||
| 4528 | frame. In the second invocation, the frame is already deleted, and | 4525 | frame. In the second invocation, the frame is already deleted, and |
| 4529 | the function should do nothing. (You can use `frame-live-p' to check | 4526 | the function should do nothing. (You can use `frame-live-p' to check |
| 4530 | for this.) This wrinkle happens when an earlier function in | 4527 | for this.) This wrinkle happens when an earlier function in |
| 4531 | `delete-frame-functions' (indirectly) calls delete-frame | 4528 | `delete-frame-functions' (indirectly) calls `delete-frame' |
| 4532 | recursively. */); | 4529 | recursively. */); |
| 4533 | Vdelete_frame_functions = Qnil; | 4530 | Vdelete_frame_functions = Qnil; |
| 4534 | 4531 | ||
| @@ -4561,7 +4558,7 @@ automatically. */); | |||
| 4561 | #else | 4558 | #else |
| 4562 | focus_follows_mouse = 0; | 4559 | focus_follows_mouse = 0; |
| 4563 | #endif | 4560 | #endif |
| 4564 | 4561 | ||
| 4565 | staticpro (&Vframe_list); | 4562 | staticpro (&Vframe_list); |
| 4566 | 4563 | ||
| 4567 | defsubr (&Sactive_minibuffer_window); | 4564 | defsubr (&Sactive_minibuffer_window); |
diff --git a/src/frame.h b/src/frame.h index e9be84d8558..7761b7520a3 100644 --- a/src/frame.h +++ b/src/frame.h | |||
| @@ -206,6 +206,30 @@ struct frame | |||
| 206 | be used for output. */ | 206 | be used for output. */ |
| 207 | unsigned glyphs_initialized_p : 1; | 207 | unsigned glyphs_initialized_p : 1; |
| 208 | 208 | ||
| 209 | /* Set to non-zero in change_frame_size when size of frame changed | ||
| 210 | Clear the frame in clear_garbaged_frames if set. */ | ||
| 211 | unsigned resized_p : 1; | ||
| 212 | |||
| 213 | /* Set to non-zero in when we want for force a flush_display in | ||
| 214 | update_frame, usually after resizing the frame. */ | ||
| 215 | unsigned force_flush_display_p : 1; | ||
| 216 | |||
| 217 | /* Set to non-zero if the default face for the frame has been | ||
| 218 | realized. Reset to zero whenever the default face changes. | ||
| 219 | Used to see the difference between a font change and face change. */ | ||
| 220 | unsigned default_face_done_p : 1; | ||
| 221 | |||
| 222 | /* Set to non-zero if this frame has already been hscrolled during | ||
| 223 | current redisplay. */ | ||
| 224 | unsigned already_hscrolled_p : 1; | ||
| 225 | |||
| 226 | /* Set to non-zero when current redisplay has updated frame. */ | ||
| 227 | unsigned updated_p : 1; | ||
| 228 | |||
| 229 | /* Set to non-zero to minimize tool-bar height even when | ||
| 230 | auto-resize-tool-bar is set to grow-only. */ | ||
| 231 | unsigned minimize_tool_bar_window_p : 1; | ||
| 232 | |||
| 209 | #if defined (USE_GTK) || defined (MAC_OS) | 233 | #if defined (USE_GTK) || defined (MAC_OS) |
| 210 | /* Nonzero means using a tool bar that comes from the toolkit. */ | 234 | /* Nonzero means using a tool bar that comes from the toolkit. */ |
| 211 | int external_tool_bar; | 235 | int external_tool_bar; |
| @@ -380,24 +404,6 @@ struct frame | |||
| 380 | support scroll bars. */ | 404 | support scroll bars. */ |
| 381 | char can_have_scroll_bars; | 405 | char can_have_scroll_bars; |
| 382 | 406 | ||
| 383 | /* If can_have_scroll_bars is non-zero, this is non-zero if we should | ||
| 384 | actually display them on this frame. */ | ||
| 385 | enum vertical_scroll_bar_type vertical_scroll_bar_type; | ||
| 386 | |||
| 387 | /* What kind of text cursor should we draw in the future? | ||
| 388 | This should always be filled_box_cursor or bar_cursor. */ | ||
| 389 | enum text_cursor_kinds desired_cursor; | ||
| 390 | |||
| 391 | /* Width of bar cursor (if we are using that). */ | ||
| 392 | int cursor_width; | ||
| 393 | |||
| 394 | /* What kind of text cursor should we draw when the cursor blinks off? | ||
| 395 | This can be filled_box_cursor or bar_cursor or no_cursor. */ | ||
| 396 | enum text_cursor_kinds blink_off_cursor; | ||
| 397 | |||
| 398 | /* Width of bar cursor (if we are using that) for blink-off state. */ | ||
| 399 | int blink_off_cursor_width; | ||
| 400 | |||
| 401 | /* Non-0 means raise this frame to the top of the heap when selected. */ | 407 | /* Non-0 means raise this frame to the top of the heap when selected. */ |
| 402 | char auto_raise; | 408 | char auto_raise; |
| 403 | 409 | ||
| @@ -416,6 +422,28 @@ struct frame | |||
| 416 | /* Nonzero if size of some window on this frame has changed. */ | 422 | /* Nonzero if size of some window on this frame has changed. */ |
| 417 | char window_sizes_changed; | 423 | char window_sizes_changed; |
| 418 | 424 | ||
| 425 | /* Nonzero if the mouse has moved on this display device | ||
| 426 | since the last time we checked. */ | ||
| 427 | char mouse_moved; | ||
| 428 | |||
| 429 | /* If can_have_scroll_bars is non-zero, this is non-zero if we should | ||
| 430 | actually display them on this frame. */ | ||
| 431 | enum vertical_scroll_bar_type vertical_scroll_bar_type; | ||
| 432 | |||
| 433 | /* What kind of text cursor should we draw in the future? | ||
| 434 | This should always be filled_box_cursor or bar_cursor. */ | ||
| 435 | enum text_cursor_kinds desired_cursor; | ||
| 436 | |||
| 437 | /* Width of bar cursor (if we are using that). */ | ||
| 438 | int cursor_width; | ||
| 439 | |||
| 440 | /* What kind of text cursor should we draw when the cursor blinks off? | ||
| 441 | This can be filled_box_cursor or bar_cursor or no_cursor. */ | ||
| 442 | enum text_cursor_kinds blink_off_cursor; | ||
| 443 | |||
| 444 | /* Width of bar cursor (if we are using that) for blink-off state. */ | ||
| 445 | int blink_off_cursor_width; | ||
| 446 | |||
| 419 | /* Storage for messages to this frame. */ | 447 | /* Storage for messages to this frame. */ |
| 420 | char *message_buf; | 448 | char *message_buf; |
| 421 | 449 | ||
| @@ -438,10 +466,6 @@ struct frame | |||
| 438 | /* The baud rate that was used to calculate costs for this frame. */ | 466 | /* The baud rate that was used to calculate costs for this frame. */ |
| 439 | int cost_calculation_baud_rate; | 467 | int cost_calculation_baud_rate; |
| 440 | 468 | ||
| 441 | /* Nonzero if the mouse has moved on this display device | ||
| 442 | since the last time we checked. */ | ||
| 443 | char mouse_moved; | ||
| 444 | |||
| 445 | /* Exponent for gamma correction of colors. 1/(VIEWING_GAMMA * | 469 | /* Exponent for gamma correction of colors. 1/(VIEWING_GAMMA * |
| 446 | SCREEN_GAMMA) where viewing_gamma is 0.4545 and SCREEN_GAMMA is a | 470 | SCREEN_GAMMA) where viewing_gamma is 0.4545 and SCREEN_GAMMA is a |
| 447 | frame parameter. 0 means don't do gamma correction. */ | 471 | frame parameter. 0 means don't do gamma correction. */ |
| @@ -450,33 +474,9 @@ struct frame | |||
| 450 | /* Additional space to put between text lines on this frame. */ | 474 | /* Additional space to put between text lines on this frame. */ |
| 451 | int extra_line_spacing; | 475 | int extra_line_spacing; |
| 452 | 476 | ||
| 453 | /* Set to non-zero in change_frame_size when size of frame changed | ||
| 454 | Clear the frame in clear_garbaged_frames if set. */ | ||
| 455 | unsigned resized_p : 1; | ||
| 456 | |||
| 457 | /* Set to non-zero in when we want for force a flush_display in | ||
| 458 | update_frame, usually after resizing the frame. */ | ||
| 459 | unsigned force_flush_display_p : 1; | ||
| 460 | |||
| 461 | /* All display backends seem to need these two pixel values. */ | 477 | /* All display backends seem to need these two pixel values. */ |
| 462 | unsigned long background_pixel; | 478 | unsigned long background_pixel; |
| 463 | unsigned long foreground_pixel; | 479 | unsigned long foreground_pixel; |
| 464 | |||
| 465 | /* Set to non-zero if the default face for the frame has been | ||
| 466 | realized. Reset to zero whenever the default face changes. | ||
| 467 | Used to see the difference between a font change and face change. */ | ||
| 468 | unsigned default_face_done_p : 1; | ||
| 469 | |||
| 470 | /* Set to non-zero if this frame has already been hscrolled during | ||
| 471 | current redisplay. */ | ||
| 472 | unsigned already_hscrolled_p : 1; | ||
| 473 | |||
| 474 | /* Set to non-zero when current redisplay has updated frame. */ | ||
| 475 | unsigned updated_p : 1; | ||
| 476 | |||
| 477 | /* Set to non-zero to minimize tool-bar height even when | ||
| 478 | auto-resize-tool-bar is set to grow-only. */ | ||
| 479 | unsigned minimize_tool_bar_window_p : 1; | ||
| 480 | }; | 480 | }; |
| 481 | 481 | ||
| 482 | #ifdef MULTI_KBOARD | 482 | #ifdef MULTI_KBOARD |
| @@ -1033,8 +1033,6 @@ extern Lisp_Object Qx_resource_name; | |||
| 1033 | extern Lisp_Object Qleft, Qright, Qtop, Qbox; | 1033 | extern Lisp_Object Qleft, Qright, Qtop, Qbox; |
| 1034 | extern Lisp_Object Qdisplay; | 1034 | extern Lisp_Object Qdisplay; |
| 1035 | 1035 | ||
| 1036 | extern Lisp_Object Qwindow_system; | ||
| 1037 | |||
| 1038 | #ifdef HAVE_WINDOW_SYSTEM | 1036 | #ifdef HAVE_WINDOW_SYSTEM |
| 1039 | 1037 | ||
| 1040 | /* The class of this X application. */ | 1038 | /* The class of this X application. */ |
diff --git a/src/keyboard.c b/src/keyboard.c index 2002aded95d..426ea34e3a4 100644 --- a/src/keyboard.c +++ b/src/keyboard.c | |||
| @@ -4716,12 +4716,14 @@ timer_check (do_it_now) | |||
| 4716 | } | 4716 | } |
| 4717 | 4717 | ||
| 4718 | DEFUN ("current-idle-time", Fcurrent_idle_time, Scurrent_idle_time, 0, 0, 0, | 4718 | DEFUN ("current-idle-time", Fcurrent_idle_time, Scurrent_idle_time, 0, 0, 0, |
| 4719 | doc: /* Return the current length of Emacs idleness. | 4719 | doc: /* Return the current length of Emacs idleness, or nil. |
| 4720 | The value is returned as a list of three integers. The first has the | 4720 | The value when Emacs is idle is a list of three integers. The first has the |
| 4721 | most significant 16 bits of the seconds, while the second has the | 4721 | most significant 16 bits of the seconds, while the second has the |
| 4722 | least significant 16 bits. The third integer gives the microsecond | 4722 | least significant 16 bits. The third integer gives the microsecond |
| 4723 | count. | 4723 | count. |
| 4724 | 4724 | ||
| 4725 | The value when Emacs is not idle is nil. | ||
| 4726 | |||
| 4725 | The microsecond count is zero on systems that do not provide | 4727 | The microsecond count is zero on systems that do not provide |
| 4726 | resolution finer than a second. */) | 4728 | resolution finer than a second. */) |
| 4727 | () | 4729 | () |
| @@ -9186,7 +9188,7 @@ read_key_sequence (keybuf, bufsize, prompt, dont_downcase_last, | |||
| 9186 | from_string = Qnil; | 9188 | from_string = Qnil; |
| 9187 | 9189 | ||
| 9188 | /* The multi-tty merge moved the code below to right after | 9190 | /* The multi-tty merge moved the code below to right after |
| 9189 | `replay_sequence' which caused alll these translation maps to be applied | 9191 | `replay_sequence' which caused all these translation maps to be applied |
| 9190 | repeatedly, even tho their doc says very clearly they are not applied to | 9192 | repeatedly, even tho their doc says very clearly they are not applied to |
| 9191 | their own output. | 9193 | their own output. |
| 9192 | The reason for this move was: "We may switch keyboards between rescans, | 9194 | The reason for this move was: "We may switch keyboards between rescans, |
| @@ -11488,6 +11490,7 @@ init_kboard (kb) | |||
| 11488 | kb->reference_count = 0; | 11490 | kb->reference_count = 0; |
| 11489 | kb->Vsystem_key_alist = Qnil; | 11491 | kb->Vsystem_key_alist = Qnil; |
| 11490 | kb->system_key_syms = Qnil; | 11492 | kb->system_key_syms = Qnil; |
| 11493 | kb->Vwindow_system = Qt; /* Unset. */ | ||
| 11491 | kb->Vinput_decode_map = Fmake_sparse_keymap (Qnil); | 11494 | kb->Vinput_decode_map = Fmake_sparse_keymap (Qnil); |
| 11492 | kb->Vlocal_function_key_map = Fmake_sparse_keymap (Qnil); | 11495 | kb->Vlocal_function_key_map = Fmake_sparse_keymap (Qnil); |
| 11493 | Fset_keymap_parent (kb->Vlocal_function_key_map, Vfunction_key_map); | 11496 | Fset_keymap_parent (kb->Vlocal_function_key_map, Vfunction_key_map); |
| @@ -11570,6 +11573,7 @@ init_keyboard () | |||
| 11570 | #endif | 11573 | #endif |
| 11571 | wipe_kboard (current_kboard); | 11574 | wipe_kboard (current_kboard); |
| 11572 | init_kboard (current_kboard); | 11575 | init_kboard (current_kboard); |
| 11576 | /* Leave Vwindow_system at its `t' default for now. */ | ||
| 11573 | 11577 | ||
| 11574 | if (!noninteractive) | 11578 | if (!noninteractive) |
| 11575 | { | 11579 | { |
| @@ -12465,6 +12469,7 @@ mark_kboards () | |||
| 12465 | mark_object (kb->Vlast_kbd_macro); | 12469 | mark_object (kb->Vlast_kbd_macro); |
| 12466 | mark_object (kb->Vsystem_key_alist); | 12470 | mark_object (kb->Vsystem_key_alist); |
| 12467 | mark_object (kb->system_key_syms); | 12471 | mark_object (kb->system_key_syms); |
| 12472 | mark_object (kb->Vwindow_system); | ||
| 12468 | mark_object (kb->Vinput_decode_map); | 12473 | mark_object (kb->Vinput_decode_map); |
| 12469 | mark_object (kb->Vlocal_function_key_map); | 12474 | mark_object (kb->Vlocal_function_key_map); |
| 12470 | mark_object (kb->Vdefault_minibuffer_frame); | 12475 | mark_object (kb->Vdefault_minibuffer_frame); |
diff --git a/src/keyboard.h b/src/keyboard.h index ae135b30b77..6d046bc98e7 100644 --- a/src/keyboard.h +++ b/src/keyboard.h | |||
| @@ -80,8 +80,7 @@ struct kboard | |||
| 80 | commands that set the prefix argument. */ | 80 | commands that set the prefix argument. */ |
| 81 | Lisp_Object Vlast_command; | 81 | Lisp_Object Vlast_command; |
| 82 | 82 | ||
| 83 | /* Normally same as last-command, but never modified by | 83 | /* Normally same as last-command, but never modified by other commands. */ |
| 84 | other commands. */ | ||
| 85 | Lisp_Object Vreal_last_command; | 84 | Lisp_Object Vreal_last_command; |
| 86 | 85 | ||
| 87 | /* User-supplied table to translate input characters through. */ | 86 | /* User-supplied table to translate input characters through. */ |
| @@ -130,6 +129,9 @@ struct kboard | |||
| 130 | /* Cache for modify_event_symbol. */ | 129 | /* Cache for modify_event_symbol. */ |
| 131 | Lisp_Object system_key_syms; | 130 | Lisp_Object system_key_syms; |
| 132 | 131 | ||
| 132 | /* The kind of display: x, w32, ... */ | ||
| 133 | Lisp_Object Vwindow_system; | ||
| 134 | |||
| 133 | /* Keymap mapping keys to alternative preferred forms. | 135 | /* Keymap mapping keys to alternative preferred forms. |
| 134 | See the DEFVAR for more documentation. */ | 136 | See the DEFVAR for more documentation. */ |
| 135 | Lisp_Object Vlocal_function_key_map; | 137 | Lisp_Object Vlocal_function_key_map; |
diff --git a/src/lisp.h b/src/lisp.h index 8a0b13a72a1..62c629bd4a8 100644 --- a/src/lisp.h +++ b/src/lisp.h | |||
| @@ -3159,6 +3159,7 @@ EXFUN (Fnext_single_char_property_change, 4); | |||
| 3159 | EXFUN (Fprevious_single_property_change, 4); | 3159 | EXFUN (Fprevious_single_property_change, 4); |
| 3160 | EXFUN (Fget_text_property, 3); | 3160 | EXFUN (Fget_text_property, 3); |
| 3161 | EXFUN (Fput_text_property, 5); | 3161 | EXFUN (Fput_text_property, 5); |
| 3162 | EXFUN (Fget_text_property, 3); | ||
| 3162 | EXFUN (Fprevious_char_property_change, 2); | 3163 | EXFUN (Fprevious_char_property_change, 2); |
| 3163 | EXFUN (Fnext_char_property_change, 2); | 3164 | EXFUN (Fnext_char_property_change, 2); |
| 3164 | extern void report_interval_modification P_ ((Lisp_Object, Lisp_Object)); | 3165 | extern void report_interval_modification P_ ((Lisp_Object, Lisp_Object)); |
| @@ -3294,6 +3295,11 @@ extern void syms_of_mac P_ ((void)); | |||
| 3294 | extern void init_mac_osx_environment P_ ((void)); | 3295 | extern void init_mac_osx_environment P_ ((void)); |
| 3295 | #endif /* MAC_OSX */ | 3296 | #endif /* MAC_OSX */ |
| 3296 | #endif /* MAC_OS */ | 3297 | #endif /* MAC_OS */ |
| 3298 | |||
| 3299 | #ifdef HAVE_MENUS | ||
| 3300 | /* Defined in (x|mac|w32)fns.c... */ | ||
| 3301 | extern int have_menus_p P_ ((void)); | ||
| 3302 | #endif | ||
| 3297 | 3303 | ||
| 3298 | /* Nonzero means Emacs has already been initialized. | 3304 | /* Nonzero means Emacs has already been initialized. |
| 3299 | Used during startup to detect startup of dumped Emacs. */ | 3305 | Used during startup to detect startup of dumped Emacs. */ |
diff --git a/src/m/windowsnt.h b/src/m/windowsnt.h deleted file mode 100644 index ddad551c772..00000000000 --- a/src/m/windowsnt.h +++ /dev/null | |||
| @@ -1,125 +0,0 @@ | |||
| 1 | /* Machine description file for Windows NT. | ||
| 2 | |||
| 3 | Copyright (C) 1993, 1994, 2001, 2002, 2003, 2004, | ||
| 4 | 2005, 2006, 2007 Free Software Foundation, Inc. | ||
| 5 | |||
| 6 | This file is part of GNU Emacs. | ||
| 7 | |||
| 8 | GNU Emacs is free software; you can redistribute it and/or modify | ||
| 9 | it under the terms of the GNU General Public License as published by | ||
| 10 | the Free Software Foundation; either version 3, or (at your option) | ||
| 11 | any later version. | ||
| 12 | |||
| 13 | GNU Emacs is distributed in the hope that it will be useful, | ||
| 14 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 16 | GNU General Public License for more details. | ||
| 17 | |||
| 18 | You should have received a copy of the GNU General Public License | ||
| 19 | along with GNU Emacs; see the file COPYING. If not, write to | ||
| 20 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||
| 21 | Boston, MA 02110-1301, USA. */ | ||
| 22 | |||
| 23 | /* The following line tells the configuration script what sort of | ||
| 24 | operating system this machine is likely to run. | ||
| 25 | USUAL-OPSYS="<name of system .h file here, without the s- or .h>" */ | ||
| 26 | |||
| 27 | /* Define BIG_ENDIAN if lowest-numbered byte in a word | ||
| 28 | is the most significant byte. */ | ||
| 29 | |||
| 30 | /* #define BIG_ENDIAN */ | ||
| 31 | |||
| 32 | /* Define NO_ARG_ARRAY if you cannot take the address of the first of a | ||
| 33 | * group of arguments and treat it as an array of the arguments. */ | ||
| 34 | |||
| 35 | #define NO_ARG_ARRAY | ||
| 36 | |||
| 37 | /* Define WORD_MACHINE if addresses and such have | ||
| 38 | * to be corrected before they can be used as byte counts. */ | ||
| 39 | |||
| 40 | #define WORD_MACHINE | ||
| 41 | |||
| 42 | /* Now define a symbol for the cpu type, if your compiler | ||
| 43 | does not define it automatically: | ||
| 44 | Ones defined so far include vax, m68000, ns16000, pyramid, | ||
| 45 | orion, tahoe, APOLLO and many others */ | ||
| 46 | |||
| 47 | /* Use type int rather than a union, to represent Lisp_Object */ | ||
| 48 | /* This is desirable for most machines. */ | ||
| 49 | |||
| 50 | #define NO_UNION_TYPE | ||
| 51 | |||
| 52 | /* Define EXPLICIT_SIGN_EXTEND if XINT must explicitly sign-extend | ||
| 53 | the 24-bit bit field into an int. In other words, if bit fields | ||
| 54 | are always unsigned. | ||
| 55 | |||
| 56 | If you use NO_UNION_TYPE, this flag does not matter. */ | ||
| 57 | |||
| 58 | #define EXPLICIT_SIGN_EXTEND | ||
| 59 | |||
| 60 | /* Data type of load average, as read out of kmem. */ | ||
| 61 | |||
| 62 | #define LOAD_AVE_TYPE long | ||
| 63 | |||
| 64 | /* Convert that into an integer that is 100 for a load average of 1.0 */ | ||
| 65 | |||
| 66 | #define LOAD_AVE_CVT(x) (int) (((double) (x)) * 100.0 / FSCALE) | ||
| 67 | |||
| 68 | /* Define CANNOT_DUMP on machines where unexec does not work. | ||
| 69 | Then the function dump-emacs will not be defined | ||
| 70 | and temacs will do (load "loadup") automatically unless told otherwise. */ | ||
| 71 | |||
| 72 | /* | ||
| 73 | #define CANNOT_DUMP 1 | ||
| 74 | #define CANNOT_UNEXEC 1 | ||
| 75 | */ | ||
| 76 | |||
| 77 | /* Start and end of text and data. */ | ||
| 78 | #define DATA_END get_data_end () | ||
| 79 | #define DATA_START get_data_start () | ||
| 80 | |||
| 81 | /* Define VIRT_ADDR_VARIES if the virtual addresses of | ||
| 82 | pure and impure space as loaded can vary, and even their | ||
| 83 | relative order cannot be relied on. | ||
| 84 | |||
| 85 | Otherwise Emacs assumes that text space precedes data space, | ||
| 86 | numerically. */ | ||
| 87 | |||
| 88 | /* Text does precede data space, but this is never a safe assumption. */ | ||
| 89 | #define VIRT_ADDR_VARIES | ||
| 90 | |||
| 91 | /* For alloca. */ | ||
| 92 | #include <malloc.h> | ||
| 93 | |||
| 94 | /* Define NO_REMAP if memory segmentation makes it not work well | ||
| 95 | to change the boundary between the text section and data section | ||
| 96 | when Emacs is dumped. If you define this, the preloaded Lisp | ||
| 97 | code will not be sharable; but that's better than failing completely. */ | ||
| 98 | |||
| 99 | /* #define NO_REMAP */ | ||
| 100 | |||
| 101 | /* Some really obscure 4.2-based systems (like Sequent DYNIX) | ||
| 102 | * do not support asynchronous I/O (using SIGIO) on sockets, | ||
| 103 | * even though it works fine on tty's. If you have one of | ||
| 104 | * these systems, define the following, and then use it in | ||
| 105 | * config.h (or elsewhere) to decide when (not) to use SIGIO. | ||
| 106 | * | ||
| 107 | * You'd think this would go in an operating-system description file, | ||
| 108 | * but since it only occurs on some, but not all, BSD systems, the | ||
| 109 | * reasonable place to select for it is in the machine description | ||
| 110 | * file. | ||
| 111 | */ | ||
| 112 | |||
| 113 | /* #define NO_SOCK_SIGIO */ | ||
| 114 | |||
| 115 | /* After adding support for a new system, modify the large case | ||
| 116 | statement in the `configure' script to recognize reasonable | ||
| 117 | configuration names, and add a description of the system to | ||
| 118 | `etc/MACHINES'. | ||
| 119 | |||
| 120 | If you've just fixed a problem in an existing configuration file, | ||
| 121 | you should also check `etc/MACHINES' to make sure its descriptions | ||
| 122 | of known problems in that configuration should be updated. */ | ||
| 123 | |||
| 124 | /* arch-tag: ed6dc0c1-5c01-49df-befd-c25dfadfb8cf | ||
| 125 | (do not change this comment) */ | ||
diff --git a/src/macfns.c b/src/macfns.c index 708fe576f17..0f40127637a 100644 --- a/src/macfns.c +++ b/src/macfns.c | |||
| @@ -2830,8 +2830,6 @@ This function is an internal primitive--use `make-frame' instead. */) | |||
| 2830 | if (CONSP (XCAR (tem)) && !NILP (XCAR (XCAR (tem)))) | 2830 | if (CONSP (XCAR (tem)) && !NILP (XCAR (XCAR (tem)))) |
| 2831 | f->param_alist = Fcons (XCAR (tem), f->param_alist); | 2831 | f->param_alist = Fcons (XCAR (tem), f->param_alist); |
| 2832 | 2832 | ||
| 2833 | store_frame_param (f, Qwindow_system, Qmac); | ||
| 2834 | |||
| 2835 | UNGCPRO; | 2833 | UNGCPRO; |
| 2836 | 2834 | ||
| 2837 | /* Make sure windows on this frame appear in calls to next-window | 2835 | /* Make sure windows on this frame appear in calls to next-window |
diff --git a/src/macterm.c b/src/macterm.c index 3c01a6618a2..7f837d2a20d 100644 --- a/src/macterm.c +++ b/src/macterm.c | |||
| @@ -12842,6 +12842,26 @@ mac_create_terminal (struct mac_display_info *dpyinfo) | |||
| 12842 | 12842 | ||
| 12843 | #endif | 12843 | #endif |
| 12844 | 12844 | ||
| 12845 | /* FIXME: This keyboard setup is 100% untested, just copied from | ||
| 12846 | w32_create_terminal in order to set window-system now that it's | ||
| 12847 | a keyboard object. */ | ||
| 12848 | #ifdef MULTI_KBOARD | ||
| 12849 | /* We don't yet support separate terminals on Mac, so don't try to share | ||
| 12850 | keyboards between virtual terminals that are on the same physical | ||
| 12851 | terminal like X does. */ | ||
| 12852 | terminal->kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); | ||
| 12853 | init_kboard (terminal->kboard); | ||
| 12854 | terminal->kboard->Vwindow_system = intern ("mac"); | ||
| 12855 | terminal->kboard->next_kboard = all_kboards; | ||
| 12856 | all_kboards = terminal->kboard; | ||
| 12857 | /* Don't let the initial kboard remain current longer than necessary. | ||
| 12858 | That would cause problems if a file loaded on startup tries to | ||
| 12859 | prompt in the mini-buffer. */ | ||
| 12860 | if (current_kboard == initial_kboard) | ||
| 12861 | current_kboard = terminal->kboard; | ||
| 12862 | terminal->kboard->reference_count++; | ||
| 12863 | #endif | ||
| 12864 | |||
| 12845 | return terminal; | 12865 | return terminal; |
| 12846 | } | 12866 | } |
| 12847 | 12867 | ||
diff --git a/src/macterm.h b/src/macterm.h index f319adeb659..9fbbbc5a2f5 100644 --- a/src/macterm.h +++ b/src/macterm.h | |||
| @@ -680,8 +680,6 @@ extern void x_clear_frame_selections P_ ((struct frame *)); | |||
| 680 | 680 | ||
| 681 | /* Defined in macfns.c */ | 681 | /* Defined in macfns.c */ |
| 682 | 682 | ||
| 683 | extern int have_menus_p P_ ((void)); | ||
| 684 | |||
| 685 | extern void x_real_positions P_ ((struct frame *, int *, int *)); | 683 | extern void x_real_positions P_ ((struct frame *, int *, int *)); |
| 686 | extern void x_set_menu_bar_lines P_ ((struct frame *, Lisp_Object, Lisp_Object)); | 684 | extern void x_set_menu_bar_lines P_ ((struct frame *, Lisp_Object, Lisp_Object)); |
| 687 | extern int x_pixel_width P_ ((struct frame *)); | 685 | extern int x_pixel_width P_ ((struct frame *)); |
diff --git a/src/minibuf.c b/src/minibuf.c index 340f6dae319..812956a13ca 100644 --- a/src/minibuf.c +++ b/src/minibuf.c | |||
| @@ -257,9 +257,13 @@ string_to_object (val, defalt) | |||
| 257 | 257 | ||
| 258 | GCPRO2 (val, defalt); | 258 | GCPRO2 (val, defalt); |
| 259 | 259 | ||
| 260 | if (STRINGP (val) && SCHARS (val) == 0 | 260 | if (STRINGP (val) && SCHARS (val) == 0) |
| 261 | && STRINGP (defalt)) | 261 | { |
| 262 | val = defalt; | 262 | if (STRINGP (defalt)) |
| 263 | val = defalt; | ||
| 264 | else if (CONSP (defalt) && STRINGP (XCAR (defalt))) | ||
| 265 | val = XCAR (defalt); | ||
| 266 | } | ||
| 263 | 267 | ||
| 264 | expr_and_pos = Fread_from_string (val, Qnil, Qnil); | 268 | expr_and_pos = Fread_from_string (val, Qnil, Qnil); |
| 265 | pos = XINT (Fcdr (expr_and_pos)); | 269 | pos = XINT (Fcdr (expr_and_pos)); |
| @@ -337,7 +341,7 @@ read_minibuf_noninteractive (map, initial, prompt, backup_n, expflag, | |||
| 337 | 341 | ||
| 338 | /* If Lisp form desired instead of string, parse it. */ | 342 | /* If Lisp form desired instead of string, parse it. */ |
| 339 | if (expflag) | 343 | if (expflag) |
| 340 | val = string_to_object (val, defalt); | 344 | val = string_to_object (val, CONSP (defalt) ? XCAR (defalt) : defalt); |
| 341 | 345 | ||
| 342 | return val; | 346 | return val; |
| 343 | } | 347 | } |
| @@ -785,6 +789,8 @@ read_minibuf (map, initial, prompt, backup_n, expflag, | |||
| 785 | histstring = val; | 789 | histstring = val; |
| 786 | else if (STRINGP (defalt)) | 790 | else if (STRINGP (defalt)) |
| 787 | histstring = defalt; | 791 | histstring = defalt; |
| 792 | else if (CONSP (defalt) && STRINGP (XCAR (defalt))) | ||
| 793 | histstring = XCAR (defalt); | ||
| 788 | else | 794 | else |
| 789 | histstring = Qnil; | 795 | histstring = Qnil; |
| 790 | 796 | ||
| @@ -1052,8 +1058,8 @@ DEFUN ("read-minibuffer", Fread_minibuffer, Sread_minibuffer, 1, 2, 0, | |||
| 1052 | doc: /* Return a Lisp object read using the minibuffer, unevaluated. | 1058 | doc: /* Return a Lisp object read using the minibuffer, unevaluated. |
| 1053 | Prompt with PROMPT. If non-nil, optional second arg INITIAL-CONTENTS | 1059 | Prompt with PROMPT. If non-nil, optional second arg INITIAL-CONTENTS |
| 1054 | is a string to insert in the minibuffer before reading. | 1060 | is a string to insert in the minibuffer before reading. |
| 1055 | \(INITIAL-CONTENTS can also be a cons of a string and an integer. Such | 1061 | \(INITIAL-CONTENTS can also be a cons of a string and an integer. |
| 1056 | arguments are used as in `read-from-minibuffer'.) */) | 1062 | Such arguments are used as in `read-from-minibuffer'.) */) |
| 1057 | (prompt, initial_contents) | 1063 | (prompt, initial_contents) |
| 1058 | Lisp_Object prompt, initial_contents; | 1064 | Lisp_Object prompt, initial_contents; |
| 1059 | { | 1065 | { |
| @@ -1067,8 +1073,8 @@ DEFUN ("eval-minibuffer", Feval_minibuffer, Seval_minibuffer, 1, 2, 0, | |||
| 1067 | doc: /* Return value of Lisp expression read using the minibuffer. | 1073 | doc: /* Return value of Lisp expression read using the minibuffer. |
| 1068 | Prompt with PROMPT. If non-nil, optional second arg INITIAL-CONTENTS | 1074 | Prompt with PROMPT. If non-nil, optional second arg INITIAL-CONTENTS |
| 1069 | is a string to insert in the minibuffer before reading. | 1075 | is a string to insert in the minibuffer before reading. |
| 1070 | \(INITIAL-CONTENTS can also be a cons of a string and an integer. Such | 1076 | \(INITIAL-CONTENTS can also be a cons of a string and an integer. |
| 1071 | arguments are used as in `read-from-minibuffer'.) */) | 1077 | Such arguments are used as in `read-from-minibuffer'.) */) |
| 1072 | (prompt, initial_contents) | 1078 | (prompt, initial_contents) |
| 1073 | Lisp_Object prompt, initial_contents; | 1079 | Lisp_Object prompt, initial_contents; |
| 1074 | { | 1080 | { |
| @@ -1102,7 +1108,7 @@ Fifth arg INHERIT-INPUT-METHOD, if non-nil, means the minibuffer inherits | |||
| 1102 | Qnil, history, default_value, | 1108 | Qnil, history, default_value, |
| 1103 | inherit_input_method); | 1109 | inherit_input_method); |
| 1104 | if (STRINGP (val) && SCHARS (val) == 0 && ! NILP (default_value)) | 1110 | if (STRINGP (val) && SCHARS (val) == 0 && ! NILP (default_value)) |
| 1105 | val = default_value; | 1111 | val = CONSP (default_value) ? XCAR (default_value) : default_value; |
| 1106 | return val; | 1112 | return val; |
| 1107 | } | 1113 | } |
| 1108 | 1114 | ||
| @@ -1225,7 +1231,7 @@ The argument PROMPT should be a string ending with a colon and a space. */) | |||
| 1225 | 1231 | ||
| 1226 | args[0] = build_string ("%s (default %s): "); | 1232 | args[0] = build_string ("%s (default %s): "); |
| 1227 | args[1] = prompt; | 1233 | args[1] = prompt; |
| 1228 | args[2] = def; | 1234 | args[2] = CONSP (def) ? XCAR (def) : def; |
| 1229 | prompt = Fformat (3, args); | 1235 | prompt = Fformat (3, args); |
| 1230 | } | 1236 | } |
| 1231 | 1237 | ||
| @@ -1835,7 +1841,7 @@ Completion ignores case if the ambient value of | |||
| 1835 | !NILP (inherit_input_method)); | 1841 | !NILP (inherit_input_method)); |
| 1836 | 1842 | ||
| 1837 | if (STRINGP (val) && SCHARS (val) == 0 && ! NILP (def)) | 1843 | if (STRINGP (val) && SCHARS (val) == 0 && ! NILP (def)) |
| 1838 | val = def; | 1844 | val = CONSP (def) ? XCAR (def) : def; |
| 1839 | 1845 | ||
| 1840 | RETURN_UNGCPRO (unbind_to (count, val)); | 1846 | RETURN_UNGCPRO (unbind_to (count, val)); |
| 1841 | } | 1847 | } |
diff --git a/src/msdos.h b/src/msdos.h index c45a5853a6c..a9379efb75d 100644 --- a/src/msdos.h +++ b/src/msdos.h | |||
| @@ -115,7 +115,6 @@ struct window; | |||
| 115 | 115 | ||
| 116 | /* Defined in xfns.c; emulated on msdos.c */ | 116 | /* Defined in xfns.c; emulated on msdos.c */ |
| 117 | 117 | ||
| 118 | extern int have_menus_p P_ ((void)); | ||
| 119 | extern void x_set_menu_bar_lines P_ ((struct frame *, Lisp_Object, Lisp_Object)); | 118 | extern void x_set_menu_bar_lines P_ ((struct frame *, Lisp_Object, Lisp_Object)); |
| 120 | extern int x_pixel_width P_ ((struct frame *)); | 119 | extern int x_pixel_width P_ ((struct frame *)); |
| 121 | extern int x_pixel_height P_ ((struct frame *)); | 120 | extern int x_pixel_height P_ ((struct frame *)); |
diff --git a/src/print.c b/src/print.c index c23e020eb8d..c6304bbd24e 100644 --- a/src/print.c +++ b/src/print.c | |||
| @@ -675,21 +675,30 @@ DEFUN ("with-output-to-temp-buffer", | |||
| 675 | Fwith_output_to_temp_buffer, Swith_output_to_temp_buffer, | 675 | Fwith_output_to_temp_buffer, Swith_output_to_temp_buffer, |
| 676 | 1, UNEVALLED, 0, | 676 | 1, UNEVALLED, 0, |
| 677 | doc: /* Bind `standard-output' to buffer BUFNAME, eval BODY, then show that buffer. | 677 | doc: /* Bind `standard-output' to buffer BUFNAME, eval BODY, then show that buffer. |
| 678 | The buffer is cleared out initially, and marked as unmodified when done. | 678 | |
| 679 | All output done by BODY is inserted in that buffer by default. | 679 | This construct makes buffer BUFNAME empty before running BODY. |
| 680 | The buffer is displayed in another window, but not selected. | 680 | It does not make the buffer current for BODY. |
| 681 | The value of the last form in BODY is returned. | 681 | Instead it binds `standard-output' to that buffer, so that output |
| 682 | If BODY does not finish normally, the buffer BUFNAME is not displayed. | 682 | generated with `prin1' and similar functions in BODY goes into |
| 683 | 683 | the buffer. | |
| 684 | The hook `temp-buffer-setup-hook' is run before BODY, | 684 | |
| 685 | with the buffer BUFNAME temporarily current. | 685 | At the end of BODY, this marks buffer BUFNAME unmodifed and displays |
| 686 | The hook `temp-buffer-show-hook' is run after the buffer is displayed, | 686 | it in a window, but does not select it. The normal way to do this is |
| 687 | with the buffer temporarily current, and the window that was used | 687 | by calling `display-buffer', then running `temp-buffer-show-hook'. |
| 688 | to display it temporarily selected. | 688 | However, if `temp-buffer-show-function' is non-nil, it calls that |
| 689 | 689 | function instead (and does not run `temp-buffer-show-hook'). The | |
| 690 | If variable `temp-buffer-show-function' is non-nil, call it at the end | 690 | function gets one argument, the buffer to display. |
| 691 | to get the buffer displayed instead of just displaying the non-selected | 691 | |
| 692 | buffer and calling the hook. It gets one argument, the buffer to display. | 692 | The return value of `with-output-to-temp-buffer' is the value of the |
| 693 | last form in BODY. If BODY does not finish normally, the buffer | ||
| 694 | BUFNAME is not displayed. | ||
| 695 | |||
| 696 | This runs the hook `temp-buffer-setup-hook' before BODY, | ||
| 697 | with the buffer BUFNAME temporarily current. It runs the hook | ||
| 698 | `temp-buffer-show-hook' after displaying buffer BUFNAME, with that | ||
| 699 | buffer temporarily current, and the window that was used to display it | ||
| 700 | temporarily selected. But it doesn't run `temp-buffer-show-hook' | ||
| 701 | if it uses `temp-buffer-show-function'. | ||
| 693 | 702 | ||
| 694 | usage: (with-output-to-temp-buffer BUFNAME BODY...) */) | 703 | usage: (with-output-to-temp-buffer BUFNAME BODY...) */) |
| 695 | (args) | 704 | (args) |
diff --git a/src/process.c b/src/process.c index fb10bf2cc8b..d80d7db2554 100644 --- a/src/process.c +++ b/src/process.c | |||
| @@ -2682,6 +2682,7 @@ OPTION is not a supported option, return nil instead; otherwise return t. */) | |||
| 2682 | 2682 | ||
| 2683 | /* A version of request_sigio suitable for a record_unwind_protect. */ | 2683 | /* A version of request_sigio suitable for a record_unwind_protect. */ |
| 2684 | 2684 | ||
| 2685 | #ifdef __ultrix__ | ||
| 2685 | static Lisp_Object | 2686 | static Lisp_Object |
| 2686 | unwind_request_sigio (dummy) | 2687 | unwind_request_sigio (dummy) |
| 2687 | Lisp_Object dummy; | 2688 | Lisp_Object dummy; |
| @@ -2690,6 +2691,7 @@ unwind_request_sigio (dummy) | |||
| 2690 | request_sigio (); | 2691 | request_sigio (); |
| 2691 | return Qnil; | 2692 | return Qnil; |
| 2692 | } | 2693 | } |
| 2694 | #endif | ||
| 2693 | 2695 | ||
| 2694 | /* Create a network stream/datagram client/server process. Treated | 2696 | /* Create a network stream/datagram client/server process. Treated |
| 2695 | exactly like a normal process when reading and writing. Primary | 2697 | exactly like a normal process when reading and writing. Primary |
diff --git a/src/s/ms-w32.h b/src/s/ms-w32.h index 5a297a4ee80..56a09f9b315 100644 --- a/src/s/ms-w32.h +++ b/src/s/ms-w32.h | |||
| @@ -241,6 +241,7 @@ Boston, MA 02110-1301, USA. */ | |||
| 241 | #undef HAVE_TERMIOS_H | 241 | #undef HAVE_TERMIOS_H |
| 242 | #define HAVE_LIMITS_H 1 | 242 | #define HAVE_LIMITS_H 1 |
| 243 | #define HAVE_STRING_H 1 | 243 | #define HAVE_STRING_H 1 |
| 244 | #define HAVE_STDLIB_H 1 | ||
| 244 | #define HAVE_PWD_H 1 | 245 | #define HAVE_PWD_H 1 |
| 245 | #define STDC_HEADERS 1 | 246 | #define STDC_HEADERS 1 |
| 246 | #define TIME_WITH_SYS_TIME 1 | 247 | #define TIME_WITH_SYS_TIME 1 |
| @@ -401,10 +402,6 @@ typedef int pid_t; | |||
| 401 | #define utime _utime | 402 | #define utime _utime |
| 402 | #endif | 403 | #endif |
| 403 | 404 | ||
| 404 | #ifdef HAVE_NTGUI | ||
| 405 | #define abort w32_abort | ||
| 406 | #endif | ||
| 407 | |||
| 408 | /* this is hacky, but is necessary to avoid warnings about macro | 405 | /* this is hacky, but is necessary to avoid warnings about macro |
| 409 | redefinitions using the SDK compilers */ | 406 | redefinitions using the SDK compilers */ |
| 410 | #ifndef __STDC__ | 407 | #ifndef __STDC__ |
diff --git a/src/term.c b/src/term.c index fca99bc6c75..bb7c139eafd 100644 --- a/src/term.c +++ b/src/term.c | |||
| @@ -3599,6 +3599,7 @@ to do `unset TERMCAP' (C-shell: `unsetenv TERMCAP') as well.", | |||
| 3599 | #ifdef MULTI_KBOARD | 3599 | #ifdef MULTI_KBOARD |
| 3600 | terminal->kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); | 3600 | terminal->kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); |
| 3601 | init_kboard (terminal->kboard); | 3601 | init_kboard (terminal->kboard); |
| 3602 | terminal->kboard->Vwindow_system = Qnil; | ||
| 3602 | terminal->kboard->next_kboard = all_kboards; | 3603 | terminal->kboard->next_kboard = all_kboards; |
| 3603 | all_kboards = terminal->kboard; | 3604 | all_kboards = terminal->kboard; |
| 3604 | terminal->kboard->reference_count++; | 3605 | terminal->kboard->reference_count++; |
| @@ -914,7 +914,6 @@ w32_get_resource (key, lpdwtype) | |||
| 914 | LPBYTE lpvalue; | 914 | LPBYTE lpvalue; |
| 915 | HKEY hrootkey = NULL; | 915 | HKEY hrootkey = NULL; |
| 916 | DWORD cbData; | 916 | DWORD cbData; |
| 917 | BOOL ok = FALSE; | ||
| 918 | 917 | ||
| 919 | /* Check both the current user and the local machine to see if | 918 | /* Check both the current user and the local machine to see if |
| 920 | we have any resources. */ | 919 | we have any resources. */ |
| @@ -1149,6 +1148,7 @@ init_environment (char ** argv) | |||
| 1149 | /* Also ignore empty environment variables. */ | 1148 | /* Also ignore empty environment variables. */ |
| 1150 | || *lpval == 0) | 1149 | || *lpval == 0) |
| 1151 | { | 1150 | { |
| 1151 | if (lpval) xfree (lpval); | ||
| 1152 | lpval = env_vars[i].def_value; | 1152 | lpval = env_vars[i].def_value; |
| 1153 | dwType = REG_EXPAND_SZ; | 1153 | dwType = REG_EXPAND_SZ; |
| 1154 | dont_free = 1; | 1154 | dont_free = 1; |
diff --git a/src/w32fns.c b/src/w32fns.c index de5b6db3d77..288b1f96665 100644 --- a/src/w32fns.c +++ b/src/w32fns.c | |||
| @@ -27,6 +27,7 @@ Boston, MA 02110-1301, USA. */ | |||
| 27 | #include <stdio.h> | 27 | #include <stdio.h> |
| 28 | #include <limits.h> | 28 | #include <limits.h> |
| 29 | #include <errno.h> | 29 | #include <errno.h> |
| 30 | #include <math.h> | ||
| 30 | 31 | ||
| 31 | #include "lisp.h" | 32 | #include "lisp.h" |
| 32 | #include "w32term.h" | 33 | #include "w32term.h" |
| @@ -4510,8 +4511,6 @@ This function is an internal primitive--use `make-frame' instead. */) | |||
| 4510 | if (CONSP (XCAR (tem)) && !NILP (XCAR (XCAR (tem)))) | 4511 | if (CONSP (XCAR (tem)) && !NILP (XCAR (XCAR (tem)))) |
| 4511 | f->param_alist = Fcons (XCAR (tem), f->param_alist); | 4512 | f->param_alist = Fcons (XCAR (tem), f->param_alist); |
| 4512 | 4513 | ||
| 4513 | store_frame_param (f, Qwindow_system, Qw32); | ||
| 4514 | |||
| 4515 | UNGCPRO; | 4514 | UNGCPRO; |
| 4516 | 4515 | ||
| 4517 | /* Make sure windows on this frame appear in calls to next-window | 4516 | /* Make sure windows on this frame appear in calls to next-window |
| @@ -7578,8 +7577,6 @@ x_create_tip_frame (dpyinfo, parms, text) | |||
| 7578 | Qnil)); | 7577 | Qnil)); |
| 7579 | } | 7578 | } |
| 7580 | 7579 | ||
| 7581 | Fmodify_frame_parameters (frame, Fcons (Fcons (Qwindow_system, Qw32), Qnil)); | ||
| 7582 | |||
| 7583 | f->no_split = 1; | 7580 | f->no_split = 1; |
| 7584 | 7581 | ||
| 7585 | UNGCPRO; | 7582 | UNGCPRO; |
| @@ -9211,8 +9208,6 @@ void globals_of_w32fns () | |||
| 9211 | 9208 | ||
| 9212 | #undef abort | 9209 | #undef abort |
| 9213 | 9210 | ||
| 9214 | void w32_abort (void) NO_RETURN; | ||
| 9215 | |||
| 9216 | void | 9211 | void |
| 9217 | w32_abort() | 9212 | w32_abort() |
| 9218 | { | 9213 | { |
diff --git a/src/w32term.c b/src/w32term.c index f174d25720a..aae84473532 100644 --- a/src/w32term.c +++ b/src/w32term.c | |||
| @@ -6874,6 +6874,7 @@ w32_create_terminal (struct w32_display_info *dpyinfo) | |||
| 6874 | terminal like X does. */ | 6874 | terminal like X does. */ |
| 6875 | terminal->kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); | 6875 | terminal->kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); |
| 6876 | init_kboard (terminal->kboard); | 6876 | init_kboard (terminal->kboard); |
| 6877 | terminal->kboard->Vwindow_system = intern ("w32"); | ||
| 6877 | terminal->kboard->next_kboard = all_kboards; | 6878 | terminal->kboard->next_kboard = all_kboards; |
| 6878 | all_kboards = terminal->kboard; | 6879 | all_kboards = terminal->kboard; |
| 6879 | /* Don't let the initial kboard remain current longer than necessary. | 6880 | /* Don't let the initial kboard remain current longer than necessary. |
diff --git a/src/window.c b/src/window.c index 766c291820f..a377ff76718 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -2690,9 +2690,8 @@ window_fixed_size_p (w, width_p, check_siblings_p) | |||
| 2690 | } | 2690 | } |
| 2691 | 2691 | ||
| 2692 | /* Return the minimum size for leaf window W. WIDTH_P non-zero means | 2692 | /* Return the minimum size for leaf window W. WIDTH_P non-zero means |
| 2693 | take into account fringes and the scrollbar of W. WIDTH_P zero | 2693 | take into account fringes and the scrollbar of W. WIDTH_P zero means |
| 2694 | means take into account mode-line and header-line of W. Return 1 | 2694 | take into account mode-line of W. Return 1 for the minibuffer. */ |
| 2695 | for the minibuffer. */ | ||
| 2696 | 2695 | ||
| 2697 | static int | 2696 | static int |
| 2698 | window_min_size_2 (w, width_p) | 2697 | window_min_size_2 (w, width_p) |
| @@ -2711,8 +2710,11 @@ window_min_size_2 (w, width_p) | |||
| 2711 | else | 2710 | else |
| 2712 | size = max (window_min_height, | 2711 | size = max (window_min_height, |
| 2713 | (MIN_SAFE_WINDOW_HEIGHT | 2712 | (MIN_SAFE_WINDOW_HEIGHT |
| 2714 | + (WINDOW_WANTS_MODELINE_P (w) ? 1 : 0) | 2713 | /* Don't count the header-line here. It would break |
| 2715 | + (WINDOW_WANTS_HEADER_LINE_P (w) ? 1 : 0 ))); | 2714 | splitting a window with a header-line when the new |
| 2715 | window shall have a height of two (calculator does | ||
| 2716 | that). */ | ||
| 2717 | + (WINDOW_WANTS_MODELINE_P (w) ? 1 : 0))); | ||
| 2716 | 2718 | ||
| 2717 | return size; | 2719 | return size; |
| 2718 | } | 2720 | } |
diff --git a/src/xfns.c b/src/xfns.c index fce3316b235..b176b3ffda5 100644 --- a/src/xfns.c +++ b/src/xfns.c | |||
| @@ -3679,8 +3679,6 @@ else | |||
| 3679 | if (CONSP (XCAR (tem)) && !NILP (XCAR (XCAR (tem)))) | 3679 | if (CONSP (XCAR (tem)) && !NILP (XCAR (XCAR (tem)))) |
| 3680 | f->param_alist = Fcons (XCAR (tem), f->param_alist); | 3680 | f->param_alist = Fcons (XCAR (tem), f->param_alist); |
| 3681 | 3681 | ||
| 3682 | store_frame_param (f, Qwindow_system, Qx); | ||
| 3683 | |||
| 3684 | UNGCPRO; | 3682 | UNGCPRO; |
| 3685 | 3683 | ||
| 3686 | /* Make sure windows on this frame appear in calls to next-window | 3684 | /* Make sure windows on this frame appear in calls to next-window |
| @@ -5212,8 +5210,6 @@ else | |||
| 5212 | Qnil)); | 5210 | Qnil)); |
| 5213 | } | 5211 | } |
| 5214 | 5212 | ||
| 5215 | Fmodify_frame_parameters (frame, Fcons (Fcons (Qwindow_system, Qx), Qnil)); | ||
| 5216 | |||
| 5217 | f->no_split = 1; | 5213 | f->no_split = 1; |
| 5218 | 5214 | ||
| 5219 | UNGCPRO; | 5215 | UNGCPRO; |
diff --git a/src/xterm.c b/src/xterm.c index 68670795fa3..9af6060d167 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -11242,6 +11242,7 @@ x_term_init (display_name, xrm_option, resource_name) | |||
| 11242 | { | 11242 | { |
| 11243 | terminal->kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); | 11243 | terminal->kboard = (KBOARD *) xmalloc (sizeof (KBOARD)); |
| 11244 | init_kboard (terminal->kboard); | 11244 | init_kboard (terminal->kboard); |
| 11245 | terminal->kboard->Vwindow_system = intern ("x"); | ||
| 11245 | if (!EQ (XSYMBOL (Qvendor_specific_keysyms)->function, Qunbound)) | 11246 | if (!EQ (XSYMBOL (Qvendor_specific_keysyms)->function, Qunbound)) |
| 11246 | { | 11247 | { |
| 11247 | char *vendor = ServerVendor (dpy); | 11248 | char *vendor = ServerVendor (dpy); |
diff --git a/src/xterm.h b/src/xterm.h index ad522c1dd75..ec583e39f4d 100644 --- a/src/xterm.h +++ b/src/xterm.h | |||
| @@ -1062,7 +1062,6 @@ extern Lisp_Object x_property_data_to_lisp P_ ((struct frame *, | |||
| 1062 | /* Defined in xfns.c */ | 1062 | /* Defined in xfns.c */ |
| 1063 | 1063 | ||
| 1064 | extern struct x_display_info * check_x_display_info P_ ((Lisp_Object frame)); | 1064 | extern struct x_display_info * check_x_display_info P_ ((Lisp_Object frame)); |
| 1065 | extern int have_menus_p P_ ((void)); | ||
| 1066 | 1065 | ||
| 1067 | #ifdef USE_GTK | 1066 | #ifdef USE_GTK |
| 1068 | extern int xg_set_icon P_ ((struct frame *, Lisp_Object)); | 1067 | extern int xg_set_icon P_ ((struct frame *, Lisp_Object)); |