From 3a06e7245703f58aaee5c50cfaa410458614efa0 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 5 May 2018 11:45:37 +0300 Subject: [PATCH] Fix encoding of characters when using GB18030 fonts * lisp/international/fontset.el (font-encoding-alist): Fix the GB18030 entry to encode characters correctly when passing them to the xfont back-end. (Bug#31315) See also http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00754.html. (cherry picked from commit bbe2cadc544e63e9378350621887f8fb9bbcc236) --- lisp/international/fontset.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lisp/international/fontset.el b/lisp/international/fontset.el index 6f912074517..5c0189b0155 100644 --- a/lisp/international/fontset.el +++ b/lisp/international/fontset.el @@ -53,7 +53,10 @@ ("ascii-0$" . ascii) ("gb2312.1980" . chinese-gb2312) ("gbk" . chinese-gbk) - ("gb18030" . (unicode . nil)) + ;; GB18030 needs the characters encoded by gb18030, but a + ;; gb18030 font doesn't necessarily support all of the GB18030 + ;; characters. + ("gb18030" . (gb18030 . unicode)) ("jisx0208.1978" . japanese-jisx0208-1978) ("jisx0208" . japanese-jisx0208) ("jisx0201" . jisx0201) -- 2.39.5