I want to tune the fonts used for cyrillic text. For that I had to redefine the font in a fontset. This seems possible only in CVS emacs 21.x cannot do it.
(set-fontset-font
;; current fontset:
(frame-parameter nil 'font)
;; the interval of cyrillic glyphs.... those covered by my pre-selected font:
`(,(decode-char 'ucs #x0400) . ,(decode-char 'ucs #x04ff))
;;"Cronyx-Helvetica-Bold-R-Normal-*-25-180-100-100-P-98-KOI8-R"
"*-*-medium-R-*-*-25-*-*-*-*-*-koi8-r"
)
;;; How to make bold? ;; I want to set a fixed font in a fontset. If i put "*" in the stroke field, out of "bold" and "medium" available fonts, "bold" is ;; picked. So I specify "medium", but the 'bold face does not use "bold". I guess I have to specify 'bold face w/ a different fontset, but then ;; 'default and 'bold faces might happen to be of different size. ;; todo: I'm not able to set the default X font to use for ascii chars! So I have to create a NEW fontset w/ the right setting! ;; Create suitable for `bold' face: (create-fontset-from-fontset-spec "-*-lucidatypewriter-bold-r-normal-*-20-*-*-*-*-*-fontset-3") ;; I should force emacs (C part) to take -Medium- rather than -Bold- version. and Bold for :bold faces! (set-fontset-font "fontset-3" `(,(decode-char 'ucs #x0400) . ,(decode-char 'ucs #x04ff)) ;;"Cronyx-Helvetica-Bold-R-Normal-*-25-180-100-100-P-98-KOI8-R" "*-*-bold-R-Normal-*-25-*-*-*-*-*-koi8-r")
For installation on Xorg I had to:
emerge font-cronyx-cyrillic xset +fp /usr/share/fonts/cyrillic xset fp rehash