6
votes
2answers
180 views

macro that deletes whatever symbol follows after the code and leave no space

How would the following macro X be defined in TeX? word in previous sentence?\macroX . Next sentence gives output identical to word in previous sentence? Next sentence The motivation: a period ...
4
votes
2answers
206 views

Making aliases for variables

I'm trying to figure out how best to define an alias. I have some moderately complicated variable names, such as $p^{i,j}_{t}$, and having to type them over and over again is a pain. More importantly, ...
10
votes
1answer
99 views

Hyphenate when using underscore as a letter

In many place in my current text I have to insert something like Name_of_model for instance. I found the last suggestion in this answer very helpful. However, I am facing a problem when it come to ...
7
votes
1answer
286 views

Automating processing of trailing punctuation (if any) for hyperlinks

This is a follow-up to Should Hyperlinks include trailing puctuation as part of the link text?, and this question is about automating the processing of the trailing character. I would like to be able ...
0
votes
1answer
124 views

Override quotation style [duplicate]

Is it possible to override the default quotation marks of ``notation''? As a czech user, I have to use \uv{} to have czech styled quotations, which doesn't write so well.
7
votes
3answers
191 views

How to define a new command for guillemets marks [duplicate]

Possible Duplicate: babel shorthand "| doesn’t work in macros I would like to define a new command for guillemets marks. I know how to obtain them in LaTeX and those I would like to ...
3
votes
1answer
488 views

Using “German” quotation marks inside \newcommand [duplicate]

Possible Duplicate: babel shorthand "| doesn’t work in macros I know there is a deeper non-understanding of LaTeX mechanics at work here, but I have no idea how to phrase my question ...
5
votes
1answer
3k views

Remove comma from moderncv's \cventry

This image shows the excerpt of a CV produced with the moderncv document class: Notice that after the bold text there is a comma. This seems to be produced automatically. How can I stop this?
45
votes
1answer
10k views

\dots versus \ldots - is there a difference?

Is there a difference between \dots and \ldots, the ellipsis? If yes: Which? When to use \dots and when to use \ldots? If no: Why are there both at all?
5
votes
1answer
147 views

Can I create one command for quoting?

I would like to get this result: I currently use this piece to get the result: \glqq{\textit{Analysis II}}\grqq{} Can I create a single command like the following to get the desired result? ...
8
votes
1answer
313 views

Acronyms without double dots using glossaries

I want to typeset my acronyms with abbreviating dots with, for instance, P.C.A. standing for principal component analysis and use macros for them. This question provides a trick to avoid double dots ...
21
votes
3answers
446 views

Comma-separated list environment

This question is somewhat of a follow up to an answer to a previous question (http://tex.stackexchange.com/a/11587/13522). I would like to create a list environment (similar to itemize and enumerate) ...
10
votes
1answer
517 views

Using \lccode / \lowercase{…} trick with double quote mark

My question was inspired by this question in which it is described how to map "#1" in maths mode to \text{#1}: \begingroup\lccode`~=`" \lowercase{\endgroup\def~}#1"{\text{#1}} \mathcode`"="8000 ...
5
votes
2answers
248 views

How can I avoid extra whitespace after using a macro before punctuation?

I have a document in which certain frequently-occurring entity names are replaced with macros, e.g.: \newcommand{\entity}{\emph{Name of Entity}} ... Lorem ipsum dolor sit \entity, consequat ...
1
vote
1answer
309 views

Write command so that commas appear properly [duplicate]

Possible Duplicate: \newcommand and spacing I want to write a command as a shortcut to insert text. \newcommand{\bl}{$blah blah$} When I write the command like this, "blah blah" runs ...
6
votes
1answer
125 views

Macro for handling placement of last quotation mark when setting quotes in text?

When including quotes in a text, there are some styles that need to be adhered to. One style is to always place the last quote where the actual quote ends, no matter the next character (e.g. ... and ...
10
votes
2answers
651 views

Replacing all dots in a document

I want to replace all dots in a LaTeX document with a call to a macro. Just doing a search and replace on '.' won't help as this will not replace the dots generated by LaTeX, e.g. in section numbers, ...
42
votes
6answers
10k views

Isn't there any other way of doing double quotes in LaTeX besides `` + ''?

The standard way of writing quotes and double quotes in LaTeX is with `` and '', but I find them quite ugly. Isn't there something similar to \emph{}, but for quotes? I mean something like ...
13
votes
4answers
331 views

How to prevent last period in captions from appearing in the list of figures?

Is there any simple way of removing the last character of an argument to a command (or environment)? I'm looking for a simple way to remove the punctuation mark from a caption when it appears in the ...
17
votes
1answer
782 views

Abbreviations and full stop--how to avoid double dots?

I have trouble with macros expanding to an abbreviated expression. Say I have \WHP which expands to "with high prob." (artificial example). I want to avoid the dot after the abbreviation colliding ...
15
votes
3answers
1k views

Detect beginning of a sentence in a macro for capitalization

Is it possible to make macros give different results at the beginning of a new sentence? Suppose that I want the macro "\secname" to write "Section" at the beginning of a new sentence, and "section" ...