From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: Exporting xml and html code with syntax highlight Date: Fri, 31 Aug 2012 08:13:17 +0200 Message-ID: <87wr0fwpvm.fsf@altern.org> References: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:36579) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T7KTe-00011J-KO for emacs-orgmode@gnu.org; Fri, 31 Aug 2012 02:13:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1T7KTd-0008AU-O7 for emacs-orgmode@gnu.org; Fri, 31 Aug 2012 02:13:10 -0400 Received: from mail-we0-f169.google.com ([74.125.82.169]:52311) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T7KTd-0008AO-Ht for emacs-orgmode@gnu.org; Fri, 31 Aug 2012 02:13:09 -0400 Received: by weys10 with SMTP id s10so1580009wey.0 for ; Thu, 30 Aug 2012 23:13:09 -0700 (PDT) In-Reply-To: (Charles Philip Chan's message of "Fri, 31 Aug 2012 01:46:21 -0400") 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: Charles Philip Chan Cc: Org-mode , schulte eric Hi Charles, Charles Philip Chan writes: > Tonight I had a need to export some xml code with syntax highlight. I > figured that the best way to do it is to modify ob-css.el (by a simple > search and replace). To my delight, it work, so I did one for html > also. I hope people will find them useful. Thanks for exploring/adding this! Since the functions do strictly nothing, we should have a way to add them dynamically, without requiring a new ob-* file. This would be useless for languages you only want to tangle, like XML and HTML. Something like (defun org-babel-support-lang (lang) (defvar org-babel-default-header-[lang] nil) (defun org-babel-execute:[lang] (body params) etc ...) Eric, what do you think? -- Bastien