summaryrefslogtreecommitdiff
path: root/lisp/startup.el
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2015-07-01 22:24:51 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2015-07-01 22:25:39 -0700
commitbb35a21c0e8a4b82ac04fa26a53f6ca394afbb24 (patch)
treede504f5a40d27c0b6b5d5755129533400f9dd221 /lisp/startup.el
parent145f28f814cc1d75cbabd91496d7b49c73f67994 (diff)
downloademacs-bb35a21c0e8a4b82ac04fa26a53f6ca394afbb24.tar.gz
Don't display ‘’ as `' under X in en_GB
The curved quote setup code invokes (char-displayable-p ?‘), but this isn’t reliable until after the X frame replaces the terminal frame (Bug#20926). * lisp/international/mule-cmds.el (set-locale-environment): Move curved quote setup code from here ... * lisp/startup.el (command-line): ... to here, after creating the X frame.
Diffstat (limited to 'lisp/startup.el')
-rw-r--r--lisp/startup.el8
1 files changed, 8 insertions, 0 deletions
diff --git a/lisp/startup.el b/lisp/startup.el
index ab5a3a4bfa5..4f1e3150abc 100644
--- a/lisp/startup.el
+++ b/lisp/startup.el
@@ -1017,6 +1017,14 @@ please check its value")
'("no" "off" "false" "0")))))
(setq no-blinking-cursor t))
+ ;; If curved quotes don't work, display ASCII approximations.
+ (unless noninteractive
+ (dolist (char-repl '((?‘ . [?\`]) (?’ . [?\']) (?“ . [?\"]) (?” . [?\"])))
+ (when (not (char-displayable-p (car char-repl)))
+ (or standard-display-table
+ (setq standard-display-table (make-display-table)))
+ (aset standard-display-table (car char-repl) (cdr char-repl)))))
+
;; Re-evaluate predefined variables whose initial value depends on
;; the runtime context.
(mapc 'custom-reevaluate-setting