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#41852: 27.0.50; text-scale commands don't scale header of tabulated-list-mode Date: Mon, 19 Oct 2020 17:19:52 +0300 Message-ID: <83y2k2pabb.fsf@gnu.org> References: <955fe4fe-a64d-b7c6-fe31-7efd810f97a5@ims.co.at> <83mu553e0x.fsf@gnu.org> <953c6df9-59b4-8b57-0be3-600d147fe9c7@ims.co.at> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7118"; mail-complaints-to="usenet@ciao.gmane.io" Cc: thomas.hisch@ims.co.at, 41852@debbugs.gnu.org To: Stefan Kangas Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Oct 19 16:20:10 2020 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 1kUW1C-0001kw-CG for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 19 Oct 2020 16:20:10 +0200 Original-Received: from localhost ([::1]:48108 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kUW1B-0007wd-BH for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 19 Oct 2020 10:20:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:56426) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kUW14-0007wU-Oa for bug-gnu-emacs@gnu.org; Mon, 19 Oct 2020 10:20:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58657) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kUW14-0003vR-EW for bug-gnu-emacs@gnu.org; Mon, 19 Oct 2020 10:20:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kUW14-0007He-8x for bug-gnu-emacs@gnu.org; Mon, 19 Oct 2020 10:20: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: Mon, 19 Oct 2020 14:20:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41852 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 41852-submit@debbugs.gnu.org id=B41852.160311719627982 (code B ref 41852); Mon, 19 Oct 2020 14:20:02 +0000 Original-Received: (at 41852) by debbugs.gnu.org; 19 Oct 2020 14:19:56 +0000 Original-Received: from localhost ([127.0.0.1]:41970 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUW0x-0007HG-MK for submit@debbugs.gnu.org; Mon, 19 Oct 2020 10:19:55 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:49562) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUW0v-0007Gz-OI for 41852@debbugs.gnu.org; Mon, 19 Oct 2020 10:19:54 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:34666) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kUW0p-0003t3-3Q; Mon, 19 Oct 2020 10:19:47 -0400 Original-Received: from [176.228.60.248] (port=3826 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kUW0o-0003gA-Fj; Mon, 19 Oct 2020 10:19:46 -0400 In-Reply-To: (message from Stefan Kangas on Sun, 18 Oct 2020 16:34:23 -0700) 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:190987 Archived-At: > From: Stefan Kangas > Date: Sun, 18 Oct 2020 16:34:23 -0700 > Cc: Eli Zaretskii , 41852@debbugs.gnu.org > > How about the attached patch? It's probably a good feature, but it has at least one caveat: setting that variable non-nil will cause not only the header-line face to be rescaled, it will also cause any face that inherits from header-line to be rescaled. Not sure if this is a problem, but it should be called out in NEWS, at least. > +** text-scale-mode > + > +--- > +*** text-scale-mode can adjust text height of header line face. > +When the new buffer local variable 'text-scale-mode-header-line' is > +non-nil, 'text-scale-adjust' (bound to 'C-x C-+' and 'C-x C--' by > +default) will also change the text height of the header line face. > +This feature is intended for use by Emacs Lisp package authors. This should mention modes that arrange their display in tabular form below the header-line, such as tabulated-list-mode and its descendants. Otherwise the last sentence and the goal of the feature itself are left on a level that's too abstract. > -(make-variable-buffer-local 'text-scale-mode-remapping) > +(make-obsolete-variable 'text-scale-mode-remapping "no longer used." "28.1") > + > +(defvar text-scale-mode--remappings nil > + "List of current remapping cookies for `text-scale-mode'.") Why this change? > +(defvar text-scale-mode-header-line nil I suggest to name this text-scale-remap-header-line-face. > + "If non-nil, also change text height of the header line.") Not just height, the size. Also, please say "`header-line' face", and mention that all the faces that inherit from it will be affected as well. > +(defun face-remap--remap-face (sym) > + (push (face-remap-add-relative sym > + :height > + (expt text-scale-mode-step > + text-scale-mode-amount)) > + text-scale-mode--remappings)) I wonder whether this is all there is to it. The display code doesn't automatically use the remapped face in all cases, we need to code that "by hand" in each and every case. So far we've been doing that only for the default face; I wonder if we'll have to do something similar for header-line on the C level... Please be sure to test this in every possible way, including cursor motion around such rescaled header-lines etc. Thanks.