* [PATCH] ox-confluence.el: Add support for ordered list
@ 2016-12-08 5:35 Lungang Fang
0 siblings, 0 replies; only message in thread
From: Lungang Fang @ 2016-12-08 5:35 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1270 bytes --]
Hi there,
This is a patch for contrib/lisp/ox-confluence.el generated following
instructions on http://orgmode.org/worg/org-contribute.html#patches . It
adds support for ordered list.
--
Lungang Fang
* contrib/lisp/ox-confluence.el (org-confluence-item): Support ordered
list
When converting a bullet item, examine the type of it and convert
accordingly.
TINYCHANGE
---
contrib/lisp/ox-confluence.el | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/contrib/lisp/ox-confluence.el b/contrib/lisp/ox-confluence.el
index 5de9e0f..de8b00e 100644
--- a/contrib/lisp/ox-confluence.el
+++ b/contrib/lisp/ox-confluence.el
@@ -81,9 +81,12 @@
(format "_%s_" contents))
(defun org-confluence-item (item contents info)
- (concat (make-string (1+ (org-confluence--li-depth item)) ?\-)
- " "
- (org-trim contents)))
+ (let* ((plain-list (org-export-get-parent item))
+ (type (org-element-property :type plain-list))
+ (bullet (if (eq type `ordered) ?\# ?\-)))
+ (concat (make-string (1+ (org-confluence--li-depth item)) bullet)
+ " "
+ (org-trim contents))))
(defun org-confluence-fixed-width (fixed-width contents info)
(format "\{\{%s\}\}" contents))
--
2.9.3 (Apple Git-75)
[-- Attachment #2: Type: text/html, Size: 3594 bytes --]
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2016-12-08 5:36 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-08 5:35 [PATCH] ox-confluence.el: Add support for ordered list Lungang Fang
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).