unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Kangas <stefan@marxist.se>
To: martin rudalics <rudalics@gmx.at>, Eli Zaretskii <eliz@gnu.org>
Cc: thomas.hisch@ims.co.at, 41852@debbugs.gnu.org
Subject: bug#41852: 27.0.50; text-scale commands don't scale header of tabulated-list-mode
Date: Fri, 30 Oct 2020 16:04:58 +0000	[thread overview]
Message-ID: <CADwFkm=xXDkMB66rUKLjPq_kFRWmo1wua9MaQJLYarw_Akk-WQ@mail.gmail.com> (raw)
In-Reply-To: <2ae49edc-098f-9ace-595d-9e29bf3d2c8b@gmx.at>

martin rudalics <rudalics@gmx.at> writes:

>  > +default) will also change the text height of the 'header-line' face.
>
> I'd prefer "font size" instead of "text height" here.

Fixed.

> Also, I'd like to see some clarification
>
> (1) that only the size of the header line face for a buffer where
> 'text-scale-mode-header-line' has been set is affected (the line above
> is IMHO too general to state this restriction),

Could you be more specific?  It already says it's buffer local, but it
seems like you think it should say something more?

Do you mean to be very explicit about it, like this?

  When the new buffer local variable 'text-scale-remap-header-line-face'
  is non-nil, 'text-scale-adjust' will also change the font size of the
  'header-line' face in the current buffer.  This will also affect any
  face that inherits from it.

> (2) that text in the header line or elsewhere in such a buffer not
> inheriting from (the remapped) header line face is unaffected, and

I'm not sure I understand what you mean.  If text-scale-mode is enabled,
typically through running e.g. `text-scale-increase', the `default' face
is scaled.  The result, AFAICT, is that all faces in the buffer change
size (well, not the mode line).  And that makes sense since all other
implicitly inherits from it, right?

This works even for anonymous faces, e.g.:

   (progn
    (fundamental-mode)
    (insert (propertize "foo" 'face '(:height 1.5)))
    (text-scale-increase))

What am I missing?

> (3) whether and how existing customizations of the header line face are
> taken into account.
>
> Wrt (3) I assume that 'tabulated-list-mode' can already get derailed
> when a user customizes header line face to use some large or small font
> size (a scenario where face remapping is not involved at all).

I tried customizing the `Height' for the `header-line' face, and it
seems to work as expected:

With no text-scale-mode it is as big as it is customized to be.  When I
run `text-scale-increase', it scales up accordingly (relative to its
customized size).  So I don't know what, if anything, should be added
here.  Since it works as expected, perhaps there is nothing to add?

> Note that maybe 'text-scale-mode-header-line' should be also watched by
> 'set-buffer-redisplay'.

I tried adding `text-scale-remap-header-line-face' to the list of
variables that are fed to `add-variable-watcher' at the end of frame.el.
That doesn't work, unfortunately.

I believe that since the remapping is done on a Lisp level,
`text-scale-mode' isn't called even with a variable watcher.  Is there a
way to work around that?  Or am I doing it wrong?

Thanks for taking the time to review this.





  reply	other threads:[~2020-10-30 16:04 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-14 13:36 bug#41852: 27.0.50; text-scale commands don't scale header of tabulated-list-mode Thomas Hisch
2020-06-14 14:42 ` Eli Zaretskii
2020-06-14 16:25   ` Thomas Hisch
2020-10-18 23:34     ` Stefan Kangas
2020-10-19 14:19       ` Eli Zaretskii
2020-10-19 18:21         ` Stefan Kangas
2020-10-19 19:02           ` Eli Zaretskii
2020-10-19 22:41             ` Stefan Kangas
2020-10-20 14:15               ` Eli Zaretskii
2020-10-20 14:40                 ` Stefan Kangas
2020-10-20 14:45                   ` Eli Zaretskii
2020-10-20 19:10                     ` Thomas Hisch
2020-10-29 17:43                       ` Stefan Kangas
2020-10-29 19:37                         ` Thomas Hisch
2020-10-29 21:45                           ` Stefan Kangas
2020-10-30  8:01                             ` Eli Zaretskii
2020-10-29 17:33                     ` Stefan Kangas
2020-10-29 18:02                       ` Drew Adams
2020-10-29 18:15                         ` Stefan Kangas
2020-10-29 18:32                           ` Drew Adams
2020-10-29 18:47                             ` Stefan Kangas
2020-10-30  8:54                       ` martin rudalics
2020-10-30 16:04                         ` Stefan Kangas [this message]
2020-10-30 17:37                           ` martin rudalics
2020-10-30 19:01                             ` Eli Zaretskii
2020-10-31  0:31                             ` Stefan Kangas
2020-10-31  8:00                               ` martin rudalics
2020-10-30 18:54                           ` Eli Zaretskii
2020-10-30 20:22                             ` Stefan Kangas
2020-10-30 20:53                               ` Eli Zaretskii
2020-10-31 16:15                                 ` Stefan Kangas
2020-10-31 16:48                                   ` Eli Zaretskii
2020-10-31 16:57                                     ` Eli Zaretskii
2020-10-31 17:55                                     ` Eli Zaretskii
2020-11-12 22:25                                       ` Stefan Kangas
2020-11-13  7:51                                         ` Eli Zaretskii
2020-11-25  2:08                                           ` Stefan Kangas
2020-11-13  8:49                                         ` martin rudalics
2020-11-25  2:08                                           ` Stefan Kangas
2020-11-13 13:00                                         ` Jean Louis
2020-11-13 14:32                                           ` Stefan Kangas
2020-11-13 15:33                                             ` Jean Louis
2020-11-13 16:07                                         ` github.com
2020-11-13 16:49                                           ` Stefan Kangas
2020-10-31 16:50                                   ` Stefan Kangas
2020-10-31  8:29                       ` Eli Zaretskii
2020-10-31 16:25                         ` Stefan Kangas
     [not found] <<955fe4fe-a64d-b7c6-fe31-7efd810f97a5@ims.co.at>
     [not found] ` <<83mu553e0x.fsf@gnu.org>
2020-06-14 16:28   ` Drew Adams
2020-06-14 17:23     ` Thomas Hisch

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CADwFkm=xXDkMB66rUKLjPq_kFRWmo1wua9MaQJLYarw_Akk-WQ@mail.gmail.com' \
    --to=stefan@marxist.se \
    --cc=41852@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=rudalics@gmx.at \
    --cc=thomas.hisch@ims.co.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).