Tagged Questions

{typewriter} is the term used for a "monospaced" font, that is, a font in which all characters have the same width.

learn more… | top users | synonyms (2)

3
votes
1answer
198 views

Installed Luximono is not working

I am using MacTex-2011 on a mac 10.7. Recently, I have installed luximono using getnonfreefonts. Everything went ok, but when I was compiling the document (pdfLaTeX) with the packages: ...
15
votes
2answers
625 views

How to center a typewriter (ttfamily) '+'

I would like to draw a circular TikZ node with + in its center, but font=\ttfamily moves it up. Why? How to solve it? \documentclass[border=3mm]{standalone} \usepackage{tikz} \begin{document} ...
10
votes
3answers
834 views

How can I ensure all teletype/monospaced text is in a certain color?

I'm trying to include some monospaced text, and I'd like it to be in a different color than the normal text. There will be several (read: hundreds) of instances of monospaced text, and I want it all ...
1
vote
1answer
324 views

table with monospaced and nonbreaking spaces

I have a xtable generated in R/Sweave that I would like displayed in portrait mode in a pdf. The spaces in the spacedSeq should properly align the sequences. How can I force this to be in a monospace ...
8
votes
2answers
1k views

Scaling fonts document-wide

I'm looking to use lcmtt mentioned here as my default typewriter font, but the scaling is way out of proportion with the rest of the text. I've used the following commands to enable the font: ...
22
votes
4answers
12k views

Using \ttfamily with \bfseries (or how to enable bold in fixed-width font)

I'm using listings package, and I've added basicstyle=\ttfamily\footnotesize. However, when I do that, the keywords from the embedded source-code are not bold anymore. I figured that \ttfamily ...
18
votes
3answers
13k views

Shrinking monospace style for listings package

I am working on a thesis and putting together a "pretty" listing. I'm looking at setting up a small font style for a code view. What I have here is: \usepackage{listings} \lstset{language=C, ...
4
votes
1answer
2k views

Put a leading space to a paragraph using texttt

This line ~~Some~~thing produces two leading spaces before the word 'Some' and the spaces before 'thing'. However, \texttt{~~Some~~thing} does not produces the first two spaces (but produces ...
4
votes
1answer
3k views

Using \verbatiminput on filenames with underscores

I'm trying to include some source files using \verbatiminput{}. Some of these filenames have underscores in them. This works fine by default. But if I try to include the underscore package so that I ...
5
votes
3answers
11k views

How to change the font of a LaTeX table to typewriter font?

I want to create a table in LaTeX, and this table needs to be in typewriter font. I have found Typesetting Tables with LaTeX, but I don't understand how to use it. How could I do this?
12
votes
4answers
2k views

Minion Pro and Monospace Font

This is more a typography question than a TeX one, but can anyone recommend me a good monospaced font that blends well with Minion Pro?
5
votes
2answers
614 views

How to use condensed typewriter with latin modern and doc

I'm documenting a class with (ltx)doc. The macro names are quite long so I get a lot of overfull hboxes. AFAIK latin modern has an additional typewriter font which is condensed. How do I switch the ...
6
votes
2answers
2k views

How do I change the \mathtt font with mathspec?

I have a document where the main font is Gotham Narrow Book but the numbers are set in Gotham Narrow Light, and this is set with commands provided by the mathspec package. I'd like to typeset a table ...
7
votes
1answer
2k views

Suggestions for typewriter font to match Concrete and Euler

I'm having fun using a combination of Concrete and Euler in some of my documents. I wonder if anyone has a suggestion about a matching typewriter font? I've been trying Inconsolata (scaled to .97) ...
5
votes
3answers
4k views

Which sans serif and monospace fonts suit Century Schoolbook?

I find the Century Schoolbook family very legible for online documentation. However, I am unsure what sans serif (for typesetting, e.g., LaTeX package names) and monospace (for typesetting code) ...
4
votes
1answer
1k views

Correctly typesetting words surrounded by double underscores?

Forgive me if the answer to this is obvious, I've just begun working with LaTex and I've had no luck with Google. I'm working on learning LaTeX, and as part of my practice I'm rewriting a guide on ...
5
votes
3answers
488 views

Display “.\integrate blah” in monospaced font (like \texttt and \verb)

I'm trying to display the following: .\integrate blah in a monospaced font. For everything else I've wanted to put in a monospace font, \texttt or \verb has worked fine, but it doesn't with this. ...
8
votes
2answers
4k views

Bold Typewriter Type fonts

I found out that there are cmbtt10 and cmttb10 fonts available. Unfortunately they are not used until I activate them with the \font macro, so just searching for those fonts is not possible. The ...
5
votes
1answer
798 views

Using \texttt with polyglossia Hebrew

\texttt does not work as expected when using it with the polyglossia package, in a segment in the Hebrew language, even when the actual text to be set is Latin. I tried reading fontspec documentation, ...
15
votes
2answers
5k views

\texttt overfull hbox problem

I asked a question earlier about \verb and overfull hbox : In-line \verb -- overfull hbox problem And regarding the solution there, changed many of my \verbs to \texttt{}s. I have come up with a new ...
5
votes
3answers
924 views

Prevent hyphenation in \texttt words

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: ...
7
votes
1answer
1k views

Double quotes with monospaced font and LuaLaTeX

I am trying to set the following minimal document: \documentclass[a4paper,11pt]{article} \usepackage{fontspec} \setmonofont{Inconsolata} \begin{document} \begin{verbatim} <!DOCTYPE HTML PUBLIC ...
16
votes
3answers
2k views

How can I create a full-size circumflex in typewriter font?

I have some C source code and would like to show the circumflex or caret (^) in the way it is typically shown in source code -- as a full-size character. The source code will be appearing in ...
54
votes
2answers
46k views

When should one use \verb and when \texttt

Sometimes people here use \verb!A SHORT COMMAND! and sometimes \textt{A SHORT COMMAND}. I'm unsure when to use which. Are there any guidelines or arguments for \verbatim vs. \texttt?
14
votes
6answers
8k views

Alternative monospace fonts

My document uses the txfonts package, which provides Times Roman, Helvetica and what appears to be a facsimile of Courier. However, I dislike the monospace font and find it to be particularly ugly. I ...
11
votes
3answers
790 views

unicode \begin{verbatim} with cmtt?

A lot of leading-edge programming languages (like Coq and Agda) allow nearly unrestricted use of unicode symbols in program text, so you can have math characters like $\otimes$ (Unicode U+2A02) as ...
9
votes
3answers
2k views

A monospace or typewriter font with matching math support

This might sound odd but I really like the old typewriter books from the pre-TeX era (the type of books that inspired Knuth to make TeX!). I don't know the exact reason, maybe its because I am very ...
5
votes
3answers
2k views

parameter passing to \verb|| environment

I happen to write the following code over and over again. {\color{blue}\verb|>|} {\footnotesize\verb|HI|} So, I came up with the following code to make it a command. \newcommand{\result}[2]{% ...
30
votes
3answers
15k views

How to get long \texttt sections to break

I often format path names with \texttt which can be very long. Usually Tex will not break this text. The line will just create a hbox overflow. It looks like this: ................ ...C:\documents ...