diff options
| author | Chong Yidong | 2010-01-09 15:31:26 -0500 |
|---|---|---|
| committer | Chong Yidong | 2010-01-09 15:31:26 -0500 |
| commit | e5a29a107058c1778796cdb13adeb1e52457455b (patch) | |
| tree | 601dafd9d2dcde5d23a1a0ca589bfb51d132340e /src | |
| parent | 2f1c63846e4424829203007baf9a40f6e3e16e08 (diff) | |
| download | emacs-e5a29a107058c1778796cdb13adeb1e52457455b.tar.gz emacs-e5a29a107058c1778796cdb13adeb1e52457455b.zip | |
Fix for Bug#4113.
* nsterm.m (ns_set_default_prefs): Delete function.
(syms_of_nsterm): Initialize ns_command_modifier,
ns_control_modifier, ns_function_modifier, ns_antialias_text, and
ns_antialias_threshold here, not in ns_term_init (Bug#4113).
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/nsterm.m | 27 |
2 files changed, 14 insertions, 18 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index e0faafaf2ca..5b69f08c733 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,5 +1,10 @@ | |||
| 1 | 2010-01-09 Chong Yidong <cyd@stupidchicken.com> | 1 | 2010-01-09 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 2 | ||
| 3 | * nsterm.m (ns_set_default_prefs): Delete function. | ||
| 4 | (syms_of_nsterm): Initialize ns_command_modifier, | ||
| 5 | ns_control_modifier, ns_function_modifier, ns_antialias_text, and | ||
| 6 | ns_antialias_threshold here, not in ns_term_init (Bug#4113). | ||
| 7 | |||
| 3 | * xdisp.c (pos_visible_p): Check for invisible text at the correct | 8 | * xdisp.c (pos_visible_p): Check for invisible text at the correct |
| 4 | position (Bug#4040). | 9 | position (Bug#4040). |
| 5 | 10 | ||
diff --git a/src/nsterm.m b/src/nsterm.m index 2eebbf86643..18c51d00938 100644 --- a/src/nsterm.m +++ b/src/nsterm.m | |||
| @@ -3479,22 +3479,6 @@ static Lisp_Object ns_mod_to_lisp (int m) | |||
| 3479 | 3479 | ||
| 3480 | 3480 | ||
| 3481 | static void | 3481 | static void |
| 3482 | ns_set_default_prefs () | ||
| 3483 | /* -------------------------------------------------------------------------- | ||
| 3484 | Initialize preference variables to defaults | ||
| 3485 | -------------------------------------------------------------------------- */ | ||
| 3486 | { | ||
| 3487 | ns_alternate_modifier = Qmeta; | ||
| 3488 | ns_command_modifier = Qsuper; | ||
| 3489 | ns_control_modifier = Qcontrol; | ||
| 3490 | ns_function_modifier = Qnone; | ||
| 3491 | ns_antialias_text = Qt; | ||
| 3492 | ns_antialias_threshold = 10.0; /* not exposed to lisp side */ | ||
| 3493 | ns_confirm_quit = Qnil; | ||
| 3494 | } | ||
| 3495 | |||
| 3496 | |||
| 3497 | static void | ||
| 3498 | ns_default (const char *parameter, Lisp_Object *result, | 3482 | ns_default (const char *parameter, Lisp_Object *result, |
| 3499 | Lisp_Object yesval, Lisp_Object noval, | 3483 | Lisp_Object yesval, Lisp_Object noval, |
| 3500 | BOOL is_float, BOOL is_modstring) | 3484 | BOOL is_float, BOOL is_modstring) |
| @@ -3756,8 +3740,6 @@ ns_term_init (Lisp_Object display_name) | |||
| 3756 | 3740 | ||
| 3757 | UNBLOCK_INPUT; | 3741 | UNBLOCK_INPUT; |
| 3758 | 3742 | ||
| 3759 | /* Read various user defaults. */ | ||
| 3760 | ns_set_default_prefs (); | ||
| 3761 | if (!inhibit_x_resources) | 3743 | if (!inhibit_x_resources) |
| 3762 | { | 3744 | { |
| 3763 | ns_default ("GSFontAntiAlias", &ns_antialias_text, | 3745 | ns_default ("GSFontAntiAlias", &ns_antialias_text, |
| @@ -6159,6 +6141,9 @@ void | |||
| 6159 | syms_of_nsterm () | 6141 | syms_of_nsterm () |
| 6160 | { | 6142 | { |
| 6161 | NSTRACE (syms_of_nsterm); | 6143 | NSTRACE (syms_of_nsterm); |
| 6144 | |||
| 6145 | ns_antialias_threshold = 10.0; | ||
| 6146 | |||
| 6162 | DEFVAR_LISP ("ns-input-file", &ns_input_file, | 6147 | DEFVAR_LISP ("ns-input-file", &ns_input_file, |
| 6163 | "The file specified in the last NS event."); | 6148 | "The file specified in the last NS event."); |
| 6164 | ns_input_file =Qnil; | 6149 | ns_input_file =Qnil; |
| @@ -6200,26 +6185,32 @@ syms_of_nsterm () | |||
| 6200 | Set to control, meta, alt, super, or hyper means it is taken to be that key.\n\ | 6185 | Set to control, meta, alt, super, or hyper means it is taken to be that key.\n\ |
| 6201 | Set to none means that the alternate / option key is not interpreted by Emacs\n\ | 6186 | Set to none means that the alternate / option key is not interpreted by Emacs\n\ |
| 6202 | at all, allowing it to be used at a lower level for accented character entry."); | 6187 | at all, allowing it to be used at a lower level for accented character entry."); |
| 6188 | ns_alternate_modifier = Qmeta; | ||
| 6203 | 6189 | ||
| 6204 | DEFVAR_LISP ("ns-command-modifier", &ns_command_modifier, | 6190 | DEFVAR_LISP ("ns-command-modifier", &ns_command_modifier, |
| 6205 | "This variable describes the behavior of the command key.\n\ | 6191 | "This variable describes the behavior of the command key.\n\ |
| 6206 | Set to control, meta, alt, super, or hyper means it is taken to be that key."); | 6192 | Set to control, meta, alt, super, or hyper means it is taken to be that key."); |
| 6193 | ns_command_modifier = Qsuper; | ||
| 6207 | 6194 | ||
| 6208 | DEFVAR_LISP ("ns-control-modifier", &ns_control_modifier, | 6195 | DEFVAR_LISP ("ns-control-modifier", &ns_control_modifier, |
| 6209 | "This variable describes the behavior of the control key.\n\ | 6196 | "This variable describes the behavior of the control key.\n\ |
| 6210 | Set to control, meta, alt, super, or hyper means it is taken to be that key."); | 6197 | Set to control, meta, alt, super, or hyper means it is taken to be that key."); |
| 6198 | ns_control_modifier = Qcontrol; | ||
| 6211 | 6199 | ||
| 6212 | DEFVAR_LISP ("ns-function-modifier", &ns_function_modifier, | 6200 | DEFVAR_LISP ("ns-function-modifier", &ns_function_modifier, |
| 6213 | "This variable describes the behavior of the function key (on laptops).\n\ | 6201 | "This variable describes the behavior of the function key (on laptops).\n\ |
| 6214 | Set to control, meta, alt, super, or hyper means it is taken to be that key.\n\ | 6202 | Set to control, meta, alt, super, or hyper means it is taken to be that key.\n\ |
| 6215 | Set to none means that the function key is not interpreted by Emacs at all,\n\ | 6203 | Set to none means that the function key is not interpreted by Emacs at all,\n\ |
| 6216 | allowing it to be used at a lower level for accented character entry."); | 6204 | allowing it to be used at a lower level for accented character entry."); |
| 6205 | ns_function_modifier = Qnone; | ||
| 6217 | 6206 | ||
| 6218 | DEFVAR_LISP ("ns-antialias-text", &ns_antialias_text, | 6207 | DEFVAR_LISP ("ns-antialias-text", &ns_antialias_text, |
| 6219 | "Non-nil (the default) means to render text antialiased. Only has an effect on OS X Panther and above."); | 6208 | "Non-nil (the default) means to render text antialiased. Only has an effect on OS X Panther and above."); |
| 6209 | ns_antialias_text = Qt; | ||
| 6220 | 6210 | ||
| 6221 | DEFVAR_LISP ("ns-confirm-quit", &ns_confirm_quit, | 6211 | DEFVAR_LISP ("ns-confirm-quit", &ns_confirm_quit, |
| 6222 | "Whether to confirm application quit using dialog."); | 6212 | "Whether to confirm application quit using dialog."); |
| 6213 | ns_confirm_quit = Qnil; | ||
| 6223 | 6214 | ||
| 6224 | staticpro (&ns_display_name_list); | 6215 | staticpro (&ns_display_name_list); |
| 6225 | ns_display_name_list = Qnil; | 6216 | ns_display_name_list = Qnil; |