all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Pierre Téchoueyres" <pierre.techoueyres@free.fr>
To: Protesilaos Stavrou <info@protesilaos.com>
Cc: 54598@debbugs.gnu.org, Lars Ingebrigtsen <larsi@gnus.org>
Subject: bug#54598: 27.2; Bad interraction between modus-theme and hs-minor-mode
Date: Thu, 31 Mar 2022 21:24:16 +0200	[thread overview]
Message-ID: <87fsmxc3tv.fsf@killashandra.ballybran.fr> (raw)
In-Reply-To: <87ee2iw9p3.fsf@protesilaos.com>

[-- Attachment #1: Type: text/plain, Size: 438 bytes --]

Hello Protesilaos,
Le jeudi 31 mars 2022 à 16:08, Protesilaos Stavrou 
<info@protesilaos.com> a écrit :
> ...
> Pierre, your suggestion to filter the custom-enabled-themes is 
> better
> than what we have.  Do you want to send it to me as a patch?
What dou you think of the attached one ?

>
> All the best,
Same here :-)
> Prot

Apart from that, do you know why the vertical line doesn't look 
the
same on Windows ?


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Filter modus themes on modus-themes--current-theme --]
[-- Type: text/x-patch, Size: 1265 bytes --]

From 2e9802aceb9e2e77dd91f54a7727177038a35aec Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pierre=20T=C3=A9choueyres?= <pierre.techoueyres@free.fr>
Date: Thu, 31 Mar 2022 21:16:42 +0200
Subject: [PATCH] Filter modus themes on modus-themes--current-theme

When custom-enabled-themes contains many themes, we're only
interrested by the first modus-* one.  This avoid a crash when
modus-themes--palette is called which complains that the first
theme returned by modus-themes--current-theme isn't either
modus-operandi or modus-vivendi (pcase use).
---
 modus-themes.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/modus-themes.el b/modus-themes.el
index 3f0e098..3a9a26e 100644
--- a/modus-themes.el
+++ b/modus-themes.el
@@ -3191,8 +3191,9 @@ Those are stored in `modus-themes-faces' and
        (custom-theme-set-variables ',name ,@modus-themes-custom-variables))))
 
 (defun modus-themes--current-theme ()
-  "Return current theme."
-  (car custom-enabled-themes))
+  "Return current modus theme."
+  (car (seq-filter (lambda (arg) (string-match-p "^modus" (symbol-name arg)))
+                   custom-enabled-themes)))
 
 ;; Helper functions that are meant to ease the implementation of the
 ;; above customization variables.
-- 
2.35.1


  reply	other threads:[~2022-03-31 19:24 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-27 16:17 bug#54598: 27.2; Bad interraction between modus-theme and hs-minor-mode Pierre Téchoueyres
2022-03-29 13:06 ` Lars Ingebrigtsen
2022-03-29 21:05   ` Pierre Téchoueyres
2022-03-31 11:49     ` Lars Ingebrigtsen
2022-03-31 13:08       ` Protesilaos Stavrou
2022-03-31 19:24         ` Pierre Téchoueyres [this message]
2022-03-31 19:57           ` Protesilaos Stavrou
2022-03-31 20:19             ` Pierre Téchoueyres
2022-04-01  6:05             ` Eli Zaretskii
2022-04-02 17:53               ` Pierre Téchoueyres
2022-04-02 18:58                 ` Eli Zaretskii
2022-04-02 19:48                   ` Pierre Téchoueyres
2022-04-03  4:18                     ` Protesilaos Stavrou
2022-04-03  5:14                     ` Eli Zaretskii
2022-04-06 18:57                       ` Pierre Téchoueyres
2022-04-07  5:51                         ` Eli Zaretskii
2022-04-07  6:51                           ` Protesilaos Stavrou
2022-04-07  7:31                             ` Eli Zaretskii
2022-04-07  8:00                               ` Protesilaos Stavrou
2022-04-07  8:27                                 ` Eli Zaretskii
2022-04-07 12:44                                   ` Protesilaos Stavrou
2022-04-07 14:25                                     ` Eli Zaretskii

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=87fsmxc3tv.fsf@killashandra.ballybran.fr \
    --to=pierre.techoueyres@free.fr \
    --cc=54598@debbugs.gnu.org \
    --cc=info@protesilaos.com \
    --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.