Tell me more ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Titles of articles I'm about to cite contain uppercase letters and when using BibTeX it converts them in lowercase ones. This happens only in title and only first letter conserves it's case. For example, when I cite article about HF, reader won't know if it is about Hafnium or fluorine acid.

I know that I can fix it manually in .bbl file but I'd like to avoid it, or fix it automatically.

Thanks for any suggestions.

share|improve this question
@Allan: Thanks for corrections. – Crowley Feb 22 '11 at 20:47

5 Answers

up vote 17 down vote accepted

This is not a bug; it's a feature. BibTeX converts all characters in the title to lowercase, with the exception of the first character. If you want to override this, wrap the character(s) in curly brackets, e.g.,

title = "Pascal, {C}, {Java}: were they all conceived in {ETH}?"

share|improve this answer
5  
Well, bibtex does not always do this. Certain .bst files can choose to convert to ALL UPPERCASE, or to leave the capitalisation exactly as it was entered in the .bib file. – Lev Bishop Feb 10 '11 at 19:19
thanks for advice. It works as I need. – Crowley Feb 10 '11 at 20:37
Incidentally, you should nearly always capitalise the subtitle, and I recommend capitalising all significant words, to allow for bibliography styles that want this. Then you get: title = "Pascal, {C}, {Java}: {Were} they all Conceived in {ETH}?" – Charles Stewart Feb 11 '11 at 9:38
Read the instractions if everyting else fails. – Igor Kotelnikov Mar 1 '11 at 15:28

You could protect your titles by using additional braces: title = "{About HF}".

share|improve this answer
I would only put the braces around the HF. – Lev Bishop Feb 10 '11 at 19:15
3  
@Lev: In that case just around HF is ok. I would just not put braces around letters or parts of words, to preserve the kerning, so perhaps around whole words. It's not necessary to do it for a complete title. – Stefan Kottwitz Feb 10 '11 at 19:19
3  
But if you put braces around whole words you lose hyphenation which seems like a worse thing to lose than kerning. – Alan Munn Feb 10 '11 at 19:32
2  
@Alan: Braces don't need to prevent hyphenation. I verified it: also within a bibliography, words within braces in a BiBTeX's title were hyphenated. – Stefan Kottwitz Feb 10 '11 at 20:03
Thanks for answer and this discussion. – Crowley Feb 10 '11 at 20:49

The canonical reference for this kind of thing is Nicolas Markey's Tame the BeaST. For your example of HF, enter it as {HF} to keep the capitalisation.

Generally, it's better to only put the braces around the minimum part that needs fixed capitalization. Some publications want all UPPER CASE, some want Title Case, some want Sentence case. So for most flexibility an article about Hafnium and hydrofluoric acid should be entered as title = {The effects of {HF} on {Hf}}

share|improve this answer
@Crowley: btw. texdoc ttb may open the mentioned document for you, it does so on my TeX Live 2009 system. – Stefan Kottwitz Feb 10 '11 at 19:15

If you do want to change all the bibliography entries then you can modify your style file. Copy it to mybst.bst and then edit the file to modify the function format.title to:

FUNCTION {format.title}
{ 
% title empty$
%    { "" }
%    { title "t" change.case$ }
%  if$
title
}

Then it didn't change the uppercase letters. Save the new file into your documents directory and try it. If it works, then you can move it into the local texmf tree.

share|improve this answer

As others have noted, lowercase titles is a feature an not a bug, the idea being that the bibliography style is responsible for capitalizing or not title words according to the particular style it implements. However, there are obviously places where this is not what you want, as you have found: acronyms, proper names etc. in titles.

The general rule for solving this problem is to enclose the elements that must always be capitalized in {...}. However, as a rule of thumb, you should always enclose the smallest possible part. For example:

title = "A comparison of {P}ascal, {A}da, and {BASIC}"
title = "A biography of {E. M.} {F}orster"

not

title = "A comparison of {Pascal}, {Ada} and {BASIC}"
title = "A biography of {E. M.} {Forster}"

The reason for not surrounding the whole word in {...} is that the braces will also prevent hyphenation of that word. So it's best just to surround the smallest stretch of a word that needs to remain capiatalized. For proper names, this will generally be the first letter; for acronyms or chemical formulas it will be the whole thing.

share|improve this answer
5  
I could give an example where hyphenation works within braces. And compare {T}ext to {Text} - the kerning between T and e. – Stefan Kottwitz Feb 10 '11 at 20:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.