From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#56695: A new and old font problem with Arabic Date: Fri, 22 Jul 2022 17:18:46 +0300 Message-ID: <83tu79jkmx.fsf@gnu.org> References: <1658477476172.1551810.eccda65c0f1753ea37e1355f26961ec46de3f906@spica.telekom.de> <83edydl80c.fsf@gnu.org> <1658497265479.1589294.1e7fbe71a9c257912af2f6c3a3b45532d616817d@spica.telekom.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26979"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 56695@debbugs.gnu.org To: "fr_ml@t-online.de" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Jul 22 16:19:14 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oEtUk-0006oq-SV for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 22 Jul 2022 16:19:11 +0200 Original-Received: from localhost ([::1]:53858 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oEtUj-0005C3-Hh for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 22 Jul 2022 10:19:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:55532) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEtUd-0005Bq-2S for bug-gnu-emacs@gnu.org; Fri, 22 Jul 2022 10:19:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:52340) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oEtUc-00008H-Pl for bug-gnu-emacs@gnu.org; Fri, 22 Jul 2022 10:19:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oEtUc-0005OG-Hv for bug-gnu-emacs@gnu.org; Fri, 22 Jul 2022 10:19:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 22 Jul 2022 14:19:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56695 X-GNU-PR-Package: emacs Original-Received: via spool by 56695-submit@debbugs.gnu.org id=B56695.165849954220716 (code B ref 56695); Fri, 22 Jul 2022 14:19:02 +0000 Original-Received: (at 56695) by debbugs.gnu.org; 22 Jul 2022 14:19:02 +0000 Original-Received: from localhost ([127.0.0.1]:42089 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oEtUb-0005O1-Jr for submit@debbugs.gnu.org; Fri, 22 Jul 2022 10:19:01 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:42628) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oEtUX-0005Nm-P4 for 56695@debbugs.gnu.org; Fri, 22 Jul 2022 10:19:00 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:44138) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEtUR-00007o-Ig; Fri, 22 Jul 2022 10:18:51 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=s+L9C9PY9F4vk2ZnzjOc6dmu0ihi0Ie1EZIxEDcKrq8=; b=q4nlywwGSGvsuxy5Etsh AQ/v2TIfhPJbtchiB6Ne0utYzLndRmrgUaKg+2K3kTf8vNpCphEerwTaydrbeD2DIq235sInE7/t1 LJIus6I4Gx1Le390bwsSft9UjjHiR3h7AT3D6GhzrqI83Rse5Zrg13O+UyHvcGHx4KRmqXMtc6Mhx 1XlqISiq+wpta3qLX1VMV7XgNOJ0ul0ivp1Bs8yqseTk3fxWksGbpliOjfUyBUkFKHxPSi/pmqoJ0 u8UN/s7hcDgdxIJC2o84cuTeoWZLkNAUjMCVB6tIWJM6qLnpEUI7Zj6LAS9k4u8DpJZkqwOmNbxFX 2EhnFtdQrgCtEA==; Original-Received: from [87.69.77.57] (port=2175 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEtUR-0003VI-6h; Fri, 22 Jul 2022 10:18:51 -0400 In-Reply-To: <1658497265479.1589294.1e7fbe71a9c257912af2f6c3a3b45532d616817d@spica.telekom.de> (fr_ml@t-online.de) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:237629 Archived-At: [Please use Reply All to keep the bug tracker CC'ed.] > Date: Fri, 22 Jul 2022 15:41:05 +0200 (CEST) > From: "fr_ml@t-online.de" > > > 1. I can't change the Arabic characters to the font of DejaVu Sans > > > Mono (or others). This wasn't a problem before. > > > > What do you mean by "cannot change"? What happens if you try? Please > > show the exact sequence of commands or Lisp code you used, and any > > error messages or incorrect effects you see when you do that. > I use the mouse with left click to chose 'Change Buffer Font'. > I don't get any error message. Just: "Buffer-Face mode enabled". > The Latin letters get their new font, but the Arabic ones don't. This is not a bug: if the font you choose cannot support Arabic, Emacs will fall back to the setup in the current fontset. In general, selecting a font only affects ASCII characters; it affects non-ASCII characters only if the font can display them properly. > > > Can Harfbuzz be a problem? In the older emacs version (maybe 3 or 4 years ago?) I never had these > > > problems. > > > > I don't know, because critical information is missing: > > > > . on what OS is that? > Linux. I've tried Ubuntu and Arch. > > . what is the version of HarfBuzz you have installed? > harfbuzz 4.4.1-1 > > . what is the text that is not displayed correctly? (please provide > > it as plain text that can be copied and examined, not as an image) > Sorry. I forgot: > ( > a-b-c-d > 1234567 > س-س-س-س > 1234567 > ) I don't think HarfBuzz is a problem in your case, but the font probably is. > > . what does Emacs say when you go to the characters involved in this > > display and type "C-u C-x ="? > Before changing the font: > > position: 23 of 32 (69%), column: 6 > character: س‎ (displayed as س‎) (codepoint 1587, #o3063, #x633) > charset: unicode (Unicode (ISO10646)) > code point in charset: 0x0633 > script: arabic > syntax: w which means: word > category: .:Base, R:Strong R2L, b:Arabic > to input: type "C-x 8 RET 633" or "C-x 8 RET ARABIC LETTER SEEN" > buffer code: #xD8 #xB3 > file code: #xD8 #xB3 (encoded by coding system utf-8-unix) > display: by this font (glyph code): > ftcrhb:-1ASC-Droid Serif-normal-normal-normal-*-13-*-*-*-*-0-iso10646-1 (#x0E) So Emacs uses the Droid Serif font for Arabic, and I guess that's the problem. > > Character code properties: customize what to show > name: ARABIC LETTER SEEN > general-category: Lo (Letter, Other) > decomposition: (1587) ('س') > ---- > After changing, or trying to change it:I get exactly the same output. > > > > > In general DejaVu Sans is known as a problematic font for complex text > > shaping (which is required for Arabic), so my advice is to use some > > other font as the default. > DejaVu Sans Mono was always ok. And often I need a monospaced font - do you know another one for Arabic? Try the Amiri font, I'm told it is OK. But you need to set that up in the fontset; do not use Amiri as your default font.