Re: [O] Add figure/table numbers to HTML captions
Hello Nicolas, I'll revise my patch in this weekend. thanks. I've split my work into these three commits: 0001-ox-html-add-figure-and-table-numbers-to-HTML-caption.patch 0002-ox-add-dictionary-entry-for-numbered-figures.patch 0003-ox-add-Japanese-translations-for-figures-and-tables.patch (enclosed in the attachments) I've also pushed them to my github repository: g...@github.com:yoshinari-nomura/org-mode.git branch: tab-and-fig-number-to-ox-html Please check the commits. I'm willing to revise them again if needed. Thanks for your great effort to tidy-up my rough work. Regards, -- Yoshinari Nomura https://github.com/yoshinari-nomura commit a82e712c3d60d8b58e2cffe13d5cbcdfa25ede24 Author: Yoshinari Nomura n...@quickhack.net Date: Sat Jun 29 15:06:49 2013 +0900 ox: add Japanese translations for figures and tables * lisp/ox.el: (org-export-dictionary): Add Japanese translations for figures and tables commit faced47cb6d049cbb4b6323556543bd86e32884d Author: Yoshinari Nomura n...@quickhack.net Date: Sat Jun 29 15:02:41 2013 +0900 ox: add dictionary entry for numbered figures * lisp/ox.el: (org-export-dictionary): Add Figure %d: entry in the same manner with Table %d:. commit 793f69627fa290c95d41c0af9792fdafdda98b06 Author: Yoshinari Nomura n...@quickhack.net Date: Sat Jun 29 14:44:52 2013 +0900 ox-html: add figure and table numbers to HTML captions * lisp/ox-html.el: (org-html--has-caption-p): New function. (org-html-link--inline-image), (org-html-table): Prepend ordinal number to caption. (org-html-link): Make numbered link by counting captioned figures and tables. From 793f69627fa290c95d41c0af9792fdafdda98b06 Mon Sep 17 00:00:00 2001 From: Yoshinari Nomura n...@quickhack.net Date: Sat, 29 Jun 2013 14:44:52 +0900 Subject: [PATCH 1/3] ox-html: add figure and table numbers to HTML captions * lisp/ox-html.el: (org-html--has-caption-p): New function. (org-html-link--inline-image), (org-html-table): Prepend ordinal number to caption. (org-html-link): Make numbered link by counting captioned figures and tables. --- lisp/ox-html.el | 32 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/lisp/ox-html.el b/lisp/ox-html.el index a996b40..30b23ca 100644 --- a/lisp/ox-html.el +++ b/lisp/ox-html.el @@ -1370,6 +1370,13 @@ (defun org-html--textarea-block (element) (or (plist-get attr :height) (org-count-lines code)) code))) +(defun org-html--has-caption-p (element optional info) + Non-nil when ELEMENT has a caption affiliated keyword. +INFO is a plist used as a communication channel. This function +is meant to be used as a predicate for `org-export-get-ordinal' or +a value to `org-html-standalone-image-predicate'. + (org-element-property :caption element)) + Table (defun org-html-htmlize-region-for-paste (beg end) @@ -2532,7 +2539,15 @@ (defun org-html-link--inline-image (link desc info) (expand-file-name raw-path)) (t raw-path))) (parent (org-export-get-parent-element link)) - (caption (org-export-data (org-export-get-caption parent) info)) + (caption + (let ((raw (org-export-data (org-export-get-caption parent) info)) + (org-html-standalone-image-predicate 'org-html--has-caption-p)) + (if (org-string-nw-p raw) + (concat (format (org-html--translate Figure %d: info) +(org-export-get-ordinal + link info nil 'org-html-standalone-image-p)) + raw) + raw))) (label (org-element-property :name parent))) ;; Return proper string, depending on DISPOSITION. (org-html-format-inline-image @@ -2725,14 +2740,19 @@ (defun org-html-link (link desc info) (org-export-solidify-link-text href) attributes desc))) ;; Fuzzy link points to a target. Do as above. (t - (let ((path (org-export-solidify-link-text path)) number) + (let* ((path (org-export-solidify-link-text path)) number + (caption-predicate + (if (org-html--has-caption-p destination) + 'org-html--has-caption-p)) + (org-html-standalone-image-predicate caption-predicate)) (unless desc (setq number (cond ((org-html-standalone-image-p destination info) (org-export-get-ordinal (assoc 'link (org-element-contents destination)) info 'link 'org-html-standalone-image-p)) - (t (org-export-get-ordinal destination info + (t (org-export-get-ordinal + destination info nil caption-predicate (setq desc (when number (if (atom number) (number-to-string number) (mapconcat 'number-to-string number .) @@ -3145,6 +3165,8 @@ (defun org-html-table (table contents info) (t (let* ((label (org-element-property :name table)) (caption (org-export-get-caption table)) + (number (org-export-get-ordinal + table info nil 'org-html--has-caption-p)) (attributes (if (org-html-html5-p info)
Re: [O] Bug: Export is crashing [8.0.3 (release_8.0.3-295-g91a4c8.dirty @ ~/org-mode-8/lisp/)]
Hello, Rustom Mody rustompm...@gmail.com writes: Now I find the crash occurs between org-export-preprocess-string and org-footnote-normalize These functions do not exist in the current export framework. You're calling the old exporter. Regards, -- Nicolas Goaziou
Re: [O] Add figure/table numbers to HTML captions
Hello, Yoshinari Nomura n...@quickhack.net writes: I've split my work into these three commits: 0001-ox-html-add-figure-and-table-numbers-to-HTML-caption.patch 0002-ox-add-dictionary-entry-for-numbered-figures.patch 0003-ox-add-Japanese-translations-for-figures-and-tables.patch (enclosed in the attachments) Thanks for your work. Some minor comments below. commit a82e712c3d60d8b58e2cffe13d5cbcdfa25ede24 Author: Yoshinari Nomura n...@quickhack.net Date: Sat Jun 29 15:06:49 2013 +0900 ox: add Japanese translations for figures and tables * lisp/ox.el: (org-export-dictionary): Add Japanese translations for figures and tables You need to add TINYCHANGE at the end of your commit messages, since, AFAIK, you haven't signed FSF papers yet. -(let ((path (org-export-solidify-link-text path)) number) +(let* ((path (org-export-solidify-link-text path)) number + (caption-predicate +(if (org-html--has-caption-p destination) +'org-html--has-caption-p)) You can remove this. Just use `org-html--has-caption-p' and replaces references to `caption-predicate' below with it. Otherwise, the patch looks good. Could you send the files as an attachment? It will be easier for me to apply them. Regards, -- Nicolas Goaziou
Re: [O] Help with beamer environments + org-special-blocks!
Hello Nicolas, Nicolas Goaziou wrote: Sebastien Vauban writes: No. I fixed it ten days ago (dffdc49). Though I'm now on Org-mode version 8.0.3 (release_8.0.3-295-g91a4c8), pulled this morning, I don't see it fixed. I realize that the patch won't fix it. This patch was introduced to allow something like: #+begin_figure* ... #+end_figure* again. But it still expects the same string after the begin_ and the end_. In this case strings are different because of the arguments to the environment. Therefore, the correct way to set this is using the #+attr_latex line, as in your first case. I hope it is less confusing now. It is. And one solution is enough... ;-) Moreover, I guess putting the arguments on a LaTeX line makes it more portable: what would happen with those arguments for HTML, for example? Here, a simple mychangemargin DIV won't hurt. Best regards, Seb -- Sebastien Vauban
Re: [O] Add figure/table numbers to HTML captions
Hi Nicolas, ox: add Japanese translations for figures and tables * lisp/ox.el: (org-export-dictionary): Add Japanese translations for figures and tables You need to add TINYCHANGE at the end of your commit messages, since, AFAIK, you haven't signed FSF papers yet. Yes. - (let ((path (org-export-solidify-link-text path)) number) + (let* ((path (org-export-solidify-link-text path)) number + (caption-predicate + (if (org-html--has-caption-p destination) + 'org-html--has-caption-p)) You can remove this. Just use `org-html--has-caption-p' and replaces references to `caption-predicate' below with it. OK. Sorry for bothering you. To tell the truth, I did not have enough confidence that any other elements other than tables and figures are safe even if they were impposed to have captions. Regards, -- Yoshinari Nomura https://github.com/yoshinari-nomura From 45eadd6308db8f0ec8646d7e23ce17b46d1f93fe Mon Sep 17 00:00:00 2001 From: Yoshinari Nomura n...@quickhack.net Date: Sat, 29 Jun 2013 14:44:52 +0900 Subject: [PATCH 1/3] ox-html: add figure and table numbers to HTML captions * lisp/ox-html.el: (org-html--has-caption-p): New function. (org-html-link--inline-image), (org-html-table): Prepend ordinal number to caption. (org-html-link): Make numbered link by counting captioned figures and tables. --- lisp/ox-html.el | 29 + 1 file changed, 25 insertions(+), 4 deletions(-) diff --git a/lisp/ox-html.el b/lisp/ox-html.el index a996b40..0b8ca8d 100644 --- a/lisp/ox-html.el +++ b/lisp/ox-html.el @@ -1370,6 +1370,13 @@ (defun org-html--textarea-block (element) (or (plist-get attr :height) (org-count-lines code)) code))) +(defun org-html--has-caption-p (element optional info) + Non-nil when ELEMENT has a caption affiliated keyword. +INFO is a plist used as a communication channel. This function +is meant to be used as a predicate for `org-export-get-ordinal' or +a value to `org-html-standalone-image-predicate'. + (org-element-property :caption element)) + Table (defun org-html-htmlize-region-for-paste (beg end) @@ -2532,7 +2539,15 @@ (defun org-html-link--inline-image (link desc info) (expand-file-name raw-path)) (t raw-path))) (parent (org-export-get-parent-element link)) - (caption (org-export-data (org-export-get-caption parent) info)) + (caption + (let ((raw (org-export-data (org-export-get-caption parent) info)) + (org-html-standalone-image-predicate 'org-html--has-caption-p)) + (if (org-string-nw-p raw) + (concat (format (org-html--translate Figure %d: info) +(org-export-get-ordinal + link info nil 'org-html-standalone-image-p)) + raw) + raw))) (label (org-element-property :name parent))) ;; Return proper string, depending on DISPOSITION. (org-html-format-inline-image @@ -2725,14 +2740,16 @@ (defun org-html-link (link desc info) (org-export-solidify-link-text href) attributes desc))) ;; Fuzzy link points to a target. Do as above. (t - (let ((path (org-export-solidify-link-text path)) number) + (let ((path (org-export-solidify-link-text path)) number + (org-html-standalone-image-predicate 'org-html--has-caption-p)) (unless desc (setq number (cond ((org-html-standalone-image-p destination info) (org-export-get-ordinal (assoc 'link (org-element-contents destination)) info 'link 'org-html-standalone-image-p)) - (t (org-export-get-ordinal destination info + (t (org-export-get-ordinal + destination info nil 'org-html--has-caption-p (setq desc (when number (if (atom number) (number-to-string number) (mapconcat 'number-to-string number .) @@ -3145,6 +3162,8 @@ (defun org-html-table (table contents info) (t (let* ((label (org-element-property :name table)) (caption (org-export-get-caption table)) + (number (org-export-get-ordinal + table info nil 'org-html--has-caption-p)) (attributes (if (org-html-html5-p info) (org-html--make-attribute-string @@ -3183,7 +3202,9 @@ (defun org-html-table (table contents info) (format (if org-html-table-caption-above caption align=\above\%s/caption caption align=\bottom\%s/caption) - (org-export-data caption info))) + (concat + (format (org-html--translate Table %d: info) number) + (org-export-data caption info (funcall table-column-specs table info) contents) -- 1.8.2.1 From 26b004825a1ac9337f9e677040cc934dcbeb878f Mon Sep 17 00:00:00 2001 From: Yoshinari Nomura n...@quickhack.net Date: Sat, 29 Jun 2013 15:02:41 +0900 Subject: [PATCH 2/3] ox: add dictionary entry for numbered figures * lisp/ox.el: (org-export-dictionary): Add Figure %d: entry in the same manner with Table %d:. TINYCHANGE --- lisp/ox.el | 3 +++ 1 file changed, 3
Re: [O] Bug: Export is crashing [8.0.3 (release_8.0.3-295-g91a4c8.dirty @ ~/org-mode-8/lisp/)]
On Sat, Jun 29, 2013 at 1:11 PM, Nicolas Goaziou n.goaz...@gmail.comwrote: Hello, Rustom Mody rustompm...@gmail.com writes: Now I find the crash occurs between org-export-preprocess-string and org-footnote-normalize These functions do not exist in the current export framework. You're calling the old exporter. Regards, -- Nicolas Goaziou So then something is wrong with my git. [I am on a different machine right now so following is from memory...] a. git pull shows upto date b. org version shows 8.0.2 (or thereabouts) Is there some 'git reset --hard ...' magic that I can try? Of course I could just download whole again but that seems strange thing to do... -- http://www.the-magus.in http://blog.languager.org
Re: [O] Add figure/table numbers to HTML captions
Yoshinari Nomura n...@quickhack.net writes: OK. Sorry for bothering you. You're not bothering me. I applied your patches and added you to the list of contributors without FSF papers. Please consider signing them if you want to provide more patches to Org mode. Thank you again. Regards, -- Nicolas Goaziou
Re: [O] Bug: Export is crashing [8.0.3 (release_8.0.3-295-g91a4c8.dirty @ ~/org-mode-8/lisp/)]
On Sat, Jun 29, 2013 at 5:15 PM, Rustom Mody rustompm...@gmail.com wrote: On Sat, Jun 29, 2013 at 1:11 PM, Nicolas Goaziou n.goaz...@gmail.comwrote: Hello, Rustom Mody rustompm...@gmail.com writes: Now I find the crash occurs between org-export-preprocess-string and org-footnote-normalize These functions do not exist in the current export framework. You're calling the old exporter. Regards, -- Nicolas Goaziou So then something is wrong with my git. [I am on a different machine right now so following is from memory...] a. git pull shows upto date b. org version shows 8.0.2 (or thereabouts) Is there some 'git reset --hard ...' magic that I can try? Of course I could just download whole again but that seems strange thing to do... Well finally! C-c C-e works (at least on one machine!) I was using org-export-as-html Maybe if it is non-working it should be removed?
Re: [O] Open Document Exporter
I need time to review other issues you are raising. Georg Lehner jorge-...@magma.com.ni writes: 4. LaTeX like definition lists Here is a patch and sample documents. You can pull from my private repo which is at http://repo.or.cz/w/org-mode/org-kjn.git From 7dfa274163fb3a06ff947e1af884af49dca34b0e Mon Sep 17 00:00:00 2001 From: Jambunathan K kjambunat...@gmail.com Date: Sat, 29 Jun 2013 17:59:48 +0530 Subject: [PATCH] ox-odt: Support for typesetting Description lists as in LaTeX * etc/styles.OrgOdtStyles.xml (OrgDescriptionTerm) (OrgDescriptionDefinition): New styles for typesetting description lists. * lisp/ox-odt.el (org-odt-description-list-style): New user option. (org-odt--translate-description-lists/html): Renmed from `org-odt--translate-description-lists. Use new style OrgDescriptionTerm. Update comments. (org-odt--translate-description-lists/latex): New. (org-odt-bold): Add an internal `:style' property. --- etc/styles/OrgOdtStyles.xml | 10 +++ lisp/ox-odt.el | 141 +- 2 files changed, 134 insertions(+), 17 deletions(-) diff --git a/etc/styles/OrgOdtStyles.xml b/etc/styles/OrgOdtStyles.xml index f41d984..c2c32fa 100644 --- a/etc/styles/OrgOdtStyles.xml +++ b/etc/styles/OrgOdtStyles.xml @@ -729,6 +729,16 @@ /text:list-level-style-number /text:list-style + style:style style:name=OrgDescriptionTerm style:family=text + style:text-properties fo:font-weight=bold/ + /style:style + + style:style style:name=OrgDescriptionDefinition style:family=paragraph style:parent-style-name=Text_20_body style:class=text + style:paragraph-properties fo:margin-left=0.64cm fo:margin-right=0cm fo:text-indent=-0.64cm style:auto-text-indent=false +style:tab-stops/ + /style:paragraph-properties + /style:style + text:list-style style:name=OrgSrcBlockNumberedLine text:list-level-style-number text:level=1 style:num-format=1 style:list-level-properties text:space-before=0.635cm text:min-label-width=0.635cm text:min-label-distance=0.101cm fo:text-align=end/ diff --git a/lisp/ox-odt.el b/lisp/ox-odt.el index a76f7dd..0eaffcb 100644 --- a/lisp/ox-odt.el +++ b/lisp/ox-odt.el @@ -86,7 +86,7 @@ (org-export-define-backend 'odt :export-block ODT :filters-alist '((:filter-parse-tree . (org-odt--translate-latex-fragments - org-odt--translate-description-lists + org-odt--translate-description-lists ; Dummy symbol org-odt--translate-list-tables))) :menu-entry '(?o Export to ODT @@ -777,6 +777,22 @@ (defcustom org-odt-pixels-per-inch display-pixels-per-inch :version 24.1) + Lists + +(defcustom org-odt-description-list-style #'org-odt--translate-description-lists/html + Specify how description lists are rendered. +Choose one of HTML or LaTeX style. + :type '(choice + (const :tag Use HTML style org-odt--translate-description-lists/html ) + (const :tag Use LaTeX style org-odt--translate-description-lists/latex )) + :group 'org-export-odt + :set (lambda (symbol value) + Alias `org-odt--translate-description-lists'. + (set-default symbol value) + (fset 'org-odt--translate-description-lists value)) + :version 24.1) + + Src Block (defcustom org-odt-create-custom-styles-for-srcblocks t @@ -1583,7 +1599,11 @@ (defun org-odt-bold (bold contents info) CONTENTS is the text with bold markup. INFO is a plist holding contextual information. (format text:span text:style-name=\%s\%s/text:span - Bold contents)) + ;; Internally, `org-odt--translate-description-lists/html' + ;; or `org-odt--translate-description-lists/latex' requests + ;; a custom style for bold. + (or (org-element-property :style bold) Bold) + contents)) Center Block @@ -3650,7 +3670,7 @@ (defun org-odt-table (table contents info) ;; item, but also within description lists and low-level ;; headlines. -;; See `org-odt-translate-description-lists' and +;; See `org-odt--translate-description-lists' and ;; `org-odt-translate-low-level-headlines' for how this is ;; tackled. @@ -3869,27 +3889,44 @@ (defun org-odt--translate-latex-fragments (tree backend info) ;; This translator is necessary to handle indented tables in a uniform ;; manner. See comment in `org-odt--table'. -(defun org-odt--translate-description-lists (tree backend info) +;; Depending on user option `org-odt-description-list-style', +;; description lists can be typeset either as in HTML documents or as +;; in LaTeX documents. + +(defun org-odt--translate-description-lists/html (tree backend info) ;; OpenDocument has no notion of a description list. So simulate it ;; using plain lists. Description lists in the exported document ;; are typeset in the same manner as they are in a typical HTML - ;; document. + ;; document. See `org-odt--translate-description-lists/latex' for + ;; yet another way of translation. ;; ;; Specifically, a description
Re: [O] Open Document Exporter
Georg Lehner jorge-...@magma.com.ni writes: 1. content.xml changed on disk == At the end of the export process I get the message: content.xml changed on disk; really edit the buffer? (y, n, r or C-h) Please type y, n or r; or ? for help After typing 'y', I have to reconfirm with 'yes' and then with 'y' again to get a valid export. Any tips how to fix or avoid this? If you have set up everything correctly, C-c C-e O (capital O) should launch LibreOffice for you. If not, you may have to do some extra configuration. Here is what I do on my Debian. Install xdg-utils. sudo apt-get install xdg-utils Make sure that xdg-open launches LibreOffice. xdg-open file.odt Add this to your .emacs (setcdr (assq 'system org-file-apps-defaults-gnu ) xdg-open %s) If you are on Windows machines, make sure that `temporary-file-directory' is configured correctly. Check *Messages* buffer and you will know what the ODT exporter is doing.
Re: [O] Open Document Exporter
Georg Lehner jorge-...@magma.com.ni writes: 2. Blank lines after headlines = After each headline I get a blank line. Can these be suppressed? I'd like to control the separation between headline and text by styles and not by extra lines. When you say headline do you mean headline or title/subtitle? Show me a sample Org and ODT file.
Re: [O] Add figure/table numbers to HTML captions
Hi Nicolas, OK. Sorry for bothering you. You're not bothering me. I applied your patches and added you to the list of contributors without FSF papers. Please consider signing them if you want to provide more patches to Org mode. Thank you so much. I'll go on the FSF procedure. -- Yoshinari Nomura https://github.com/yoshinari-nomura
Re: [O] Modifying the Beamer Exporter
I want to include my collaborators in the header of each org file just as I would authors, that is by including a line like #+COLLABORATORS: Alice Bob I've found some limited documentation on modifying the exporter (manual section 12.3) and taken a look at ox.el, ox-latex.el, ox-beamer.el, etc. What I did was: + Create a new backend derived from the beamer one + add COLLABORATORS to its options-alist + set the template (in translate-alist) to one handling collaborators This works, but before I continued on making other modifications (in a similar vein), I wanted to check in with people with a higher level understanding. In general if it's generally useful make a patch (if feasible). . . Could you point out exactly which function (with ref to the Beamer manual) you're using? Searching for collaborator in the manual didn't give me any hints. . . Maybe, maybe not. Difficult to say unless you give us a better idea of what kind of changes you plan on making. To add to Eric's comment: Filters is a viable option and potentially more sustainable if your code ain't submitted up stream. It depends on the nature of your changes. –Rasmus -- This is the kind of tedious nonsense up with which I will not put
Re: [O] [RFC] Introduce ox-i18n.el
Hi Nicolas, Nicolas Goaziou n.goaz...@gmail.com writes: I would like to move every variable and function related to internationalization (i.e smart quotes and translations) in a dedicated file (ox-i18n.el) instead of ox.el. Considering ox.el is 6k lines long, I think it can be a bit tedious to locate and modify internationalization entries. And since we are missing quite a few translations, every little bit can help. Maybe we can generalize even more, call it org-i18n.el and have `org-clock-clocktable-language-setup' (and maybe others) included? If ox-i18n.el exists, it will be confusing to have other i18n pieces in other part of Org. If the *only* purpose is to boost translations, I don't think moving the code the right thing to do: we simply need to give more pointers on the website on how to help with it. 2 cts, -- Bastien
[O] [PATCH] ox-html: Restore wrongly omitted table attributes under HTML5.
From edd97671641e28c3e240efe6ea8fa8d77b4b7eae Mon Sep 17 00:00:00 2001 From: Kodi Arfer g...@arfer.net Date: Sat, 29 Jun 2013 10:43:07 -0400 Subject: [PATCH] ox-html: Restore wrongly omitted table attributes under HTML5. * lisp/ox-html.el (org-html-table): For HTML5, omit :html-table-attributes but not :id or :attr_html. TINYCHANGE --- lisp/ox-html.el | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lisp/ox-html.el b/lisp/ox-html.el index 4a2b6ec..bcf86ee 100644 --- a/lisp/ox-html.el +++ b/lisp/ox-html.el @@ -3163,12 +3163,12 @@ contextual information. (number (org-export-get-ordinal table info nil 'org-html--has-caption-p)) (attributes - (if (org-html-html5-p info) - (org-html--make-attribute-string - (org-combine-plists - (and label (list :id (org-export-solidify-link-text label))) - (plist-get info :html-table-attributes) - (org-export-read-attribute :attr_html table) + (org-html--make-attribute-string + (org-combine-plists + (and label (list :id (org-export-solidify-link-text label))) + (unless (org-html-html5-p info) + (plist-get info :html-table-attributes)) + (org-export-read-attribute :attr_html table (alignspec (if (and (boundp 'org-html-format-table-no-css) org-html-format-table-no-css) -- 1.8.1.2
[O] [PATCH] Add :caption attribute to #+ATTR_LATEX property
This feature is very useful when you export org to latex with custom caption command, for example: #+ATTR_LATEX: :caption \BiTableCaption{caption 1}{caption 2} |---+---| | x | y | |---+---| | 1 | 2 | |---+---| 0001-Add-caption-attribute-to-ATTR_LATEX-property.patch Description: Binary data
Re: [O] [RFC] Introduce ox-i18n.el
Nicolas Goaziou n.goaz...@gmail.com writes: I would like to move every variable and function related to internationalization (i.e smart quotes and translations) in a dedicated file (ox-i18n.el) instead of ox.el. Sounds good to me. How about a more informative name where uninformed need not look up the meaning of i18n on Wikipedia? ox-translation(s) or something like that. . . –Rasmus -- El Rey ha muerto. ¡Larga vida al Rey!
[O] auto pack empty space between headers?
Hi list i seem to get alot of times empty spaces between some org sections (between headers and sub-headers). I can manually to each sub heading and manually delete all empty lines at the end of the section. i was wondering if there was any command to auto pack empty space between headers? best Z
[O] auto pack empty space between headers?
Hi list does any one know of a way to auto insert and change the date in each sections header when the section is edited?IE have a date in the header showing last edited date. is this technically possible? best Z
Re: [O] Open Document Exporter
Hello Jambunathan! This works great for me, Thank You! Best Regards, Georg Lehner On 06/29/2013 02:43 PM, Jambunathan K wrote: I need time to review other issues you are raising. Georg Lehnerjorge-...@magma.com.ni writes: 4. LaTeX like definition lists Here is a patch and sample documents. You can pull from my private repo which is at http://repo.or.cz/w/org-mode/org-kjn.git
Re: [O] [PATCH] ox-html: Restore wrongly omitted table attributes under HTML5.
Hello, Kodi Arfer k...@arfer.net writes: From edd97671641e28c3e240efe6ea8fa8d77b4b7eae Mon Sep 17 00:00:00 2001 From: Kodi Arfer g...@arfer.net Date: Sat, 29 Jun 2013 10:43:07 -0400 Subject: [PATCH] ox-html: Restore wrongly omitted table attributes under HTML5. * lisp/ox-html.el (org-html-table): For HTML5, omit :html-table-attributes but not :id or :attr_html. Thank you for your patch. Could you rebase it against maint? I cannot apply it at the moment. +(unless (org-html-html5-p info) + (plist-get info :html-table-attributes)) One nitpick. It is more explicit to use: (and (not (org-html-html5-p info)) (plist-get info :html-table-attributes)) since you are using the returned value. Regards, -- Nicolas Goaziou
[O] [PATCH] (update) Add :caption attribute to #+ATTR_LATEX property
This is the updated patch of Add :caption attribute to #+ATTR_LATEX property If possible, please include it to master This feature is very useful when you export org to latex with custom caption command, for example: #+ATTR_LATEX: :caption \BiTableCaption{caption 1}{caption 2} |---+---| | x | y | |---+---| | 1 | 2 | |---+---| -- 0001-Add-caption-attribute-to-ATTR_LATEX-property.patch Description: Binary data
Re: [O] [PATCH] ox-html: Restore wrongly omitted table attributes under HTML5.
On 2013 Jun 29 Sat 6:37:33 PM -0400, Nicolas Goaziou n.goaz...@gmail.com wrote: Kodi Arfer k...@arfer.net writes: From edd97671641e28c3e240efe6ea8fa8d77b4b7eae Mon Sep 17 00:00:00 2001 From: Kodi Arfer g...@arfer.net Date: Sat, 29 Jun 2013 10:43:07 -0400 Subject: [PATCH] ox-html: Restore wrongly omitted table attributes under HTML5. * lisp/ox-html.el (org-html-table): For HTML5, omit :html-table-attributes but not :id or :attr_html. Thank you for your patch. Could you rebase it against maint? I cannot apply it at the moment. I don't think I can. I'm not clear about the relationship between maint and master in general, but it looks like maint doesn't have the bug my patch is supposed to fix, because it doesn't treat an HTML5 doctype specially at all. + (unless (org-html-html5-p info) +(plist-get info :html-table-attributes)) One nitpick. It is more explicit to use: (and (not (org-html-html5-p info)) (plist-get info :html-table-attributes)) since you are using the returned value. Sure, I can change that. Should I base the patch off master again?
Re: [O] [need help] How to add a caption to table with #+attr_latex :caption \bicaption{...}{...}
Rasmus ras...@gmx.us writes: Hi Feng, In my thesie, I need add a caption to table or figure with \bicaption{ä¸ææ é¢}{English title} I assume you'd still want to use the #+CAPTION-cookie, no? If so, one solution that comes to mind is writing captions like #+CAPTION: my-Asian-string (sorry about my ignorance) MYSPLIT my-English-string and write a filter using (org-split-string text MYSPLIT) and format it as (format \bicaption{%s}{%s} LIST) if the length is two. Org perhaps regexps could be used to identify 'my-Asian-string'. I'm not sure where to apply the filter, though, but a better solution than the one below would use `org-export-get-caption' on the correct elements at the correct time. . . --- #+caption: ä¸ææ é¢ #+caption: English Title | 1 | 2 | --- I think this is the best document construct, simple and intuitive. But, realizing this feature need some dirty hack, the main reason is that \bicaption often a custom latex command, fig caption and table caption are different in option, for example: \bicaption[å¾]{...}[fig]{...} \bicaption{å¾}{fig}{...}{...} \bicaption{...}{...} \bicaption[表]{...}[Table]{} ... Here's a dirty, inelegant regexp filter that's run on the final tex-string. #+begin_src emacs-lisp (defun org-latex-filter-split-caption (text backend info) When ## is present in a string make a bicaption. (when (org-export-derived-backend-p backend 'latex 'beamer) (replace-regexp-in-string caption{\\(.*?\\)[ \t]*##[ \t]+?\\(.*\\)} bicaption{\\1}{\\2} text) )) (add-to-list 'org-export-filter-final-output-functions 'org-latex-filter-split-caption) #+end_src It is a very useful tip, thanks! It will export this document 'correctly': #+begin_src org #+TITLE: my test doc #+CAPTION: - ## english title | 1 | 2 | 3 | #+CAPTION: english title | 2 | 3 | #+end_src Hope this inspires you to solve the problem in a more elegant manner. âRasmus --
[O] bug leading to duplicate subtrees
I finally found out how some duplicate subtrees are created: * test 1 * test 2 Refile test 1. Kill test 2. Move. Yank. You will yank both lines. To fix: make refiling not be an appendable kill. Thanks. Samuel -- The Kafka Pandemic: http://thekafkapandemic.blogspot.com The disease DOES progress. MANY people have died from it. ANYBODY can get it. Denmark: free Karina Hansen NOW.
Re: [O] Org mode and right-to-left paragraphs
Hi Bastien, Thank you for answering. Dov helped me figure out the issue that you point out. The workaround was simple. There is something very appealing (sexy?) about exporting documents with multilingual texts and literate programming code blocks. That keeps me on the optimistic side. Regards, Manuel GJT On Jun 27, 2013 10:11 AM, Bastien b...@gnu.org wrote: