emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: James Harkins <jamshark70@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: Do not export single newlines to latex
Date: Mon, 9 Jun 2014 07:42:08 +0000 (UTC)	[thread overview]
Message-ID: <loom.20140609T093750-697@post.gmane.org> (raw)
In-Reply-To: 87singocwz.fsf@mailbox.org

Alexander Baier <alexander.baier <at> mailbox.org> writes:

> I am writing a document for which my main export target is latex.  To
> obtain reasonable diffs wrt version control systems, I use one line
> per sentence in addition to =visual-line-mode= as was mentioned in this
> post last November http://thread.gmane.org/gmane.emacs.orgmode/78332.
> 
> The problem with this is that these newlines get translated to newlines
> in latex aka "\\<newline>".

I use the LaTeX exporter routinely, and I have never seen this behavior. For
instance,

~~~ org input file
* Headline
The first sentence.
The second sentence.
~~~

~~~ LaTeX export (minus preamble)
\begin{document}

\maketitle
\tableofcontents

\section{Headline}
\label{sec-1}
The first sentence.
The second sentence.
% Emacs 23.3.1 (Org mode 8.2.5f)
\end{document}
~~~

I also checked the customization variables in the org-export-latex group,
and I didn't see anything immediately relevant to newline translation.

So I can think of a couple of possibilities:

- You might have some strange configuration lying around somewhere.
(Additional evidence that you're seeing nonstandard behavior is that none of
the .el files in the org distribution contain the string 'newline', let
alone '<newline>'.)

- Or you might be using a newer org than I'm using, in which case you might
be seeing a regression bug. (As far as I know, a single line break in the
input should definitely not translate into "\\<newline>"!!)

> I want the export back end to ignore those
> single newlines and only insert "\\<newline>" into the latex document
> upon encountering two consecutive newlines in my org-mode file.

Two consecutive line breaks in the input should be copied over directly into
the .tex file. It's then up to LaTeX to interpret this -- per its own
standards -- as a paragraph break. Again, "\\<newline>" would be quite
exceptional.

hjh

  reply	other threads:[~2014-06-09  7:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-07 17:19 Do not export single newlines to latex Alexander Baier
2014-06-09  7:42 ` James Harkins [this message]
2014-06-09 11:13   ` Alexander Baier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=loom.20140609T093750-697@post.gmane.org \
    --to=jamshark70@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).