emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <mail@nicolasgoaziou.fr>
To: "Pierre-André Cornillon" <pac.herault@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Fontification for the inner bloc of two nested bloc
Date: Tue, 10 Oct 2017 09:16:15 +0200	[thread overview]
Message-ID: <87k203fp6o.fsf@nicolasgoaziou.fr> (raw)
In-Reply-To: <CAGTEyCwwLM1NSeZxo9Y_TV3D6XPGddOkeCDfziXg1RBXmhb1SA@mail.gmail.com> ("Pierre-André Cornillon"'s message of "Sat, 7 Oct 2017 11:11:39 +0200")

Hello,

Pierre-André Cornillon <pac.herault@gmail.com> writes:

> Dear orgmode users/gurus,
>
> I have a question about fontification of inner src bloc.
>
> I have two nested blocks: one special (outer bloc) and one src (inner
> bloc) like this
>
> #+begin_bloc20171001122500
> #+begin_src R
>   blip <- runif(2)
>   test <- rnorm(2)
> #+end_src
>
> #+end_bloc20171001122500
>
> and I want to have the native fontification property for the inner one.
>
> I have already (setq org-src-fontify-natively t) in my .emacs and it
> works like a charm for src blocks alone (not nested) but for nested
> ones it breaks.
>
> Is nested blocks are allowed and if so, is that possible to have that
> fontification property ?

Nested blocks are allowed, but the fontification system has a few
shortcomings, including this one. Ultimately, this part of Org needs to
be rewritten using the parser.

Anyway The bug probably lies in `org-fontify-meta-lines-and-blocks-1'.
Do you want to investigate?

Regards,

-- 
Nicolas Goaziou

  reply	other threads:[~2017-10-10  7:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-07  9:11 Fontification for the inner bloc of two nested bloc Pierre-André Cornillon
2017-10-10  7:16 ` Nicolas Goaziou [this message]
2017-10-11 15:54   ` Pierre-André Cornillon
2017-10-11 16:00     ` Nicolas Goaziou
  -- strict thread matches above, loose matches on Subject: below --
2017-10-05  9:59 Pierre-André Cornillon
2017-10-01 14:36 Pierre-Andre Cornillon

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=87k203fp6o.fsf@nicolasgoaziou.fr \
    --to=mail@nicolasgoaziou.fr \
    --cc=emacs-orgmode@gnu.org \
    --cc=pac.herault@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).