From: Matt Price <moptop99@gmail.com>
To: Org Mode <emacs-orgmode@gnu.org>
Subject: overlay showing computed value of macro?
Date: Thu, 22 Nov 2018 13:19:05 -0500 [thread overview]
Message-ID: <CAN_Dec-Oi2n72839bbHF4=Wh83AHwhaqPE1ivV+MW+ChkS7Zjw@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1115 bytes --]
I use macros in my course syllabi to automate creation of timestamps It
looksl ike this:
# see bottom of this email for the defn of ~get-ts~
#+MACRO: ts (eval (get-ts+7))
** Week {{{n}}} ({{{ts}}}): Time Scales in Rivers, Geology, and Human
Relationships
* Week {{{n}}} ({{{ts}}}): +READING WEEK: NO CLASS
** Week {{{n}}} ({{{ts}}}): Communities, States, and Water Governance
This makes it much easier for me to re-arrange headings while I'm planning
schedules. But it's a little hard to tell, for instance, if I have the
right number of class meetings, or if the University holidays are in the
right place, etc.
It would be nice for me to overlay the macro invocations with the values
that they will evaluate to on export. I guess I would have to figure out
when to trigger recalculation of the values (maybe not too often, say only
when the macro is first created, when it's edited or deleted/deformed, and
perhaps on structure editing.
I do not understand emacs overlays very well so this feels a little
daunting to me. Does anyone out there have ideas about how to do it
effectively?
Thanks as always!
[-- Attachment #2: Type: text/html, Size: 1478 bytes --]
next reply other threads:[~2018-11-22 18:26 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-22 18:19 Matt Price [this message]
2018-11-22 21:06 ` overlay showing computed value of macro? Matt Price
2018-11-22 22:37 ` Matt Price
2018-11-23 9:08 ` Matt Price
2018-11-23 9:32 ` Eric S Fraga
2018-11-23 12:49 ` Matt Price
2018-11-23 14:15 ` Eric S Fraga
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='CAN_Dec-Oi2n72839bbHF4=Wh83AHwhaqPE1ivV+MW+ChkS7Zjw@mail.gmail.com' \
--to=moptop99@gmail.com \
--cc=emacs-orgmode@gnu.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.