>>>> "Aidan" == Aidan Kehoe
<kehoea(a)parhasard.net> writes:
Aidan> Ar an deichiú lá de mí na Samhain, scríobh Stephen J. Turnbull:
Aidan> The menu has never worked with XFT. X resources usually work, customize has
Aidan> never worked (Customize is *way* less important than the menu working), and
Aidan> the following Lisp code usually works (you can change Monospace-11.5 to
Aidan> whatever you’d like):
Aidan> (with-fboundp '(fc-name-unparse fc-font-match fc-name-parse)
Aidan> (set-specifier
Aidan> (face-font 'default)
Aidan> (cons '(x)
Aidan> (fc-name-unparse
Aidan> (fc-font-match (selected-device)
Aidan> (fc-name-parse
"Monospace-11.5:lang=en")))))
Aidan> (macrolet
Aidan> ((define-tags-and-set-faces (&rest tag-details)
Aidan> (cons
Aidan> 'progn
Aidan> (mapcan
Aidan> (function*
Aidan> (lambda ((tag-name regex size))
Aidan> `((define-specifier-tag ',tag-name nil
Aidan> #'(lambda (charset)
Aidan> (string-match ,regex
Aidan> (symbol-name (charset-name
charset)))))
Aidan> (set-face-font 'default
Aidan> (fc-name-unparse
Aidan> (fc-font-match
Aidan> (selected-device)
Aidan> (fc-name-parse ,(format "-%d:lang=%s" size
tag-name)))
Aidan> nil '(x ,tag-name) 'append)))))
Aidan> tag-details))))
Aidan> (define-tags-and-set-faces
Aidan> (zh-tw "^chinese-\\(big5\\|cns\\)" 18)
Aidan> (zh "^chinese-" 18)
Aidan> (ja "^\\(japanese\\|katakana\\)-" 18)
Aidan> (ko "^korean-" 18)
Aidan> (am "^ethiopic-" 18)
Aidan> (vi "^vietnamese-" 14)
Aidan> (el "^greek-" 12)
Aidan> (ru "^cyrillic-" 12)
Aidan> (hu "^latin-iso8859-2" 12)
Aidan> (ar "^arabic-" 16)
Aidan> (lo "^lao" 14)
Aidan> (he "^hebrew" 11.5)
Aidan> (th "^thai" 14))))
Aidan> If you don’t care about writing anything but English, or at a stretch
Aidan> something else Windows-1252-compatible, the #'set-specifier call should
be
Aidan> enough.
Aidan> (I believe Raymond uses the above code already!)
Yes, I use something very similar. It works pretty nicely. I did
have to add a few additions because I changed the default font and
size to something else, and that messed up the sizes of other faces
like font-lock, slime, git mode, etc.
Ray
_______________________________________________
XEmacs-Beta mailing list
XEmacs-Beta(a)xemacs.org
http://lists.xemacs.org/mailman/listinfo/xemacs-beta