Subject: mailing-list for TeXmacs Users
List archive
From : Sam Liddicott <address@hidden>- To: TeXmacs user list <address@hidden>
- Subject: Difficult macro parameters - removing the implicit document tag
- Date: Mon, 12 Feb 2024 15:03:33 +0000
TL;DR: I'm trying to work out how get rid of the implicit document tag if I press ENTER to insert a newline into a macro argument
This sample macro x can be used for the demo:
<assign|x|<\macro|a|b|c>
<arg|a> <arg|b><arg|c>
</macro>>
<arg|a> <arg|b><arg|c>
</macro>>
If I invoke it like this:
<x|aa|bb|cc>
I get the expected rendering:
aa bbcc
If I insert a new-line between the two a's, the source will invoke it like this:
<\x>
a
a
</x|bb|cc>
a
a
</x|bb|cc>
And I get (as expected, due to implicit concatenation of document blocks):
a bbcc
a
If I delete the new-line separating the a's my source is:
<\x>
aa
</x|bb|cc>
aa
</x|bb|cc>
Although it renders as:
aa bbcc
this is NOT the same as before the newline: <x|aa|bb|cc>
The difference is that the first argument now has label "document" but before it had label "string" (or as it may have been in real life, "concatenation" or "with" etc)
From within the editor, how do I get rid of the implicit document tag and reduce back to string?
Sam
- Difficult macro parameters - removing the implicit document tag, Sam Liddicott, 02/12/2024
- Re: Difficult macro parameters - removing the implicit document tag, Sam Liddicott, 02/12/2024
- Re: Difficult macro parameters - removing the implicit document tag, Giovanni Piredda, 02/12/2024
- Re: Difficult macro parameters - removing the implicit document tag, Sam Liddicott, 02/12/2024
- Re: Difficult macro parameters - removing the implicit document tag, Giovanni Piredda, 02/12/2024
- Re: Difficult macro parameters - removing the implicit document tag, Sam Liddicott, 02/12/2024
Archive powered by MHonArc 2.6.24.