[Orgmode] Re: Bug: #+ATTR_LaTeX broken in LaTeX export [6.36trans (release_6.36.461.g798e)]
Hi Nicolas, Eric, Tassilo and everybody else, Nicolas Goaziou wrote: I don't know about #+BEGIN_changemargin (but as far as I understand, it's coming from org-exp-blocks and should be handled during preprocess-hook, so it is beyond the scope of this patch). To be correct, the `#+BEGIN_changemargin' comes from `Org-special-blocks', not from `Org-exp-blocks': --8---cut here---start-8--- ;; turn Org blocks into LaTeX environments and HTML divs ;; (markup in environments in LaTeX export, or giving LaTeX attributes to ;; sections in export) (try-require 'org-special-blocks) --8---cut here---end---8--- I've disabled, for months, `Org-exp-blocks' as I've switched to Org-Babel for such cases: --8---cut here---start-8--- ;; switch from org-exp-blocks to Org-babel! ;; ;; pre-process blocks when exporting org files (ditaa, dot, comment, R, ;; ;; etc.) ;; (try-require 'org-exp-blocks) --8---cut here---end---8--- Best regards, Seb -- Sébastien Vauban ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Re: Bug: #+ATTR_LaTeX broken in LaTeX export [6.36trans (release_6.36.461.g798e)]
Hi everyone, It seems that the patch in this thread has introduce the following problem: Consider this test file. * Test # test \begin{equation} \e=mc^2 \end{equation} but a^2 should still be treated nicely When exported, the # test line is exported as \# test I have not checked if this really was the patch which did that, but I suspect it. Could someone please check? Thanks. - Carsten On Jul 1, 2010, at 6:44 AM, Tassilo Horn wrote: Eric Schulte schulte.e...@gmail.com writes: Hi Eric, I've applied your patch. I agree that a catchall cleanup function at the end of the export process is not solution. Especially when it makes some perfectly valid constructs (e.g. nested blocks) impossible to export. I can confirm that it works for me, now. Thanks, Tassilo ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode - Carsten ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: Bug: #+ATTR_LaTeX broken in LaTeX export [6.36trans (release_6.36.461.g798e)]
On Jul 1, 2010, at 10:33 AM, Bernt Hansen wrote: Carsten Dominik carsten.domi...@gmail.com writes: Hi everyone, It seems that the patch in this thread has introduce the following problem: Consider this test file. * Test # test \begin{equation} \e=mc^2 \end{equation} but a^2 should still be treated nicely When exported, the # test line is exported as \# test I have not checked if this really was the patch which did that, but I suspect it. Could someone please check? Thanks. Fun with git :) Thank you my wizard. :) This bug is squashed. - Carsten , | 0e636dc2ed8dc4c2a4663551d975ee2a6719c967 is the first bad commit | commit 0e636dc2ed8dc4c2a4663551d975ee2a6719c967 | Author: Eric Schulte schulte.e...@gmail.com | Date: Sun Jun 27 19:35:34 2010 -0700 | | org-exp: check for protection before removing comments | | * lisp/org-exp.el (org-export-handle-comments): check for protection | before removing comments | | :04 04 141f3fd1e9870e39b8dd863668d0d65dfc3677f3 9c5ff59abd1941ef3ba7969156a4ad6ad19fb0eb M lisp | bisect run success ` This commit was determined automatically with git bisect and the following script/setup. ,[ /tmp/test.org ] | * Test | | # test | \begin{equation} | \e=mc^2 | \end{equation} | | but a^2 should still be treated nicely ` ,[ /tmp/bisect.sh ] | #/bin/sh | emacs -batch -q -l /home/bernt/minimal.emacs -l /tmp/export-quit.el | if grep '^\\# test' /tmp/test.tex | then | exit 1 | else | exit 0 | fi ` ,[ /home/bernt/minimal.emacs ] | (add-to-list 'load-path (expand-file-name ~/git/org-mode/lisp)) | (add-to-list 'auto-mode-alist '(\\.\\(org\\|org_archive\\|txt\\) $ . org-mode)) | (setq org-agenda-files '(/tmp/test.org)) | (require 'org-install) | | (global-set-key \C-cl 'org-store-link) | (global-set-key \C-ca 'org-agenda) | (global-set-key \C-cb 'org-iswitchb) | ` ,[ /tmp/export-quit.el ] | (find-file /tmp/test.org) | (call-interactively 'org-export-as-latex) | (save-buffers-kill-emacs) ` $ git bisect start master 188105 $ git bisect run /tmp/bisect.sh -Bernt - Carsten ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: Bug: #+ATTR_LaTeX broken in LaTeX export [6.36trans (release_6.36.461.g798e)]
Hi Tassilo, Tassilo Horn wrote: * Implementieren ** Composite Pattern #+ATTR_LaTeX: width=\textwidth [[./composite-pattern.png]] Unfortunately, the image doesn't show up, but the #+ATTR_LaTeX is displayed literally. Here's the LaTeX code produced by the LaTeX export. Just for information, this must be the same cause as for the symptom I described in Tables and environment with parameters. Best regards, Seb -- Sébastien Vauban ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Re: Bug: #+ATTR_LaTeX broken in LaTeX export [6.36trans (release_6.36.461.g798e)]
I don't know about #+BEGIN_changemargin (but as far as I understand, it's coming from org-exp-blocks and should be handled during preprocess-hook, so it is beyond the scope of this patch). There is some design choice involved here. Until recently, there was a catch-all function called org-export-handle-comments that was called at the end of the export process and removed any line starting with a #. It was certainly useful, but made things hard to debug : had the #+ATTR_LaTeX line been misinterpreted or just silently deleted ? At the moment, org-export-handle-comments only handles... comments. But everything that is not comments has to be taken care of somewhere else. For example, org-export-attach-captions-and-attributes deletes #+CAPTIONS and #+ATTR_backend in the process, and org-export-select-backend-specific-text deletes #+backend and #+ATTR_backend not used (that's what my patch do, actually). If you want to apply my patch (v. 2), we have to define a function to remove #+TBLFM and #+TBLNAME lines because there is none at the moment. It could be org-export-special-table-lines but it doesn't look like it's the purpose of that function. Otherwise, you can just ignore the patch and bring back the full power to org-export-handle-comments. I personally prefer avoiding do-it-all functions. But I'm not a maintainer. Regards, -- Nicolas ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: Bug: #+ATTR_LaTeX broken in LaTeX export [6.36trans (release_6.36.461.g798e)]
Eric Schulte schulte.e...@gmail.com writes: Hi Eric, I've applied your patch. I agree that a catchall cleanup function at the end of the export process is not solution. Especially when it makes some perfectly valid constructs (e.g. nested blocks) impossible to export. I can confirm that it works for me, now. Thanks, Tassilo ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode