all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Oleksandr Gavenko <gavenkoa@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Emacs do not show RU and IPA chars in monospaced font.
Date: Wed, 11 Jul 2012 00:00:42 +0300	[thread overview]
Message-ID: <87a9z7e3gl.fsf@desktop.home.int> (raw)
In-Reply-To: 87txxhq5ww.fsf@desktop.home.int

On 2012-07-09, Oleksandr Gavenko wrote:
> I try set:
>
>   (set-frame-font "-misc-fixed-medium-r-normal-*-13-*-*-*-*-*-iso10646-*")
>
> and for russian letter get (ugly bold large letters):
>
>   xft:-Misc-Fixed-normal-normal-normal-ja-13-*-*-*-c-120-iso10646-1 (#x1FC)
>
> [SKIP]
>
> Do I need prepare bug report?

I report bug:

  http://debbugs.gnu.org/cgi/bugreport.cgi?bug=11889

After a while I read:

  http://emacswiki.org/emacs/SetFonts
  http://www.emacswiki.org/emacs/FontSets
  http://www.emacswiki.org/emacs/DisplayingNonAsciiCharacters

and corresponding Emacs manuals.

That I leaned that I need some tools for viewing selected chars in selected
font.

For server-side fonts this can be done like:

  $ xfontsel -sampleUCS 'əθʃçʧ  θʒtð Hello Привет!'

For client-side font I found:

  $ gucharmap

After looking for several problematic chars I found that they are missing in
13 px size for my font or look wrongly.

After playing with configurations I found font that cover all needed my me
characters.

And learned how use fontsets, here my setup:

  (set-frame-font "-misc-fixed-medium-r-normal--14-*-*-*-c-*-iso10646-1")
  (set-fontset-font "fontset-default" 'latin
                    "-misc-fixed-medium-r-normal--14-*-*-*-c-*-iso10646-1")
  (set-fontset-font "fontset-default" 'phonetic
                    "-misc-fixed-medium-r-normal--14-*-*-*-c-*-iso10646-1")
  (set-fontset-font "fontset-default" 'cyrillic
                    "-misc-fixed-medium-r-normal--14-*-*-*-c-*-iso10646-1")
  (set-fontset-font "fontset-default" 'greek
                    "-misc-fixed-medium-r-normal--14-*-*-*-c-*-iso10646-1")

Another quiz for me was searching of script name symbols for
'set-fontset-font'. Jumping to .c source take 'char-script-table'.

After reading manual about built-in types I get this list:

  (pp (char-table-extra-slot char-script-table 0))
  latin phonetic greek coptic cyrillic armenian ...

Another useful thing that help me is:

  (describe-fontset "default-fontset")
  (describe-fontset "standard-fontset")
  (describe-fontset "startup-fontset")

So algorithm to fix font displaying simple:

 * Use Emacs >= 23.x for UTF support.
 * Find fonts that cover your chars (xfontsel & gucharmap).
 * Set fonts as say manual. I Emacs make wrong decision for selected chars,
   set font manually by 'set-fontset-font'. This func support individual char,
   char range and symbolic names (which I use in this post).

================================================================

Anyone can tell me test program for client-side fonts that display string that
I pass to it? gucharmap show only individual chars (opposed to xfontsel with
'-sampleUCS'). This is inconvenient, I like to pass this string to perform
on whole text:

  (defun my-print-range (start end)
    (let (i)
      (setq i start)
      (while (< i end)
        (ucs-insert i)
        (setq i (1+ i))
        )))

  ;; ASCII
  (my-print-range ?\u0020 ?\u0080)
  ;; !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~\x7f

  ;; Cyrillic
  (my-print-range ?\u0410 ?\u0460)
  ;; АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюяѐёђѓєѕіїјљњћќѝўџ

  ;; Greek
  (my-print-range ?\u0391 ?\u03ca)
  ;; ΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡ΢ΣΤΥΦΧΨΩΪΫάέήίΰαβγδεζηθικλμνξοπρςστυφχψω

  (my-print-range ?\u0250 ?\u02d1)
  ;; IPA
  ;; ɐɑɒɓɔɕɖɗɘəɚɛɜɝɞɟɠɡɢɣɤɥɦɧɨɩɪɫɬɭɮɯɰɱɲɳɴɵɶɷɸɹɺɻɼɽɾɿʀʁʂʃʄʅʆʇʈʉʊʋʌʍʎʏʐʑʒʓʔʕʖʗʘʙʚʛʜʝʞʟʠʡʢʣʤʥʦʧʨʩʪʫʬʭʮʯʰʱʲʳʴʵʶʷʸʹʺʻʼʽʾʿˀˁ˂˃˄˅ˆˇˈˉˊˋˌˍˎˏː

-- 
Best regards!




  reply	other threads:[~2012-07-10 21:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-08 21:50 Emacs do not show RU and IPA chars in monospaced font Oleksandr Gavenko
2012-07-10 21:00 ` Oleksandr Gavenko [this message]
2012-07-10 21:35   ` Drew Adams
2012-07-10 21:49   ` Peter Dyballa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a9z7e3gl.fsf@desktop.home.int \
    --to=gavenkoa@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.