-1

I use this code to add an extra space in the frqq command:

\let\oldfrqq\frqq
\renewcommand{\frqq}{\oldfrqq\xspace}

It compiles, but generates an error when it is used:

! Undefined control sequence
\frqq ->\oldfrqq \xspace

Is oldfrqq undefined? How should I make it work?

Gerard
  • 373
  • Is \frqq defined at all? If I use \providecommand{\frqq}{foo} there's no error. –  Nov 27 '15 at 23:22
  • Sure. \frq, \flq, \frqq, \flqq are the Swiss guillemots and they are displayed. – Gerard Nov 27 '15 at 23:24
  • Which package do you use? I've never seen those commands so far! –  Nov 27 '15 at 23:24
  • 2
    Please provide a minimal working example (MWE) that replicates the problem. – Werner Nov 27 '15 at 23:26
  • The answer of D. Carlisle is correct, it works now, thank you. – Gerard Nov 27 '15 at 23:29
  • @ChristianHupfer I believe those guillemots are available because of the babel package: \usepackage[ngerman]{babel} option that I use, but I am not sure. – Gerard Nov 27 '15 at 23:30
  • @Gerard: I am German and use babel that way, but I've never used such Swiss guillemots. It would have been nice to see the code you have, I could have tracked the error as well, but I've included \usepackage{xspace} already and searched the error at the wrong place. Please post full examples not just fragments! (By the way: I am not the downvoter ;-)) –  Nov 27 '15 at 23:32
  • you can also make your code more readable using \usepackage{etoolbox} ... \apptocmd{\frqq}{\xspace}{}{} – musicman Nov 27 '15 at 23:34
  • Also see http://tex.stackexchange.com/questions/86565/drawbacks-of-xspace/86620#86620 – David Carlisle Nov 27 '15 at 23:44
  • @DavidCarlisle In my case simply \space works as well. – Gerard Nov 27 '15 at 23:51
  • @Werner To be honest the MWE requirement often feels like just too much effort in relation to the problem ..? – Gerard Nov 27 '15 at 23:53
  • 1
    @Gerard: This is a poor question, as there is no context given. Specifically, the formatting of the error message is ambiguous: The error could have been with an non-existent \oldfrqq or \xspace. Also, the question title doesn't have anything to do with the question once you know the answer. Finally, this has nothing to do with [tag:macros], but more with the vague [tag:errors] tag. – Werner Nov 27 '15 at 23:56
  • 1
    Also note that you are asking for help here... when the community requests something that would clarify the problem, spoon-feeding is definitely a good idea. Answers here seem free-of-charge, but it has to be well-formulated. – Werner Nov 27 '15 at 23:57

1 Answers1

2

The error is telling you that \xspace is undefined, presumably because you have not loaded the package of that name

David Carlisle
  • 757,742