From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thorsten Jolitz Subject: Re: A question on org-element-headline-interperter Date: Fri, 03 Oct 2014 09:08:48 +0200 Message-ID: <871tqpaav3.fsf@gmail.com> References: <87ppeaxdss.fsf@wmi.amu.edu.pl> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:54526) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZwzH-0002QX-4C for emacs-orgmode@gnu.org; Fri, 03 Oct 2014 03:09:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XZwzA-0005xx-Uh for emacs-orgmode@gnu.org; Fri, 03 Oct 2014 03:09:11 -0400 Received: from plane.gmane.org ([80.91.229.3]:33195) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XZwzA-0005vV-Nk for emacs-orgmode@gnu.org; Fri, 03 Oct 2014 03:09:04 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XZwz8-0000N3-Ky for emacs-orgmode@gnu.org; Fri, 03 Oct 2014 09:09:02 +0200 Received: from g231226238.adsl.alicedsl.de ([92.231.226.238]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 03 Oct 2014 09:09:02 +0200 Received: from tjolitz by g231226238.adsl.alicedsl.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 03 Oct 2014 09:09:02 +0200 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-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Marcin Borkowski writes: Hi, > I guess I don't understand something. I have a headline in a `headline' > variable (say that I did something like (org-element-parse-buffer) and > took one of the headlines from there). I thought that > > (insert > (org-element-headline-interpreter headline (org-element-property ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > :contents headline))) > > would put it into the current buffer; however, it only puts the first > line (without the actual contents). > > What is my misconception here? as I learned myself from Nicolas recently, these are internal functions, the API function for interpreting is ,----[ C-h f org-element-interpret-data RET ] | org-element-interpret-data is an autoloaded compiled Lisp function in | `org-element.el'. | | (org-element-interpret-data DATA &optional PSEUDO-OBJECTS) | | Interpret DATA as Org syntax. | | DATA is a parse tree, an element, an object or a secondary string | to interpret. | | Optional argument PSEUDO-OBJECTS is a list of symbols defining | new types that should be treated as objects. An unknown type not | belonging to this list is seen as a pseudo-element instead. Both | pseudo-objects and pseudo-elements are transparent entities, i.e. | only their contents are interpreted. | | Return Org syntax as a string. `---- -- cheers, Thorsten