emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/modus-vivendi-theme 5107407 059/110: Internal: convert


From: Stefan Monnier
Subject: [elpa] externals/modus-vivendi-theme 5107407 059/110: Internal: convert two defmacro into defun
Date: Wed, 29 Apr 2020 21:40:07 -0400 (EDT)

branch: externals/modus-vivendi-theme
commit 5107407bcea2028d169df2ac152ff8909aa6c6de
Author: Protesilaos Stavrou <address@hidden>
Commit: Protesilaos Stavrou <address@hidden>

    Internal: convert two defmacro into defun
    
    These should never have been implemented as a `defmacro' even though
    things worked from an end-user perspective.
---
 modus-operandi-theme.el | 14 +++++++-------
 modus-vivendi-theme.el  | 14 +++++++-------
 2 files changed, 14 insertions(+), 14 deletions(-)

diff --git a/modus-operandi-theme.el b/modus-operandi-theme.el
index bca466d..ed79066 100644
--- a/modus-operandi-theme.el
+++ b/modus-operandi-theme.el
@@ -412,23 +412,23 @@ between foreground and background is >= 7:1)."
   "Use fewer/dim backgrounds in `diff-mode', `ediff',`magit'."
   :type 'boolean)
 
-(defmacro modus-operandi-theme-diffs (subtle-bg subtle-fg intense-bg 
intense-fg)
+(defun modus-operandi-theme-diffs (subtle-bg subtle-fg intense-bg intense-fg)
   "Colour combinations for `modus-operandi-theme-subtle-diffs'.
 
 SUBTLE-BG should be similar or the same as the main background
 SUBTLE-FG should be an appropriate accent value
 INTENSE-BG should be one of the dedicated backgrounds for diffs
 INTENSE-FG should be one of the dedicated foregrounds for diffs"
-  (list 'if 'modus-operandi-theme-subtle-diffs
-        (list 'list :background subtle-bg :foreground subtle-fg)
-        (list 'list :background intense-bg :foreground intense-fg)))
+  (if modus-operandi-theme-subtle-diffs
+      (list :background subtle-bg :foreground subtle-fg)
+    (list :background intense-bg :foreground intense-fg)))
 
-(defmacro modus-operandi-theme-scale (amount)
+(defun modus-operandi-theme-scale (amount)
   "Scale heading by AMOUNT.
 
 AMOUNT is a customisation option."
-  (list 'when 'modus-operandi-theme-scale-headings
-        (list 'list :height amount)))
+  (when modus-operandi-theme-scale-headings
+        (list :height amount)))
 
 ;; Define colour palette.  Each colour must have a >= 7:1 contrast
 ;; ratio relative to the foreground/background colour it is rendered
diff --git a/modus-vivendi-theme.el b/modus-vivendi-theme.el
index 6dd45c6..5a4d7f1 100644
--- a/modus-vivendi-theme.el
+++ b/modus-vivendi-theme.el
@@ -412,23 +412,23 @@ between foreground and background is >= 7:1)."
   "Use fewer/dim backgrounds in `diff-mode', `ediff',`magit'."
   :type 'boolean)
 
-(defmacro modus-vivendi-theme-diffs (subtle-bg subtle-fg intense-bg intense-fg)
+(defun modus-vivendi-theme-diffs (subtle-bg subtle-fg intense-bg intense-fg)
   "Colour combinations for `modus-vivendi-theme-subtle-diffs'.
 
 SUBTLE-BG should be similar or the same as the main background
 SUBTLE-FG should be an appropriate accent value
 INTENSE-BG should be one of the dedicated backgrounds for diffs
 INTENSE-FG should be one of the dedicated foregrounds for diffs"
-  (list 'if 'modus-vivendi-theme-subtle-diffs
-        (list 'list :background subtle-bg :foreground subtle-fg)
-        (list 'list :background intense-bg :foreground intense-fg)))
+  (if modus-vivendi-theme-subtle-diffs
+      (list :background subtle-bg :foreground subtle-fg)
+    (list :background intense-bg :foreground intense-fg)))
 
-(defmacro modus-vivendi-theme-scale (amount)
+(defun modus-vivendi-theme-scale (amount)
   "Scale heading by AMOUNT.
 
 AMOUNT is a customisation option."
-  (list 'when 'modus-vivendi-theme-scale-headings
-        (list 'list :height amount)))
+  (when modus-vivendi-theme-scale-headings
+    (list :height amount)))
 
 ;; Define colour palette.  Each colour must have a >= 7:1 contrast
 ;; ratio relative to the foreground/background colour it is rendered



reply via email to

[Prev in Thread] Current Thread [Next in Thread]