From: handa <handa@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 20984@debbugs.gnu.org, bruce.connor.am@gmail.com
Subject: bug#20984: 25.0.50; Combining accents don't display properly in certain fonts
Date: Sat, 11 Jul 2015 01:06:35 +0900 [thread overview]
Message-ID: <87h9pc575g.fsf@gnu.org> (raw)
In-Reply-To: <83oajkbkbo.fsf@gnu.org> (message from Eli Zaretskii on Fri, 10 Jul 2015 09:25:31 +0300)
[-- Attachment #1: Type: text/plain, Size: 1618 bytes --]
In article <83oajkbkbo.fsf@gnu.org>, Eli Zaretskii <eliz@gnu.org> writes:
> Btw, I wonder why xftfont and libotf don't do the same as Uniscribe,
> i.e. instruct Emacs to display the à character. This is what the
> composition data I see here says:
> [0 1 97 231 8 1 7 12 4 nil]
> This single vector tells Emacs to display one glyph, and 231 is its
> code in the font.
> It is strange that libotf doesn't take this shortcut, although I'm
> quite sure a glyph for à is available both in DejaVu Sans Mono and in
> Source Code Pro. But I don't know enough about libotf.
Sorry, I found that my build of emacs-24.5 was without m17n-flt (and
libotf). So, the combining was done by Emacs itself using the function
compose-gstring-for-graphic.
I've just rebuild emacs-24.5 with m17n-flt, and see the same problem as
the trunk, which means that the culprit may be in m17n-flt or libotf.
So, I checked m17n-flt and found that the rule for combining latin
characters has a bug when a font has such OTF features as subs, sups.
Please try the attached COMBINING.flt by these steps:
1. make the directory ~/.m17n.d
2. put COMBINING.flt under that directory.
3. run emacs
By the why, the reason of m17n-flt/libotf not taking the shortcut above
is that the Source Code Pro font doesn't have such a feature. I suspect
Uniscribe has a special code for using precomposed glyph without asking
a font about its features. So, perhaps, even with TTF font (i.e. a font
of no OTF features), Uniscribe can display a-grave sequence with the
precomposed glyph.
---
K. Handa
handa@gnu.org
[-- Attachment #2: COMBINING.flt --]
[-- Type: application/octet-stream, Size: 2075 bytes --]
;; COMBINING.flt -- Font Layout Table for combining diacritical marks
;; Copyright (C) 2007 AIST (H15PRO112)
;; See the end for copying conditions.
(font layouter combining nil)
;;; <li> COMBINING.flt
;;;
;;; For combining diacritical marsk (U+0300..U+036F).
(category
;; The contents is build up by the m17n-lib.
)
(generator
(0
(cond
("(u)([a-t]+)"
(cond
((font-facility :otf=DFLT+mark) < :otf=DFLT=+mark,mkmk >)
(".*"
< = ; combining class
(cond ("a" Bc.Bc =) ; < 200
("b" bl.tc =) ; 200
("c" bc.tc =) ; 202
("d" br.tc =) ; 204
("e" Bl.Br =) ; 208
("f" Br.Bl =) ; 210
("g" tl.bc =) ; 212
("h" tc.bc =) ; 214
("i" tr.bc =) ; 216
("j" bl.tc =) ; 218
("k" bc-tc =) ; 220
("l" br-tc =) ; 222
("m" Bl.Br =) ; 224
("n" Br.Bl =) ; 226
("o" tl+bc =) ; 228
("p" tc+bc =) ; 230
("q" tr+bc =) ; 232
("r" br-tr =) ; 233
("s" tr+br =) ; 234
("t" bc-tc =)) ; 240
* >)))
("[a-t]" [ = ])
("." =))
*))
;; Copyright (C) 2007
;; National Institute of Advanced Industrial Science and Technology (AIST)
;; Registration Number H15PRO112
;; This file is part of the m17n database; a sub-part of the m17n
;; library.
;; The m17n library is free software; you can redistribute it and/or
;; modify it under the terms of the GNU Lesser General Public License
;; as published by the Free Software Foundation; either version 2.1 of
;; the License, or (at your option) any later version.
;; The m17n library is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
;; Lesser General Public License for more details.
;; You should have received a copy of the GNU Lesser General Public
;; License along with the m17n library; if not, write to the Free
;; Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
;; Boston, MA 02110-1301, USA.
;; Local Variables:
;; mode: emacs-lisp
;; End:
next prev parent reply other threads:[~2015-07-10 16:06 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-05 16:24 bug#20984: 25.0.50; Combining accents don't display properly in certain fonts Artur Malabarba
2015-07-05 16:33 ` Eli Zaretskii
2015-07-05 16:42 ` Artur Malabarba
2015-07-05 17:01 ` Eli Zaretskii
2015-07-05 18:02 ` Artur Malabarba
2015-07-06 14:59 ` handa
[not found] ` <CAAdUY-K+xkkeVapMxf44ZwbCXtQYDJGCPZu2PnRhPf-X9R=Npw@mail.gmail.com>
2015-07-06 16:58 ` Artur Malabarba
2015-07-06 17:16 ` Eli Zaretskii
2015-07-09 9:27 ` handa
2015-07-09 17:10 ` Eli Zaretskii
2015-07-09 21:55 ` Artur Malabarba
2015-07-10 6:25 ` Eli Zaretskii
2015-07-10 7:29 ` Artur Malabarba
2015-07-10 16:06 ` handa [this message]
2015-07-15 19:05 ` Artur Malabarba
2015-07-15 19:28 ` Eli Zaretskii
2015-07-15 22:29 ` Artur Malabarba
2015-07-16 2:40 ` Eli Zaretskii
2015-07-16 12:51 ` handa
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=87h9pc575g.fsf@gnu.org \
--to=handa@gnu.org \
--cc=20984@debbugs.gnu.org \
--cc=bruce.connor.am@gmail.com \
--cc=eliz@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.