[vine-users:080966] Emacs でのフォント設定について

MURAKAMI Tomokazu tomone @ p-act.sakura.ne.jp
2011年 4月 18日 (月) 00:08:08 JST


村上 @PARALLEL ACT %TomOne です。

[VineLinux:0971] を参考に、

=========================================
(set-frame-font "Inconsolata 12")
(setq-default line-spacing 1);; 行間
(set-fontset-font (frame-parameter nil 'font)
 		  'japanese-jisx0208
  		  '("IPAGothic" . "unicode-bmp")
 		  nil 'append);; Monospace, IPAGothc, VL Gothic など
=========================================

として、欧文を Inconsolata、漢字を IPAGothic にしています。
しかし、この設定だと「×」が半角になり、

------------------------
     5/1 5/2 5/3 5/4 5/5
佐藤 ○ ○ ○ ○ ○
鈴木 ○ × ○ ○ ○
加藤 ○ ○ × ○ ○
村上 ○ ○ ○ △ ○
------------------------

といった表が崩れて見にくいです。

------------------------
     5/1 5/2 5/3 5/4 5/5
佐藤 ○ ○ ○ ○ ○
鈴木 ○ x ○ ○ ○
加藤 ○ ○ x ○ ○
村上 ○ ○ ○ △ ○
------------------------
この様になります。

そこで、こう追記して、
=========================================
(set-fontset-font nil
                  '#xd7 ; ×の符号
                  (font-spec :family "IPAGothic"))
=========================================
どうにか「×」だけは全角にしましたが、「÷」なんかは半角のままで、気持
ち悪いです。それに「×」が他の文字と別扱いなのが気になります。

さらに、
=========================================
(set-frame-font "Inconsolata 12")
=========================================
だけにして、C-u C-x = で文字情報を調べると、


---------------------------------------------
        character: 1 (49, #o61, #x31)
preferred charset: ascii (ASCII (ISO646 IRV))
       code point: 0x31
           syntax: w 	which means: word
         category: .:Base, a:ASCII, l:Latin, r:Roman
      buffer code: #x31
        file code: #x31 (encoded by coding system ctext-unix)
          display: by this font (glyph code)
    xft:-unknown-Inconsolata-normal-normal-normal-*-16-*-*-*-m-0-iso10646-1 (#x31)

Character code properties: customize what to show
  name: DIGIT ONE
  general-category: Nd (Number, Decimal Digit)
---------------------------------------------

---------------------------------------------
        character: 村 (26449, #o63521, #x6751)
preferred charset: japanese-jisx0208
		   (JISX0208.1983/1990 Japanese Kanji: ISO-IR-87)
       code point: 0x423C
           syntax: w 	which means: word
         category:
		   .:Base, C:2-byte han, c:Chinese, h:Korean, j:Japanese, |:line breakable
      buffer code: #xE6 #x9D #x91
        file code: ESC #x24 #x28 #x42 #x42 #x3C
		   (encoded by coding system ctext-unix)
          display: by this font (glyph code)
    xft:-unknown-IPA明朝-normal-normal-normal-*-16-*-*-*-d-0-iso10646-1 (#xA27)

Character code properties: customize what to show
  name: CJK IDEOGRAPH-6751
  general-category: Lo (Letter, Other)
---------------------------------------------

---------------------------------------------
        character: ○ (9675, #o22713, #x25cb)
preferred charset: japanese-jisx0208
		   (JISX0208.1983/1990 Japanese Kanji: ISO-IR-87)
       code point: 0x217B
           syntax: _ 	which means: symbol
         category: .:Base, c:Chinese, h:Korean, j:Japanese
      buffer code: #xE2 #x97 #x8B
        file code: ESC #x24 #x28 #x42 #x21 #x7B
		   (encoded by coding system ctext-unix)
          display: by this font (glyph code)
    xft:-unknown-みかちゃん_o-normal-normal-normal-*-16-*-*-*-d-0-iso10646-1 (#x

Character code properties: customize what to show
  name: WHITE CIRCLE
  general-category: So (Symbol, Other)
---------------------------------------------

---------------------------------------------
        character: × (215, #o327, #xd7)
preferred charset: japanese-jisx0208
		   (JISX0208.1983/1990 Japanese Kanji: ISO-IR-87)
       code point: 0x215F
           syntax: _ 	which means: symbol
         category: .:Base, c:Chinese, h:Korean, j:Japanese, l:Latin
      buffer code: #xC3 #x97
        file code: ESC #x24 #x28 #x42 #x21 #x5F
		   (encoded by coding system ctext-unix)
          display: by this font (glyph code)
    xft:-unknown-Inconsolata-normal-normal-normal-*-16-*-*-*-m-0-iso10646-1 (#xD7)

Character code properties: customize what to show
  name: MULTIPLICATION SIGN
  general-category: Sm (Symbol, Math)
---------------------------------------------

となり、

---------------------------------------------
       font		preferred charset
ASCII: Inconsolata	ascii
漢字:  IPA明朝		japanese-jisx0208
○:    みかちゃん	japanese-jisx0208
×:    Inconsolata	japanese-jisx0208
---------------------------------------------

と、preferred charset が同じなのにフォントがバラバラになり、どういう風
にカテゴライズされているのか、設定すべきなのかますます分からなくなりま
した。

「○」が一般記号で、「×」が数学記号だから別扱いなのだろうとは思います
が。


なにか仕組みを知る方法や解決方法はありますでしょうか?

-- 
┏━━━━━━━━━━━━━━━━━━━━━━━┓
┃  村上 智一   ( TomOne )     PARALLEL ACT     ┠┐
┃  URI:    http://p-act.sakura.ne.jp/          ┃│
┃  E-Mail: tomone(at)p-act.sakura.ne.jp (main) ┃│
┃  E-Mail: mrkmtmkz(at)kch.biglobe.ne.jp (sub) ┃│
┗┯━━━━━━━━━━━━━━━━━━━━━━┛│
  └───────────────────────┘


vine-users メーリングリストの案内