all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Gustavo Barros <gusbrs.2016@gmail.com>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 48936@debbugs.gnu.org
Subject: bug#48936: 27.2; pulse-reset-face and extend attribute of pulse-highligh-face
Date: Sun, 13 Jun 2021 10:20:02 -0300	[thread overview]
Message-ID: <87lf7d9a0t.fsf@gmail.com> (raw)
In-Reply-To: <87k0my2ale.fsf@gnus.org>

Hi Lars,

On Sun, 13 Jun 2021 at 09:49, Lars Ingebrigtsen <larsi@gnus.org> wrote:

> Gustavo Barros <gusbrs.2016@gmail.com> writes:
>
>> Considering the role `pulse-highlight-face' plays in the way `pulse' 
>> works, it would be expected that this resetting should also be done 
>> for 
>> the `:extend' attribute when the function is called without an 
>> argument, 
>
> I think that sounds correct, so I've now made this change in Emacs 28.

Thank you for looking into this.

But my suggestion was more the one to use the `:extend' attribute of 
`pulse-highlight-start-face' to reset `pulse-highlight-face'. Like:

#+begin_src emacs-lisp
(set-face-extend 'pulse-highlight-face
                 (if face 
                     (face-extend-p face nil t)
                   (face-extend-p 'pulse-highlight-start-face)))
#+end_src

Because `pulse-highlight-start-face' is the default face `pulse' uses 
when the `pulse-momentary-highlight-...' functions are called without 
argument.  This makes `pulse-highlight-start-face' the only possible 
handle for setting the `:extend' attribute for calls of `pulse' 
functions without argument. If you just set it to nil when a call with 
no argument is made, we can still only get a pulse to work with 
`:extend' by explicitly passing the argument.

Btw, this is the same treatment `:background' receives. Why should we 
treat both face attributes differently?

Best regards,
Gustavo.





  reply	other threads:[~2021-06-13 13:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-09 14:15 bug#48936: 27.2; pulse-reset-face and extend attribute of pulse-highligh-face Gustavo Barros
2021-06-13 12:49 ` Lars Ingebrigtsen
2021-06-13 13:20   ` Gustavo Barros [this message]
2021-06-13 13:39     ` Lars Ingebrigtsen
2021-06-13 13:45       ` Gustavo Barros
2021-06-13 14:12         ` Eli Zaretskii
2021-06-13 14:32           ` Gustavo Barros

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

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

  git send-email \
    --in-reply-to=87lf7d9a0t.fsf@gmail.com \
    --to=gusbrs.2016@gmail.com \
    --cc=48936@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.