From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: Add contents-begin and contents-end to src-block in org-element.el Date: Mon, 25 Dec 2017 09:49:00 +0100 Message-ID: <87o9mnfb0j.fsf@nicolasgoaziou.fr> References: <87tvwggo9s.fsf@nicolasgoaziou.fr> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:43910) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eTORW-0004gN-5p for emacs-orgmode@gnu.org; Mon, 25 Dec 2017 03:49:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eTORV-0000M6-7Q for emacs-orgmode@gnu.org; Mon, 25 Dec 2017 03:49:06 -0500 Received: from relay4-d.mail.gandi.net ([2001:4b98:c:538::196]:43171) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eTORV-0000L3-0J for emacs-orgmode@gnu.org; Mon, 25 Dec 2017 03:49:05 -0500 In-Reply-To: (Somelauw .'s message of "Mon, 25 Dec 2017 00:55:45 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: "Somelauw ." Cc: emacs-orgmode@gnu.org Hello, "Somelauw ." writes: > 2017-12-24 16:05 GMT+01:00 Nicolas Goaziou : >> Contents mean "data in Org syntax". There are no such contents in source >> blocks. Therefore, the parser does not provide :contents-begin >> and :contents-end for them. > > Thanks for your quick response As I understand from your reply, > :contents-begin/end should be reserved for elements that can contain > other org-elements or org-objects. > > I'm writing a plugin that allows one to operate on the inner body of > an org-element and so far I'm relying on :contents-begin and > :contents-end. This has worked pretty well so far on most org > elements, but org-src-blocks seem to be an exception. I may want to > special-case these. > > By the way, do you know of any other org-elements that have an inner > body that doesn't classify as "data in Org syntax"? comment, comment blocks, example blocks, export blocks, fixed-width, keyword, latex-environment, node property. These elements usually set :value property instead. Regards, -- Nicolas Goaziou