Quote:
Originally Posted by theducks
With spaces (the first). , but regular if in text as NBS would make crummy justification on many devices. Trade-off (I reallyhate huge gaps in text) 
|
Personally, in ebooks, I would avoid using these non-breaking spaces. They're going to cause more headaches than they're worth.
But for Print, see some of the notes below.
Side Note: In ebooks, the only non-breaking spaces I use is in 3- and 4+-dot ellipses.
Quote:
Originally Posted by phossler
Q1: Are there rules or is it personal choice that F. A. Hayek -> F.A. Hayek is correct? I typically use F. A. Hayek with spaces
|
The most important thing is consistency throughout.
But this all comes down to preferences (Style Guides / House Styles).
For example, the publishers I do a lot of work for prefer the "F.M. Last" form.
If I run across a book where 90% are one way, and 10% are the other way, better to choose one and make it consistent (and I personally lean towards no space).
If the book is 100% correct though, then I don't mess with it.

(This is very rare though, these types of inconsistencies sneak in all the time, just like mismatching hyphenation.)
- - - - -
Pass #1: Take care of the "easy".
Search: (\b[A-Z]\.) ([A-Z]\.) ([A-Z])
Replace: \1\2 \3
This catches "F. M. Last" -> "F.M. Last".
Pass #2: Take care of the "hard" + all the rest.
Search: (\b[A-Z]\.) ([A-Z])
Replace: \1 \2
This will catch "First M. Last" -> "First M. Last".
Exceptions
Depending on how the rest of the book deals with acronyms, there may be very few errors, or a ton. Here are a few examples you may run across:
I ran this on a ~2 million word journal.
Pass #1:
Many styles shorten journal/newspaper names:
Quote:
I. Maurice Wormser, “The True Conception of Unilateral Contracts”, <i>Selected Readings</i>, pp. 307, 308–309. Compare Frederick Pollock, review of Clarence D. Ashley, <i>The Law of Contracts</i>, 28 <i>L. Q. Rev.</i> 100.
|
It would be wrong to merge this into "L.Q. Rev".
Pass #2:
U.S. (1 of these is a sentence-ender):
Quote:
This distinction was originally continued in America, as evidenced by the placement of the bankruptcy clause in the commerce section of the U.S. Constitution.
“A single, ultimate arbiter of conflicts (e.g. the U.S. Supreme Court) is considered non-essential.”
The book was a landmark for the development of sociology in the U.S. Spencer emphasized a science of sociology which would teach men to think of social causation in a scientific way.
|
(If you're writing a book, don't end the sentence on an acronym like that... It's very poor form. Rewrite sentence instead. [Or go with the superior "US"!])
B.C. (sentence-ender?):
Quote:
[...] the jurist-king of Babylonia who reigned in the 18th century B.C. Hammurabi provided for liquidation of the assets of the insolvent debtor and their distribution among creditors [...]
|
C.I.A. + F.B.I. (sentence-ender):
Quote:
[...] as is also the case with para-military organizations like the C.I.A. and F.B.I. This often surreptitious attrition of popular control runs counter [...]
|
As you can see, this is where Natural Language Processing would cut down on the false hits. You need something smarter than plain ol' Regex IF you want to do mass search/replaces.
Side Note: LanguageTool detects some of this stuff in the backend while parsing sentences so it can recommend proper capitalization, but doesn't (yet) recommend non-breaking spaces like Antidote:
https://languagetool.org/
And tools like NTLK (Natural Language Toolkit) may detect even more of these cases:
https://www.nltk.org/index.html
Quote:
Originally Posted by phossler
Q2: I'd think that CA and NYC would be the correct acronym?
|
Depends on the source. Again, consistency within a document/book matters... but, you could have:
Book titles:
Quote:
Duncan Campbell, <i>War Plan UK: The Truth About Civil Defence in Britain</i> (London: Burnett, 1982).
|
Publisher locations:
Quote:
Bruno Leoni, <i>Freedom and the Law</i> (Princeton, N. J.: D. Van Nostrand, 1961)
|
Quite often, when discussing voting, the party+state is combined:
Not smart to just Replace All or add/remove periods haphazardly. :P
Quote:
Originally Posted by phossler
Q3: Related to Q1. I'm on the fence about A.M. vs A. M.. I think I prefer the no-space version, but are there any rules?
|
There are ~5 or 6 different styles for am/pm. See Posts #35–38:
https://www.mobileread.com/forums/sh...38#post3978438
(And I linked to a Wikipedia post describing some styles/conventions around the world.)
Side Note: Of course, just use the proper 24-hour clock and you won't have to deal with the am/pm nonsense!
Quote:
Originally Posted by phossler
[...] but are there any rules?
|
If you're typesetting a physical print book though, there are some typographical guidelines you may want to follow. For example:
Titles:
- Mr. Smith -> Mr.~Smith
- Ms. Jones -> Ms.~Jones
- Dr. John Ioannidis -> Dr.~John Ioannidis
Saint/Street:
- St. Martin's Church -> St.~Martin's Church
- Meet me at Main St. and Example Blvd.
Roman Numerals:
- Charles V -> Charles~V
- King Louis XIV -> King Louis~XIV
Chapter/Part/Appendix:
- See Chapter 1 -> See Chapter~1
- Appendix A -> Appendix~A
Pages:
- See page 123 -> See page~123
- See pp. 123–150 -> See pp.~123–150
Volume:
Editions:
- <i>Title of Book</i>, 2nd ed. -> <i>Title of Book</i>, 2nd~ed.
Ordinals:
- I scored 2nd place -> I scored 2nd~place
Variables:
- Look at line <i>y</i> -> Look at line~<i>y</i>
Equation/Figure Numbers:
- The solution is in Equation 1.2 -> The solution is in Equation~1.2
- Fig. 1.2 shows you the location -> Fig.~1.2 shows you the location
Units:
- Drive for 3.5 km -> Drive for 3.5~km
- Run for 2000 m -> Run for 2000~m
Maths/Equations*:
et al.
- This genius example (Tex et al., 2021) -> This genius example (Tex et~al., 2021)
For a few more examples, see:
TeX Stack Exchange: "When should I use non-breaking space?"
* Note: Proper maths typography is a whole other can of worms...
- - - - -
You could also skim Robert Bringhurst's "The Elements of Typographic Style" or relevant Style Guides.
For example, Bringhurst's Chapter 2.1.5 recommends:
Quote:
2.1.5 Add little or no space within strings of initials.
Names such as W. B. Yeats and J. C. L. Prillwitz need hair spaces, thin spaces or no spaces at all after the intermediary periods. A normal word space follows the last period in the string.
|
Chapter 2.4.6:
Quote:
2.4.6 Link short numerical and mathematical expressions with hard spaces.
All you may see on the keyboard is a space bar, but typographers use several invisible characters: the word space, fixed spaces of various sizes (em space, en space, thin space, figure space, etc) and a hard space or no-break space. The hard space will stretch, like a normal word space, when the line is justified, but it will not convert to a linebreak. Hard spaces are useful for preventing linebreaks within phrases such as 6.2 mm, 3 in., 4 × 4, or in phrases like page 3 and chapter 5.
When it is necessary to break longer algebraic or numerical expressions, such as a + b = c, the break should come at the equal sign or another clear logical pause.
|
Chicago Manual of Style:
Quote:
9.20 Decimal places-European practice.
In European countries, except for Great Britain, the decimal point is represented by a comma. A thin, fixed space, not a comma, separates groups of three digits, whether to the left or to the right of the decimal point. (In electronic publications, a nonbreaking space may be used.) This practice reflects European-style SI usage (see 9.56). Canadians increasingly follow SI usage, retaining the decimal point (or, in French-language contexts, the comma) but using a thin space to separate groups of three digits. In US publications, US style should be followed, except in direct quotations. See also 10.61.
36 333,333 (European style)
36 333.333 (Canadian style)
36,333.333 (US and British style)
|
- - - - -
Speaking of other languages... languages like Polish/Czech have typographical rules on "single letters" at the end of lines:
TeX Stack Exchange: "one-letter word at the end of line"
So if dealing with those types of books, you may need to use non-breaking spaces. (Although this stuff really should be dealt with at the device/layout-algorithm level.)