From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#33232: `gnus-summary-line-format' padding =?UTF-8?Q?doesn=E2=80=99t?= work in gui when there are multiple-column-width characters Date: Fri, 02 Nov 2018 08:36:43 +0200 Message-ID: <83a7msgf44.fsf@gnu.org> References: <87wopw8np3.fsf@portable.galex-713.eu> <87lg6cjtr5.fsf@ericabrahamsen.net> <87efc4idm4.fsf@gmail.com> <87d0rojqyn.fsf@ericabrahamsen.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1541140574 6864 195.159.176.226 (2 Nov 2018 06:36:14 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 2 Nov 2018 06:36:14 +0000 (UTC) Cc: 33232@debbugs.gnu.org, npostavs@gmail.com To: Eric Abrahamsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Nov 02 07:36:09 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIT3u-0001ei-Q7 for geb-bug-gnu-emacs@m.gmane.org; Fri, 02 Nov 2018 07:36:06 +0100 Original-Received: from localhost ([::1]:49927 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIT61-0006F1-0E for geb-bug-gnu-emacs@m.gmane.org; Fri, 02 Nov 2018 02:38:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52040) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIT5r-00065y-QF for bug-gnu-emacs@gnu.org; Fri, 02 Nov 2018 02:38:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gIT5n-00055h-R6 for bug-gnu-emacs@gnu.org; Fri, 02 Nov 2018 02:38:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:54937) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gIT5n-00055Z-NZ for bug-gnu-emacs@gnu.org; Fri, 02 Nov 2018 02:38:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gIT5m-0003CL-Dq; Fri, 02 Nov 2018 02:38:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org, bugs@gnus.org Resent-Date: Fri, 02 Nov 2018 06:38:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 33232 X-GNU-PR-Package: emacs,gnus X-GNU-PR-Keywords: Original-Received: via spool by 33232-submit@debbugs.gnu.org id=B33232.154114062912232 (code B ref 33232); Fri, 02 Nov 2018 06:38:02 +0000 Original-Received: (at 33232) by debbugs.gnu.org; 2 Nov 2018 06:37:09 +0000 Original-Received: from localhost ([127.0.0.1]:59195 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIT4v-0003BE-6W for submit@debbugs.gnu.org; Fri, 02 Nov 2018 02:37:09 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:42250) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIT4t-0003Ao-4E for 33232@debbugs.gnu.org; Fri, 02 Nov 2018 02:37:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gIT4j-0004jZ-Un for 33232@debbugs.gnu.org; Fri, 02 Nov 2018 02:37:01 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:53284) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIT4j-0004iv-Nr; Fri, 02 Nov 2018 02:36:57 -0400 Original-Received: from [176.228.60.248] (port=1755 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gIT4i-0000GT-FA; Fri, 02 Nov 2018 02:36:57 -0400 In-reply-to: <87d0rojqyn.fsf@ericabrahamsen.net> (message from Eric Abrahamsen on Thu, 01 Nov 2018 16:52:32 -0700) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:151937 Archived-At: > From: Eric Abrahamsen > Date: Thu, 01 Nov 2018 16:52:32 -0700 > Cc: 33232@debbugs.gnu.org > > >>> Given this (rectangular) excerpt from my bug-gnu-emacs summary: > >>>> …01-nov…[-> 33224@debbugs.gnu.org ] bug#33224: `message-simpli… > >>>> …01-nov…[Noam Postavsky ] bug#33225: [debbugs.el] Do… > >>>> …01-nov…[-> Noam Postavsky ] bug#33225: [debbugs.el] D… > >>>> …01-nov…[積丹尼 Dan Jacobson ] bug#33226: chromium, firef… > >>> > >>> On my system (Debian, with Xorg, i3, GUI Emacs), the last line has its > >>> “]” sooner than the others. This is because `gnus-correct-length' > >>> (along with `char-width') says each of the first three characters is > >>> two-columns wide: but under GUI, this is untrue, as these three > >>> collectively form exactely 5 columns (and not six, as would calculate > >>> `gnus-correct-length'). > >> > >> Someone just reported something similar on the org list, that > >> `string-width' doesn't return the actual width occupied by the string, > >> which you'd think would be the whole point. > > > > See Bug#31588, the width of these characters depends on the font, so > > string-width (which works only on a string) can't give the right answer. > > Or, from another point of view, it's the font's fault for being too > > narrow on these characters. > > Yeah, I figured it was probably a font issue, but still it's kind of > misleading to have a function that *sounds* like it's going to handle > the font issue, but doesn't. The only reliable way of getting pixelwise alignment in GUI frames is to use the :align-to display spec, or other related display property specs that provide pixelwise width and alignment.