On 2020-07-03 1:07 pm, Urs Liska wrote:
But I'd rather do something like

  (markup (assq-ref enclosures enclosure) "CC")

markup is a macro, and macros appear to have unique rules of evaluation.

The following approach defers the macro expansion:

%%%%
\version "2.20.0"

#(define-markup-command
  (test layout props enclosure content)
  (boolean? markup?)
  (interpret-markup layout props
    (primitive-eval
      (list 'markup
            (if enclosure #:box #:circle)
            content))))

\markup {
  \test ##t box
  \test ##f circle
}
%%%%


-- Aaron Hill

Reply via email to