[Top][All Lists]

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

Re: Document/Example how to create "standalone" markup commands

From: Aaron Hill
Subject: Re: Document/Example how to create "standalone" markup commands
Date: Thu, 07 Jun 2018 10:16:31 -0700
User-agent: Roundcube Webmail/1.3.6

On 2018-06-07 07:58, David Kastrup wrote:
Aaron Hill <address@hidden> writes:

On 2018-06-07 06:34, Aaron Hill wrote:
Hi David,

Correct me if I am wrong, but the second definition is ***not***
usable as a
function.  That is, it cannot accept a parameter for customizing the
markup.  Unless `\etc` is something magical that is undocumented, the
resulting `\doubleBox` would have to be a complete idea.

(See ***correction*** above.)

I hate email sometimes... No ability to edit when you make a dumb
typing mistake.  Sorry.

I don't understand what you consider "not a function" though.  It is a
function with constrained form, but a function nevertheless since it
takes a text/markup parameter.

There are likely many pedants who would say that functions strictly have non-zero arity, but that is neither here nor there.

The snippet you mentioned does not work as-is on 2.19.81, so I was curious if there was something new going on with how to define functions. As I originally suspected `\etc` was nothing more than a placeholder for other, actual markup, your suggested definition of `\doubleBox` ultimately becomes a fixed, parameter-less construct. That is, you could not say `c\doubleBox foo`, which is what Urs was trying to achieve. Is there something potentially unsound about using define-event-function to that end?

-- Aaron Hill

reply via email to

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