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#65803: 29.1; Noto Sans Mono CJK JP has doubled-width on Windows Date: Sun, 10 Sep 2023 08:22:57 +0300 Message-ID: <834jk2txe6.fsf@gnu.org> References: <83bkeeytwf.fsf@gnu.org> <838r9iyrky.fsf@gnu.org> <835y4myqtb.fsf@gnu.org> <83jzt1xju6.fsf@gnu.org> <83wmx0x3hj.fsf@gnu.org> <87wmx0dbn6.fsf@yahoo.com> <834jk3v8ux.fsf@gnu.org> <87wmwzbh5z.fsf@yahoo.com> <83pm2rtmvz.fsf@gnu.org> <87o7iac05e.fsf@yahoo.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35457"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 65803@debbugs.gnu.org, shingo.fg8@gmail.com To: Po Lu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Sep 10 07:24:12 2023 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 1qfCvc-00091P-EK for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 10 Sep 2023 07:24:12 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qfCvR-00061E-C9; Sun, 10 Sep 2023 01:24:02 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qfCvP-00060y-2g for bug-gnu-emacs@gnu.org; Sun, 10 Sep 2023 01:23:59 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qfCvO-000225-RW for bug-gnu-emacs@gnu.org; Sun, 10 Sep 2023 01:23:58 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qfCvS-0000VZ-2f for bug-gnu-emacs@gnu.org; Sun, 10 Sep 2023 01:24: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: Sun, 10 Sep 2023 05:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65803 X-GNU-PR-Package: emacs Original-Received: via spool by 65803-submit@debbugs.gnu.org id=B65803.16943234071911 (code B ref 65803); Sun, 10 Sep 2023 05:24:02 +0000 Original-Received: (at 65803) by debbugs.gnu.org; 10 Sep 2023 05:23:27 +0000 Original-Received: from localhost ([127.0.0.1]:48777 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qfCus-0000Ul-SR for submit@debbugs.gnu.org; Sun, 10 Sep 2023 01:23:27 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50390) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qfCuq-0000UY-3H for 65803@debbugs.gnu.org; Sun, 10 Sep 2023 01:23:25 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qfCuh-0001zn-1V; Sun, 10 Sep 2023 01:23:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=I3ezpwG2lqjyF2MH1Z0iOg3nuvxT/q3eme/iW/JIPEM=; b=rm+9xraar+FS yGuNoKsf6ESa8lnK4t2VmdiMSf+aIzzpgGMNku2DHnICyFkpJ9g6Yz9Nt2WNN+4mc6v8DgQuV3Scb ImBJpzFF/SZsQ5iGtDz/uwLnCIbZnkhbQSnNBDNLy0EjBzI0y9ZfhalLeYbtP6M+sGAaTlHZ1RV1k BoEBBFBLgf6eH2nuYn2RpkMf7ByYIk9O1yVeeDfxjD+LBdcF2KBZpozSbuJWpcctmG12pya8DCDJM px8XTldY54RCq85QDE3ts36NgJiyfJp1enFbnmXmEm0ojIyPJZmuL/4aSkvl+IeY/fz1uAvlvuBFl a+XyO2AKw41AaEhkv6rMtA==; In-Reply-To: <87o7iac05e.fsf@yahoo.com> (message from Po Lu on Sun, 10 Sep 2023 09:00:45 +0800) 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:269910 Archived-At: > From: Po Lu > Cc: shingo.fg8@gmail.com, 65803@debbugs.gnu.org > Date: Sun, 10 Sep 2023 09:00:45 +0800 > > Eli Zaretskii writes: > > > Basically, calculating our own estimate of the average width means we > > discard the attribute reported by the font, in effect backing up on > > the change made in OpenType spec v3, which deprecated the previous > > requirement to compute the average width based only on ASCII > > characters. This seems to be justified only because Emacs uses the > > average width of the font for one purpose only: to calculate the > > default column width of a frame. So this calculation is only relevant > > for when a font is used as the default face's font. If we ever decide > > to use the average width for anything else, we might be bitten by > > this. > > > > So I think a cleaner solution would be to leave the average width > > attribute as the font reports it, and introduce a new attribute for > > the average width of the ASCII characters. Not sure how urgent this > > is, but we should at least describe this subtlety in the comments. > > However, the only function of the average width property is to provide > the average width of ASCII characters AFAICT, we never use this for anything but FRAME_COLUMN_WIDTH. So when you talk about "average width of ASCII characters", I don't think I understand what is that property, since we never call it like that and never use it for ASCII characters. > Moreover, the average width attribute in > older TrueType fonts is that of each ASCII glyph, and several fonts > provide no average width attribute at all (given that an OS/2 table need > not be supplied in fonts that aren't designed to function under > MS-Windows), in which case calculating its value for each glyph at > load-time will prove prohibitively expensive. I don't understand what you are trying to say here. Who suggested to calculate the value of the average width for each glyph in the font at load time?