emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Incorrect display using Chinese-GBK language environment


From: Yu-ning Feng
Subject: Incorrect display using Chinese-GBK language environment
Date: Wed, 19 Mar 2008 16:53:15 +0800

description
--------
When .emacs was empty, started emacs
$emacs-23.0.60 -fn "DejaVu Sans Mono-12"

on the splash screen, there should have been 4 chinese characters at the right-most of the line where "Emacs Tutorial" was at.
Instead, 4 korean characters were displayed. (See *1.png)
Information of the first character was as below:

        character: 快 (24555, #o57753, #x5feb)
preferred charset: chinese-gbk (GBK Chinese simplified.)
       code point: 0xBFEC
           syntax: w     which means: word
         category: C:Chinese (Han) characters of 2-byte character sets
           c:Chinese h:Korean j:Japanese
           |:While filling, we can break a line at this character.
      buffer code: #xE5 #xBF #xAB
        file code: #xE5 #xBF #xAB (encoded by coding system utf-8-unix)
          display: by this font (glyph code)
     -wenquanyi-wenquanyi bitmap song-medium-r-normal--16-160-75-75-P-80-iso10646-1 (#xBFEC)

(That chinese character in describtion info was not displayed correctly either.)

Then .emacs was changed to:
(set-fontset-font "fontset-default" 'chinese-gb2312 '("wenquanyi bitmap song" . "iso10646"))
(set-language-environment 'Chinese-GB)

restart emacs by the same way. This time those characters displayed correctly. (See *2.png)

Then, once more, .emacs was changed to:
(set-fontset-font "fontset-default" 'chinese-gbk '("wenquanyi bitmap song" . "iso10646"))
(set-language-environment 'Chinese-GBK)

still restart emacs by the same way. Characters displayed incorrect.(See *3.png)

my conclusion
--------
Since the gbk was an extending encoding based on gb2312, and was backward compatible with the later one, I thought the gbk encoding system or the gbk language environment in emacs was not working as expected.


In GNU Emacs 23.0.60.1 (i686-pc-linux-gnu, GTK+ Version 2.8.20)
 of 2008-03-19 on ynfeng
Windowing system distributor `The X.Org Foundation', version 11.0.70101000
configured using `configure  '--prefix=/home/yuning/emacs-2008-3-18/' '--with-x-toolkit=gtk' '--with-xft' '--enable-font-backend' '--with-xpm=no' '--with-jpeg=no' '--with-gif=no' '--with-tiff=no''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: zh_CN.UTF-8
  value of $XMODIFIERS: @im=SCIM
  locale-coding-system: utf-8-unix
  default-enable-multibyte-characters: t

Attachment: Screenshot-emacs-23.0.60@ynfeng-1.png
Description: PNG image

Attachment: Screenshot-emacs-23.0.60@ynfeng-2.png
Description: PNG image

Attachment: Screenshot-emacs-23.0.60@ynfeng-3.png
Description: PNG image


reply via email to

[Prev in Thread] Current Thread [Next in Thread]