emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Charles C. Berry" <ccberry@ucsd.edu>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: Scott Randby <srandby@gmail.com>, emacs-orgmode@gnu.org
Subject: Re: Multiple underscores crash org latex export; other exporters survive
Date: Mon, 5 Dec 2016 09:30:16 -0800	[thread overview]
Message-ID: <alpine.OSX.2.20.1612050853030.740@charles-berrys-macbook.local> (raw)
In-Reply-To: <87bmwsatox.fsf@nicolasgoaziou.fr>

On Sun, 4 Dec 2016, Nicolas Goaziou wrote:

> Hello,
>
> Scott Randby <srandby@gmail.com> writes:
>
>> There is an interesting issue here. I sometimes want to use ~ in a code
>> snippet, so I can't use ~code snippet~. Yet,
>
> Indeed, this was discussed in this ML. We need some escape character in
> Org. A general escape character is a bit ambitious, and not necessarily
> useful, but we could introduce one specifically for verbatim and code
> markers, much like in macros and verbatim blocks, e.g.
>
>  ~some\~code\=with special\\ characters~
>
> There is a design decision involved: what character can be escaped? It
> could be anything, or limit to "~" for code and "=" for verbatim
> markers. For example macros limit escape-able characters to "," and "\".
> This makes the contents easier to read, but the rule is inconsistent.
>
> Thoughts?

I do not think this is needed.

The existing markup is simple and useful and does not complicate the 
appearance of the org buffer nor editting it.

More complicated inline markups can be rendered with export snippets, 
macros, and/or inline src blocks. For example:

--
#+MACRO: code src_code[:eval no :exports code]{$1}

{{{code(y~x)}}}
--

will handle many situations.

If one needs to render something with embedded commas and/or backslashes 
like

: y~x(z,w)
: cat("here is a newline\n")

then

: src_code{ y~x(z,w) }
: src_code{ cat("here is a newline\n") }

works if `org-babel-default-header-args:code' is

: '((:eval . "no")(:exports . "code"))

HTH,

Chuck

      parent reply	other threads:[~2016-12-05 17:30 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-03 19:40 Multiple underscores crash org latex export; other exporters survive Scott Otterson
2016-12-03 21:24 ` Scott Randby
2016-12-03 22:31   ` Charles C. Berry
2016-12-04  4:53     ` Scott Randby
2016-12-04 10:13       ` Nicolas Goaziou
2016-12-04 16:03         ` Scott Randby
2016-12-05  8:36         ` Scott Otterson
2016-12-06  1:33           ` Scott Randby
     [not found]             ` <CAPY3P0QcpouDjmNpmaY6FzNSNjZyHAGufrbVtSuBzPxr6mUAzg@mail.gmail.com>
2016-12-06 18:18               ` Scott Randby
2016-12-06 23:50             ` Nicolas Goaziou
2016-12-07  2:06               ` Scott Randby
2016-12-07 11:21                 ` Nicolas Goaziou
2016-12-10 23:24                   ` Scott Randby
2016-12-11  0:05                     ` Nicolas Goaziou
2016-12-12  3:37                       ` Scott Randby
2016-12-12  7:46                         ` Nicolas Goaziou
2016-12-12 15:18                           ` Scott Otterson
2016-12-13 12:54                             ` Nicolas Goaziou
2016-12-05 17:30         ` Charles C. Berry [this message]

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=alpine.OSX.2.20.1612050853030.740@charles-berrys-macbook.local \
    --to=ccberry@ucsd.edu \
    --cc=emacs-orgmode@gnu.org \
    --cc=mail@nicolasgoaziou.fr \
    --cc=srandby@gmail.com \
    /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).