ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Henning Hraban Ramm via ntg-context <ntg-context@ntg.nl>
To: Wolfgang Schuster via ntg-context <ntg-context@ntg.nl>
Cc: Henning Hraban Ramm <texml@fiee.net>
Subject: Re: [NTG-context] expansion of section title
Date: Tue, 27 Jun 2023 21:19:59 +0200	[thread overview]
Message-ID: <2242f630-f8b9-9695-4673-6f8815861377@fiee.net> (raw)
In-Reply-To: <4027191a-4cc1-843f-eb81-2d1ab5c332e4@gmail.com>

Am 27.06.23 um 21:01 schrieb Wolfgang Schuster via ntg-context:
> Henning Hraban Ramm via ntg-context schrieb am 27.06.2023 um 20:55:
>> \defineregister[todos]
>>
>> % add a "todos" index entry with the current section title
>> \define[1]\TODO{\todos{\structurevariable{title}}}
>>
>> \chapter{Something}
>> \TODO{This is still empty!}
>>
>> % at the end of the book
>> \chapter{work list}
>> \placetodos 
> 
> \define[1]\TODO{\expanded{\todos{\structurevariable{title}}}}

Thank you, that works.
I thought I tried that, but probably forgot the braces.

> What is the purpose of the argument for \TODO when you don't use it?

I simplified too much, the actual definition is (now):

\define[1]\TODO{\inouter{\tt\color[ColTodo]{TODO}}\expanded{\todos{\structurevariable{title}}}\color[ColTodo]{\bf 
#1}\autoinsertnextspace}

Hraban
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : https://contextgarden.net
___________________________________________________________________________________

      reply	other threads:[~2023-06-27 19:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-27 18:55 Henning Hraban Ramm via ntg-context
2023-06-27 19:01 ` Wolfgang Schuster via ntg-context
2023-06-27 19:19   ` Henning Hraban Ramm via ntg-context [this message]

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=2242f630-f8b9-9695-4673-6f8815861377@fiee.net \
    --to=ntg-context@ntg.nl \
    --cc=texml@fiee.net \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).