Background
The text contains programming variable names such as report_city and SUBREPORT_FILE. All such variables are marked up with \texttt.
Problem
Some variable names are hyphenated:
SUBREPORT_-
FILE
I would prefer that the variables are not subjected to hyphenation.
Solution
A few ideas:
- Redefine
\textttto wrap an\mbox{...}command around the content. Best solution? - Use
\uchyph0. Did not work as expected. - Define all the words using
\hyphenation{...}. The command\hyphenation{SUBREPORT\_FILE}did not compile, and defining all the words would be a second last resort. - Edit the entire document and put all variables inside
\mbox{...}commands. I would consider this a last resort.
Question
How would you prevent the texts from being hyphenated?
Thank you!
\verb|...|or\lstinline|...|? – Jan 25 '11 at 09:33\texttt, rather than adding more evil red text. But that is a possibility. – Dave Jarvis Jan 25 '11 at 09:38hyphenat? If yes then comment it out – Jan 25 '11 at 09:52textttis not the problem, please see my post. – yannisl Jan 25 '11 at 11:54