[prev in list] [next in list] [prev in thread] [next in thread] 

List:       lilypond-devel
Subject:    Re: Using \\ in a texinfo macro argument generates \ in html, but \\ in pdf
From:       Reinhold Kainhofer <reinhold () kainhofer ! com>
Date:       2008-03-31 20:00:06
Message-ID: 200803312200.07325.reinhold () kainhofer ! com
[Download RAW message or body]

Am Montag, 31. März 2008 schrieb Karl Berry:
> Reinhold Kainhofer wrote:
>  >   Nope, does not work. The backslashes are still doubled by texi2pdf
>  >   (i.e. not understood as one backslash).
>
> How about
> @set backslash \
> and then using @value{backslash} in the actual argument?
>
> Or
>
> @macro backslash
> \\
> @end macro
> and then @backslash{}?
>
> Do either of those work?

Yes, thanks, both of them work fine (the second one is easier to read, 
though).

Graham (that's one of our Lilypond documentation team), which one is better 
for lilypond?

> Or we could define a new command @backslash{} similar to @comma{}.

@backslash seems already defined and gives a TeX error when used (somehow it 
seems to be only allowed in math mode or so):

./escaping_slashes_in_macros_answer.texi:19: Missing $ inserted.
<inserted text>
                $
<to be read again>
                   @delimiter
@backslash ->@delimiter
                        "26E30F


Anyway, the @bs macro or the @set{bs} approach, both solve our problem.

Cheers,
Reinhold

-- 
------------------------------------------------------------------
Reinhold Kainhofer, Vienna University of Technology, Austria
email: reinhold@kainhofer.com, http://reinhold.kainhofer.com/
 * Financial and Actuarial Mathematics, TU Wien, http://www.fam.tuwien.ac.at/
 * K Desktop Environment, http://www.kde.org, KOrganizer maintainer
 * Chorvereinigung "Jung-Wien", http://www.jung-wien.at/



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic