From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: "Garreau\, Alexandre" 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: Thu, 01 Nov 2018 22:58:32 +0100 Message-ID: <87wopw8np3.fsf@portable.galex-713.eu> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1541109457 23122 195.159.176.226 (1 Nov 2018 21:57:37 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 1 Nov 2018 21:57:37 +0000 (UTC) User-Agent: Gnus (5.13), GNU Emacs 25.1.1 (i686-pc-linux-gnu, GTK+ Version 3.22.11) of 2017-09-15, modified by Debian To: 33232@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Nov 01 22:57:33 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 1gIKy5-0005vI-HC for geb-bug-gnu-emacs@m.gmane.org; Thu, 01 Nov 2018 22:57:33 +0100 Original-Received: from localhost ([::1]:46321 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIL0B-0007R7-Tc for geb-bug-gnu-emacs@m.gmane.org; Thu, 01 Nov 2018 17:59:43 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39790) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIKzw-0007O1-Iw for bug-gnu-emacs@gnu.org; Thu, 01 Nov 2018 17:59:31 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gIKzY-0003p8-Q0 for bug-gnu-emacs@gnu.org; Thu, 01 Nov 2018 17:59:17 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:54738) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gIKzY-0003oy-Kd for bug-gnu-emacs@gnu.org; Thu, 01 Nov 2018 17:59:04 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gIKzX-0005Hb-8p; Thu, 01 Nov 2018 17:59:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: "Garreau\, Alexandre" Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org, bugs@gnus.org Resent-Date: Thu, 01 Nov 2018 21:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 33232 X-GNU-PR-Package: emacs,gnus X-GNU-PR-Keywords: X-Debbugs-Original-To: submit@debbugs.gnu.org (The Gnus Bugfixing Girls + Boys) Original-Received: via spool by submit@debbugs.gnu.org id=B.154110951620228 (code B ref -1); Thu, 01 Nov 2018 21:59:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 1 Nov 2018 21:58:36 +0000 Original-Received: from localhost ([127.0.0.1]:58991 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIKz5-0005GB-Ul for submit@debbugs.gnu.org; Thu, 01 Nov 2018 17:58:36 -0400 Original-Received: from portable.galex-713.eu ([89.234.186.82]:48464) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gIKz4-0005G3-In for submit@debbugs.gnu.org; Thu, 01 Nov 2018 17:58:35 -0400 Original-Received: from localhost ([::1] helo=portable.galex-713.eu) by portable.galex-713.eu with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1gIKz2-0000Lt-GZ for submit@debbugs.gnu.org; Thu, 01 Nov 2018 22:58:32 +0100 PGP-FINGERPRINT: E109 9988 4197 D7CB B0BC 5C23 8DEB 24BA 867D 3F7F Accept-Language: fr, en, eo, it, br 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:151918 Archived-At: Given this (rectangular) excerpt from my bug-gnu-emacs summary: > =E2=80=A601-nov=E2=80=A6[-> 33224@debbugs.gnu.org ] bug#33224: `me= ssage-simpli=E2=80=A6 > =E2=80=A601-nov=E2=80=A6[Noam Postavsky ] bug#33225: [de= bbugs.el] Do=E2=80=A6 > =E2=80=A601-nov=E2=80=A6[-> Noam Postavsky ] bug#33225: [d= ebbugs.el] D=E2=80=A6 > =E2=80=A601-nov=E2=80=A6[=E7=A9=8D=E4=B8=B9=E5=B0=BC Dan Jacobson = ] bug#33226: chromium, firef=E2=80=A6 On my system (Debian, with Xorg, i3, GUI Emacs), the last line has its =E2=80=9C]=E2=80=9D 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'). You can check that by eval=E2=80=99ing: > (window-text-pixel-size nil (- (point) 593) (- (point) 588)) > (window-text-pixel-size nil (- (point) 583) (- (point) 580)) which return the width of the three first characters after =E2=80=9C[=E2=80= =9D in the two last summary lines. According `gnus-correct-length' they=E2=80=99r the same size: > (gnus-correct-length "[=E7=A9=8D=E4=B8=B9=E5=B0=BC Dan Jacobson = ]") > (gnus-correct-length "[-> Noam Postavsky ]") According `char-width' the fact each character is considered to have a width which is a multiple of the others makes them the same size: > (mapcar #'char-width "[=E7=A9=8D=E4=B8=B9=E5=B0=BC Dan Jacobson = ]") > (mapcar #'char-width "[-> Noam Postavsky ]") So would it be better to get gnus-correct-length keep returning a column number but as a float to be somewhat compatible? or working with pixels when operating in a GUI frame? but how would padding, which is said to be in numbers of column, operate then? or should it stay with a behavior that works in terminal but breaks in gui? I=E2=80=99m reporting this at least for archive, in case someone have an id= ea. But I=E2=80=99m not sure the solution is that trivial. Gnus v5.13 GNU Emacs 25.1.1 (i686-pc-linux-gnu, GTK+ Version 3.22.11) of 2017-09-15, modified by Debian