help-texinfo
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [help-texinfo] HTML Span


From: Mike Gran
Subject: Re: [help-texinfo] HTML Span
Date: Thu, 11 Apr 2013 07:15:04 -0700 (PDT)

>> @span{classname, text}
>> 
>> For HTML output only, it would expand to 
>> 
>> <span class="classname">text</span>
>> 
>What about using a user defined macro?
>
>Something like (untested)
>
>@ifhtml
>@macro span{classname, text}
>@inlinefmt{html, <span class="\classname\">\text\<span>}
>@end macro
>@end ifhtml
>
>@ifnothtml
>@macro span{classname, text}
>\text\
>@end macro
>@end ifnothtml


Nice.  I managed to get that to work.  There
seems to already be an @span in the DVI format, and
I had to go with `inlineraw' to not escape the html.
So I ended up with.



@ifhtml
@macro css{classname, text}
@inlineraw{html, <span class="\classname\">\text\<span>}
@end macro
@end ifhtml

@ifnothtml
@macro css{classname, text}
\text\
@end macro
@end ifnothtml


Thanks,

Mike




reply via email to

[Prev in Thread] Current Thread [Next in Thread]