josephwright / csquotes

Con­text sen­si­tive quo­ta­tion fa­cil­i­ties
LaTeX Project Public License v1.3c
29 stars 18 forks source link

Ignore leading and trailing spaces #45

Closed dbosk closed 4 years ago

dbosk commented 4 years ago

Consider

I quote: \textcquote{some-source}{%
  this is a quote.
}

This code will produce a small space before the closing quote. It would be nice if the commands ignored trailing spaces. (And leading spaces too, so that the % at the opening bracket can be dropped. However, as footnotes have the same behaviour, this is less important; but, for footnotes that trailing space is invisible.)

I like the above coding style since it makes the code more readable. However, it requires adding those comments to give the expected result, which is sort of taking one step back again.

Tested on version 5.2c.

josephwright commented 4 years ago

In general, document commands do not strip spaces in their arguments in LaTeX. One can argue about this, but it's very common indeed (think basic stuff like \emph). At the same time, the API here has been stable for many years. As such, I can't really adjust it: sorry, but this is a WONTFIX.