# LaTeX back-end and sentence spacing

4 messages
Open this post in threaded view
|
Report Content as Inappropriate

## LaTeX back-end and sentence spacing

 This post was updated on . I see at asciidoctor/asciidoctor#681 that a LaTeX back-end for AsciiDoctor is under consideration, and that there is concern about curly quotes, dashes, etc. being passed through. I want to raise another point for consideration: Sentence spacing. LaTeX defaults to the classical pre-typewriter tradition of making the spaces between sentences wider than that between words. This can be turned off with the `\frenchspacing` command, and perhaps that will be necessary in the end—but many people who use LaTeX prefer the older style, and I wonder whether an AsciiDoctor-to-LaTeX translator will be capable of getting this right. (This effect is achievable in HTML-based back-ends as well: With CSS, give paragraphs the `word-spacing` property of [say] 0.25em, then wrap sentences in a `` with a class whose `word-spacing` has been set to zero. And perhaps if the LaTeX back-end gets sentence spacing right, an option to do the same in HTML might be appropriate. But I suspect this will be a feature little desired. At any rate…) LaTeX uses (approximately) the following heuristic for determining sentence-end: a full-stop preceded by a lower-case letter ends an sentence; preceded by an upper-case letter it does not end a sentence (it’s assumed to be an abbreviation); and punctuation like quotes are skipped over. To override this when needed, LaTeX defines the `\@` command. See Will Robertson’s LaTeX Alive: Correct punctuation spaces or the following examples: `J. K. Rowling did not shoot J. R\@.  Kristin Shepard did.` (The `\@` before the full-stop tells LaTeX that this does end the sentence, while the other full-stops after capital letters do not.) `Dr.\@ Frankenstein, how good to see you.  Come on in.` (The `\@` after the full-stop tells LaTeX that this does not end the sentence, although normally full-stops after lower-case letters do.) (I have added a space to the code to show more clearly where the desired end-of-sentence spaces are, but this is neither needed nor recognized in LaTeX.) As I wrote above, perhaps the best thing to do—certainly the easiest—would be to have the LaTeX back-end emit the `\frenchspacing` command, which will turn all this off. But still—is it at all possible to define a (non-disruptive & optional) syntax which will allow the user to make use of this typographical nicety?
Open this post in threaded view
|
Report Content as Inappropriate

## Re: LaTeX back-end and sentence spacing

 Administrator >  I wonder whether an AsciiDoctor-to-LaTeX translator will be capable of getting this right.This request is certainly within reason. I'll admit that I don't know enough about LaTeX right now to make a decision one way or another. I will leave that up to the capable LaTeX community that is forming around this converter.Now that the LaTeX converter setup in it's own repository {1} (code on the way), I encourage you to open this as an issue in this repository so it can be tracked and, if decided upon, integrated into the converter. (Feel free to simply repost this message as the content of the issue).Cheers,-DanOn Mon, Nov 3, 2014 at 6:08 PM, jcsalomon [via Asciidoctor :: Discussion] wrote: I see at asciidoctor/asciidoctor#681 that a LaTeX back-end for AsciiDoctor is under consideration, and that there is concern about curly quotes, dashes, etc. being passed through. I want to raise another point for consideration: Sentence spacing. LaTeX defaults to the classical pre-typewriter tradition of making the spaces between sentences wider than that between words. This can be turned off with the `\frenchspacing` command, and perhaps that will be necessary in the end—but many people who use LaTeX prefer the older style, and I wonder whether an AsciiDoctor-to-LaTeX translator will be capable of getting this right. (This effect is achievable in HTML-based back-ends as well: With CSS, give paragraphs the `word-spacing` property of [say] 0.25em, then wrap sentences in a `` with a class whose `word-spacing` has been set to zero. And perhaps if the LaTeX back-end gets sentence spacing right, an option to do the same in HTML might be appropriate. But I suspect this will be a feature little desired. At any rate…) LaTeX uses (approximately) the following heuristic for determining sentence-end: a full-stop preceded by a lower-case letter ends an sentence; preceded by an upper-case letter it does not end a sentence (it’s assumed to be an abbreviation); and punctuation like quotes are skipped over. To override this when needed, LaTeX defines the `\@` command: `J. K. Rowling did not shoot J. R\@.  Kristin Shepard did.` (The `\@` before the full-stop tells LaTeX that this does end the sentence, while the other full-stops after capital letters do not.) `Dr.\@ Frankenstein, how good to see you.  Come on in.` (The `\@` after the full-stop tells LaTeX that this does not end the sentence, although normally full-stops after lower-case letters do.) (I have added a space to the code to show more clearly where the desired end-of-sentence spaces are, but this is neither needed nor recognized in LaTeX.) As I wrote above, perhaps the best thing to do—certainly the easiest—would be to have the LaTeX back-end emit the `\frenchspacing` command, which will turn all this off. But still—is it at all possible to define a (non-disruptive & optional) syntax which will allow the user to make use of this typographical nicety? If you reply to this email, your message will be added to the discussion below: http://discuss.asciidoctor.org/LaTeX-back-end-and-sentence-spacing-tp2414.html To start a new topic under Asciidoctor :: Discussion, email [hidden email] To unsubscribe from Asciidoctor :: Discussion, click here. NAML -- Dan Allen | http://google.com/profiles/dan.j.allen
Open this post in threaded view
|
Report Content as Inappropriate

## Re: LaTeX back-end and sentence spacing

 Dan “mojavelinux” Allen wrote This request is certainly within reason. I'll admit that I don't know enough about LaTeX right now to make a decision one way or another. I will leave that up to the capable LaTeX community that is forming around this converter. Now that the LaTeX converter setup in it's own repository {1} (code on the way), I encourage you to open this as an issue in this repository so it can be tracked and, if decided upon, integrated into the converter. (Feel free to simply repost this message as the content of the issue). Posted at asciidoctor/asciidoctor-latex#3. —Joel
 In reply to this post by jcsalomon I’ve posted this idea to the asciidoctor/asciidoctor-latex#3, but perhaps this forum will have more eyes on it that can suggest whether it’s a good idea: Is there some sort of symbol sequence that “vanilla” AsciiDoctor can be taught to ignore, but that AsciiDoctor-LaTeX can be taught to explicitly look for and translate to `\@` for the LaTeX back-end?