From mboxrd@z Thu Jan 1 00:00:00 1970 From: super.quazimodo@gmail.com (S.S) Subject: Bug: Literal Examples are malformed in exports (to html/tex) [8.0.3 (release_8.0.3-165-g60ca9e @ /home/quazimodo/.emacs.d/vendor/org-mode/lisp/)] Date: Thu, 30 May 2013 04:15:22 +1000 Message-ID: <87ehcp64at.fsf@gmail.com> Return-path: Received: from eggs.gnu.org ([208.118.235.92]:43212) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UhkuR-0000W9-7K for emacs-orgmode@gnu.org; Wed, 29 May 2013 14:15:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UhkuN-0002rn-Sq for emacs-orgmode@gnu.org; Wed, 29 May 2013 14:15:39 -0400 Received: from mail-pd0-f181.google.com ([209.85.192.181]:50823) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UhkuN-0002rb-MP for emacs-orgmode@gnu.org; Wed, 29 May 2013 14:15:35 -0400 Received: by mail-pd0-f181.google.com with SMTP id bv13so7371130pdb.12 for ; Wed, 29 May 2013 11:15:34 -0700 (PDT) Received: from lappy.local.home (c27-253-100-110.carlnfd2.nsw.optusnet.com.au. [27.253.100.110]) by mx.google.com with ESMTPSA id cd2sm38190630pbd.35.2013.05.29.11.15.32 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Wed, 29 May 2013 11:15:33 -0700 (PDT) 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 Remember to cover the basics, that is, what you expected to happen and what in fact did happen. You don't know how to make a good report? See http://orgmode.org/manual/Feedback.html#Feedback Your bug report will be posted to the Org-mode mailing list. ------------------------------------------------------------------------ I add a literal example like #+BEGIN_SRC (defun org-xor (a b) "Exclusive or." (if a (not b) b)) #+END_SRC and #+BEGIN_EXAMPLE (defun org-xor (a b) "Exclusive or." (if a (not b) b)) #+END_EXAMPLE to an org file in various places. Export with (org-html-export-to-html) and (org-latex-export-to-latex) produces inconsistent and malformed example blocks. Some of these blocks produce

#+BEGINEXAMPLE (defun org-xor (a b) "Exclusive or." (if a (not b) b))

Others produce

(defun org-xor (a b) "Exclusive or." (if a (not b) b))

and \#+BEGIN$_{\text{EXAMPLE}}$ (defun org-xor (a b) "Exclusive or." (if a (not b) b)) \#+END$_{\text{EXAMPLE}}$ vs \begin{example } (defun org-xor (a b) "Exclusive or." (if a (not b) b)) \end{example I expect to see correctly created example areas that maintain spacing/tabs/newlines. I add the following before an example block #+ATTR_HTML: :textarea t :width 40 and it creates

(defun org-xor (a b) "Exclusive or." (if a (not b) b))

NOTE: I do not believe that I have a mixed install. By deleting org-mode 8.0.3 and using the built-in 7.8.11 these problems are resolved. Emacs : GNU Emacs 24.2.1 (i686-pc-linux-gnu, GTK+ Version 2.24.10) of 2012-11-10 on charichuelo, modified by Debian Package: Org-mode version 8.0.3 (release_8.0.3-165-g60ca9e @ /home/quazimodo/.emacs.d/vendor/org-mode/lisp/) current state: ============== (setq org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point org-babel-execute-safely-maybe) org-latex-format-headline-function 'org-latex-format-headline-default-function org-tab-first-hook '(org-hide-block-toggle-maybe org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe org-babel-header-arg-expand) org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers org-cycle-hide-inline-tasks org-cycle-show-empty-lines org-optimize-window-after-visibility-change) org-agenda-before-write-hook '(org-agenda-add-entry-text) org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook) org-babel-pre-tangle-hook '(save-buffer) org-occur-hook '(org-first-headline-recenter) org-metaup-hook '(org-babel-load-in-session-maybe) org-confirm-elisp-link-function 'yes-or-no-p org-clock-out-hook '(org-clock-remove-empty-clock-drawer) org-mode-hook '((lambda nil (org-add-hook (quote change-major-mode-hook) (quote org-show-block-all) (quote append) (quote local)) ) (lambda nil (org-add-hook (quote change-major-mode-hook) (quote org-babel-show-result-all) (quote append) (quote local)) ) org-babel-result-hide-spec org-babel-hide-all-hashes) org-metadown-hook '(org-babel-pop-to-session-maybe) org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer) org-after-todo-state-change-hook '(org-clock-out-if-current) org-confirm-shell-link-function 'yes-or-no-p )