latex - Spacing issues with xspace -


let's macro \newcommand{\k}{king\xspace}. spacings in "... said \k." fine. do if want no spacing in middle of \k\k.? want "kingking." not "king king."

is there way this?

the whole point of \xspace add space between words , not add space before punctuation. so, if don't want spaces between 2 uses of macro don't use \xspace. but, of course require you use {} @ end:

\documentclass{article} \newcommand{\k}{king}%  \begin{document} @ end of sentence \k.\par in between \k\k{} want 1 long word. \end{document} 

Comments

Popular posts from this blog

Javascript line number mapping -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -