LATEX-L Archives

Mailing list for the LaTeX3 project


Options: Use Classic View

Use Proportional Font
Show Text Part by Default
Condense Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Content-Type: text/plain; charset=ISO-8859-1
Date: Wed, 11 May 2011 14:49:00 +0100
Reply-To: Mailing list for the LaTeX3 project <[log in to unmask]>
MIME-Version: 1.0
Message-ID: <[log in to unmask]>
Content-Transfer-Encoding: 7bit
Sender: Mailing list for the LaTeX3 project <[log in to unmask]>
From: Joseph Wright <[log in to unmask]>
Parts/Attachments: text/plain (37 lines)
Hello all,

You may remember that a while ago we discussed space skipping for
optional arguments with xparse, for example

   \foo{mandatory}[optional] other text
   \foo{mandatory} [optional] other text
   \foo{mandatory}  other text

At the time, the feeling was that we should not skip spaces in these
cases, so only the first of my examples is parsed as containing an
optional argument.

I've been looking at this again, as I'm not sure this is the best
approach. When the only argument is optional

  \foo [bar]
  \foo  text

TeX will always skip spaces and so things are not consistent. In the
same way, mandatory arguments are always grabbed

  \foo {bar}

So looking again at this I think we should 'follow TeX', and be
consistent in skipping spaces in all cases. I don't like the fact that
at present there is a somewhat convoluted explanation of the behaviour
in the xparse documentation: this tends to show up when something is not
really correct! (At the same time, the implementation would be slightly
easier to follow if this change was made.)

Does this seem reasonable?
Joseph Wright