From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Adam Porter Newsgroups: gmane.emacs.bugs Subject: bug#56874: 28.1.50; tab-bar-format-align-right should probably use string-width Date: Fri, 5 Aug 2022 15:32:35 -0500 Message-ID: <40b946ca-71eb-0904-f1b1-773e5134bc4f@alphapapa.net> References: <86pmhjbzmw.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1553"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.6.1 Cc: 56874@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Aug 05 22:33:18 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 1oK40T-0000CL-I9 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 05 Aug 2022 22:33:17 +0200 Original-Received: from localhost ([::1]:38220 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oK40S-0004X7-2a for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 05 Aug 2022 16:33:16 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:43710) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oK40F-0004UB-9g for bug-gnu-emacs@gnu.org; Fri, 05 Aug 2022 16:33:07 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:42660) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oK40F-0001he-0x for bug-gnu-emacs@gnu.org; Fri, 05 Aug 2022 16:33:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oK40E-0001Dc-IS for bug-gnu-emacs@gnu.org; Fri, 05 Aug 2022 16:33:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Adam Porter Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 05 Aug 2022 20:33:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56874 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 56874-submit@debbugs.gnu.org id=B56874.16597315664658 (code B ref 56874); Fri, 05 Aug 2022 20:33:02 +0000 Original-Received: (at 56874) by debbugs.gnu.org; 5 Aug 2022 20:32:46 +0000 Original-Received: from localhost ([127.0.0.1]:60642 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oK3zx-0001D4-Rv for submit@debbugs.gnu.org; Fri, 05 Aug 2022 16:32:46 -0400 Original-Received: from boar.tulip.relay.mailchannels.net ([23.83.218.250]:64903) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oK3zu-0001Cr-IR for 56874@debbugs.gnu.org; Fri, 05 Aug 2022 16:32:45 -0400 X-Sender-Id: dreamhost|x-authsender|inbox@alphapapa.net Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 620EF6A1A8F; Fri, 5 Aug 2022 20:32:38 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a207.dreamhost.com (unknown [127.0.0.6]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 83D476A1A07; Fri, 5 Aug 2022 20:32:37 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1659731557; a=rsa-sha256; cv=none; b=SFedXtcbycIwz3Cfb62ue9+lZ7XMNKsmynDQAZmRemcuwSKEowI3CzxD40XFlulotx3XoH /uCaHFbBBAzi2n6JFqxEwCYgugpg0yzfxpjbRTrWo67gtrCyBHB1mnCQapbRCwBcjmQ5dj 2rG7oNYAeuGCmNJ6rV7GKoBFhcl/U/YIo2NILxxCPrehHuSv+s75Mt6WJMN7smicklF+Vi hkfguFJEZYa+IFcHxPVXN9IaTINxWFb8xK2KldQRN7W0Vi3fZcNt/4tIWUNSqmOHK9ITJm AZyexQQpHnI8VBoFG+GWpFRU8Ap3TKIULgfVseL/zFooKiH5DcXBMA/3iEZsWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1659731557; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=nmrbQ3zazJruHaUJ+QmeRfveVDFDU3sPd1k/g5S3kG4=; b=X+eK9xJaZEHJ+KAbOzIpM3RkZ9HGmD4jgog39IrSyuI9bl4rrBogQN+yaydsltjg5nIcAu JGEO0pFtubJ5/yLMjthLshIqMg6bg1Br0k6vXYPbvaVqGI6bKOXx9JL1NOZESIjfyt4caT JWP4y9jeODN/xsTAiuSVWQJ9+T0+M5xRmZORSJoYyOGogIMZeIYgVfYT2Kt39E/qFqNlMa Mn2AQOR0yiHJVyRVumiiIza8t7e99VFzL54EWU8q8Rb1jGGPJX5hsmMC2r47DuJmudHfln lcfRP497tpU7Iv4IiL4ZFkiBnwa3I54wpBcyWDkANG6Hvtyty2/S47nkXitgRg== ARC-Authentication-Results: i=1; rspamd-7586b5656-w46fl; auth=pass smtp.auth=dreamhost smtp.mailfrom=adam@alphapapa.net X-Sender-Id: dreamhost|x-authsender|inbox@alphapapa.net X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|inbox@alphapapa.net X-MailChannels-Auth-Id: dreamhost X-Fumbling-Absorbed: 0ef3d8fb766485d8_1659731557769_2952051948 X-MC-Loop-Signature: 1659731557769:1029233920 X-MC-Ingress-Time: 1659731557769 Original-Received: from pdx1-sub0-mail-a207.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.103.123.82 (trex/6.7.1); Fri, 05 Aug 2022 20:32:37 +0000 Original-Received: from [10.58.0.10] (unknown [45.131.192.220]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: inbox@alphapapa.net) by pdx1-sub0-mail-a207.dreamhost.com (Postfix) with ESMTPSA id 4Lzy2X6lsyzPs; Fri, 5 Aug 2022 13:32:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alphapapa.net; s=dreamhost; t=1659731557; bh=nmrbQ3zazJruHaUJ+QmeRfveVDFDU3sPd1k/g5S3kG4=; h=Date:Subject:To:Cc:From:Content-Type:Content-Transfer-Encoding; b=F2eg/NzUMnAPSqZUHPcd1cycTxTnnk5Qq8ppXIrVaaF/WKyK5LTuUA8eSCjSh3hbl aPfpbI9FUX99SBBClymG1THZ0A+wXueO1XkkHf89Be7JWOTRmdBL2fxpQDNb57mCq9 wsjj2YjvvhufQvJDt5frcuxXsen/O2mWkzfU7W1lbcxCkKPr2WeK7KJ0d/f46gfGf4 oGaPDhwLP/aiZDwoJnF3gBrNzvPqklgzQTfJNZjsYoU1NGmYWDms/UbhqLP+daK1q8 VyD1vn+b+pvBTbN9SR/EOR2HktTDPqvTtqs+isN92FPRpgoSIegV4zcMafnEHP011r kt4jCBDk2cuGw== Content-Language: en-US In-Reply-To: <86pmhjbzmw.fsf@mail.linkov.net> 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:238942 Archived-At: Hi Juri, On 8/1/22 13:13, Juri Linkov wrote: > Please check Emacs 29 where tab-bar-format-align-right > contains a better improvement: > > (string-pixel-width (propertize rest 'face 'tab-bar)) > > Does this work in your case as well? I don't have an Emacs 29 build readily accessible, but I see that Emacs 28 has the function `shr-string-pixel-width', which I'm guessing is similar. So I tried using that function, and it is an improvement, but not quite correct: rather than wrapping onto a new line, the string appears on the same line as the rest of the tab-bar, but it is not right-aligned as it should be. If it would help you reproduce the problem to test whether Emacs 29 already has a fix, all that seems to be necessary is to set the tab-bar face to, e.g. ":height 1.2", and add a string of some length (e.g. about 20) to the global-mode-string, and see whether it wraps onto a new line and whether it's right-aligned. If it seems correct on Emacs 29, then I'd guess it's already solved. Thanks, Adam