On Thu, 24 May 2018 14:50:36 +0200, Hans Hagen wrote:
> On 5/24/2018 11:21 AM, Christoph Reller wrote:
>> On Wed, 23 May 2018 16:01:05 +0200, Hans Hagen wrote:
>>> On 5/23/2018 3:39 PM, Christoph Reller wrote:
What is the right way to define a
On Thu, 24 May 2018 11:24:34 +0200
Christoph Reller wrote:
> Thank you Hraban for pointing me to the wiki. I was aware of this page
> but it contains only the case of mandatory arguments in curly braces
> {} not in brackets [].
One must *not* confuse with the LaTeX
Hi,
> Arguments in brackets are always optional (if I don’t misunderstand),
> depending on your own logic (\if*argument, \ifempty etc.)
The original intent was for user-level commands to have square brackets
for arguments setting things up, and curly braces for arguments that
are actually
Am 2018-05-24 um 11:24 schrieb Christoph Reller :
> On Wed, 23 May 2018 17:54:39 +0200, Henning Hraban Ramm
> wrote:
What is the right way to define a command with both mandatory and
optional arguments, e.g:
>>> i'm not sure wht happens at
On 5/24/2018 11:21 AM, Christoph Reller wrote:
On Wed, 23 May 2018 16:01:05 +0200, Hans Hagen wrote:
On 5/23/2018 3:39 PM, Christoph Reller wrote:
Hi,
What is the right way to define a command with both mandatory and
optional arguments, e.g:
On Wed, 23 May 2018 17:54:39 +0200, Henning Hraban Ramm <te...@fiee.net> wrote:
> Date: Wed, 23 May 2018 17:54:39 +0200
> From: Henning Hraban Ramm <te...@fiee.net>
> To: mailing list for ConTeXt users <ntg-context@ntg.nl>
> Subject: Re: [NTG-context]
On Wed, 23 May 2018 16:01:05 +0200, Hans Hagen wrote:
>
> On 5/23/2018 3:39 PM, Christoph Reller wrote:
>> Hi,
>>
>> What is the right way to define a command with both mandatory and
>> optional arguments, e.g:
>>
>> \MyCommand[optional][mandatory]
>>
>> Consider the following
Am 2018-05-23 um 16:01 schrieb Hans Hagen :
> On 5/23/2018 3:39 PM, Christoph Reller wrote:
>> Hi,
>> What is the right way to define a command with both mandatory and
>> optional arguments, e.g:
> i'm not sure wht happens at your end but this is the best way:
Also, there’s
On 5/23/2018 3:39 PM, Christoph Reller wrote:
Hi,
What is the right way to define a command with both mandatory and
optional arguments, e.g:
\MyCommand[optional][mandatory]
Consider the following MWE:
\unexpanded\def\MyCommand[#1]{
\dosingleempty{\doMyCommand[#1]}}
Hi,
What is the right way to define a command with both mandatory and
optional arguments, e.g:
\MyCommand[optional][mandatory]
Consider the following MWE:
\unexpanded\def\MyCommand[#1]{
\dosingleempty{\doMyCommand[#1]}}
\def\doMyCommand[#1][#2]{
\doifsomething{#1}{number 1: #1\par}
10 matches
Mail list logo