is it possible to set the lesser and greater than symbol while in text mode?
I have a text in which I have to set a lot of <tags> and now they all
look like $<$this$>$. That's okay, as long as I don't want any extra
formatting on the tag. If I want a bold one for example, I need to
seperately make the parts in math mode bold from the part in text mode...
greetings,
Bart
There are \textless and \textgreater. imho I, for one, would have made
a macro such as \newcommand{\Tag}[1]{\textless {#1}\texgreater} or
something to that effect.
> greetings,
hih
--
Le TeXnicien de surface
> is it possible to set the lesser and greater than symbol while in text mode?
\textgreater and the like?
--
Maurizio Loreti http://www.pd.infn.it/~loreti/mlo.html
Dept. of Physics, Univ. of Padova, Italy ROT13: ybe...@cq.vasa.vg
> is it possible to set the lesser and greater than symbol while in
> text mode?
\documentclass{article}
\usepackage[T1]{fontenc}
\begin{document}
< >
\end{document}
--
Sender address blackholed, do not reply by email!
You can still reach me at plehman at gmx dot net.
You mean probably \usepackage[latin1]{inputenc}
(instead of \usepackage[T1]{fontenc} which has nothing to do with
it).
Gruß,
Jörg
Try the example with and without \usepackage[T1]{fontenc}.
Try the example with and without \usepackage[latin1]{inputenc}.
When do you get < > in the document?
--
Ulrike Fischer
e-mail: zusätzlich meinen Vornamen vor dem @ einfügen.
e-mail: add my first name between the news and the @.
> * Philipp Lehman wrote:
>> Bart Van Loon wrote:
>>
>>> is it possible to set the lesser and greater than symbol while in
>>> text mode?
>>
>> \documentclass{article}
>> \usepackage[T1]{fontenc}
>> \begin{document}
>>< >
>> \end{document}
>
> You mean probably \usepackage[latin1]{inputenc}
Nope. This is not an input encoding problem. "<" and ">" are plain
Ascii.
> (instead of \usepackage[T1]{fontenc} which has nothing to do with
> it).
Did you even bother trying?
Stictly speaking, it's not an output encoding problem either. It's one
of CM's weird traits hence switching to EC will sidestep the issue.
Jörg, you are wrong. Choosing the T1 encoding has the side effect
of selecting the EC fonts, or other Cork-encoded, which have < and >
in the normal (ASCII) position.
The "correct" solution, however, is to use \textless and \textgreater
which work in any encoding.
Ciao
Enrico
No, sorry.
> Stictly speaking, it's not an output encoding problem either. It's one
> of CM's weird traits hence switching to EC will sidestep the issue.
It is indeed weird, but switching to EC triggers additional side
effects. So the proper solution is \textless and \textgreater.
Cheers,
Jörg
Le TeXnicien de surface wrote:
> Bart Van Loon wrote / a écrit :
>>is it possible to set the lesser and greater than symbol while in
>>text mode?
>>
>>I have a text in which I have to set a lot of <tags> and now they
>>all look like $<$this$>$. That's okay, as long as I don't want any
>>extra formatting on the tag. If I want a bold one for example, I
>>need to seperately make the parts in math mode bold from the part in
>>text mode...
> There are \textless and \textgreater. imho I, for one, would have made
> a macro such as \newcommand{\Tag}[1]{\textless {#1}\texgreater} or
> something to that effect.
Thanks a lot! I created the following commands now:
\newcommand{\opentag}[1]{\textless\mbox{#1}\textgreater}
\newcommand{\closetag}[1]{\textless\mbox{/#1}\textgreater}
\newcommand{\singletag}[1]{\textless\mbox{#1 /}\textgreater}
and they work just perfect for me.
greetings,
Bart
yeah. you get your hyphenation right.
outline fonts for cork encoding should not be a problem any more, with
current tex distributions.
> So the proper solution is \textless and \textgreater.
apart from the fact that they take a heck of a lot more typing.
--
Robin (http://www.tex.ac.uk/faq) Fairbairns, Cambridge
What is fix-cm intended for?
Hint:
% The appearance of the T1 and TS1 encoded CM fonts (aka `EC') is
% made as similar as possible to the traditional (OT1 encoded) ones.
> outline fonts for cork encoding should not be a problem any more, with
> current tex distributions.
Another example of causing side-effects.
>> So the proper solution is \textless and \textgreater.
>
> apart from the fact that they take a heck of a lot more typing.
Robin, you should learn more about capable text editors.
Cheers,
Jörg
This looks like you are typesetting html or xml source text. If so,
using a package like `listings' could be another option.
Cheers,
Jörg
by default T1/cmr/... etc. appear using very closely spaced optically
sized fonts. fix-cm causes latex to use a smaller number of optical
sizes for the ec fonts.
i don't use ec fonts for type 1 encoding, precisely because of the
embarrassing plethora of fonts: i use latin modern, which uses optical
sizes exactly the same as knuth's.
doesn't seem to me to have anything to do with hyphenation, which
doesn't work with standard tex, ot1 fonts, and most european
languages. (exception: english, which has a few diareses and a few
imported accents, only.)
>> outline fonts for cork encoding should not be a problem any more, with
>> current tex distributions.
>
>Another example of causing side-effects.
but not a serious one, any more.
>>> So the proper solution is \textless and \textgreater.
>>
>> apart from the fact that they take a heck of a lot more typing.
>
>Robin, you should learn more about capable text editors.
ho ho very droll.
you know, if i used word, i wouldn't show my arthritic fingers so much
-- it does the capitalisation at the start of sentences for me.
so it _does_ have its uses.
This is exactly the point. If someone likes to get the hyphenation
right, why you believe he likes to use different looking fonts?
This is what I call (unwanted) side-effects.
>>>> So the proper solution is \textless and \textgreater.
>>>
>>> apart from the fact that they take a heck of a lot more typing.
>>
>>Robin, you should learn more about capable text editors.
>
> ho ho very droll.
If you map Alt+, to \textless and Alt+. to \textgreater, you have
exactly the same amount of typing, and this is only the simplest
solution. Hence the argument about having more typing isn't
convincing.
Cheers,
Jörg
so don't use fonts that have a different look. easy.
i've said this three times now. you plainly know better than i do,
since i only use the things.
plainly no point in carrying on the exchange.