emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Thomas S. Dye" <tsd@tsdye.com>
To: emacs-orgmode list <emacs-orgmode@gnu.org>
Subject: [PATCH] Emphasize caption in html output
Date: Sun, 28 Mar 2010 19:45:30 -1000	[thread overview]
Message-ID: <42A8856C-EF43-408A-8646-D386760175A7@tsdye.com> (raw)

Hi Carsten,

This appears to emphasize org-mode markup in html export of captions.   
It seems to work, but I have a difficult time understanding org-mode  
code and haven't any sense of the proper way to do things, etc., so  
caveat emptor.

All the best,
Tom

---------------
	Modified lisp/org-html.el
diff --git a/lisp/org-html.el b/lisp/org-html.el
index d75d8f5..71e3e99 100644
--- a/lisp/org-html.el
+++ b/lisp/org-html.el
@@ -1521,7 +1521,7 @@ lang=\"%s\" xml:lang=\"%s\">
    (save-match-data
      (if (string-match "^ltxpng/" src)
  	(format "<img src=\"%s\"/>" src)
-      (let* ((caption (org-find-text-property-in-string 'org-caption  
src))
+      (let* ((caption (org-export-html-convert-emphasize (org-find- 
text-property-in-string 'org-caption src)))
  	     (attr (org-find-text-property-in-string 'org-attributes src))
  	     (label (org-find-text-property-in-string 'org-label src)))
  	(concat
@@ -1599,11 +1599,11 @@ lang=\"%s\" xml:lang=\"%s\">
      ;; column and the special lines
      (setq lines (org-table-clean-before-export lines)))

-  (let* ((caption (or (get-text-property 0 'org-caption (car lines))
+  (let* ((caption (org-export-html-convert-emphasize (or (get-text- 
property 0 'org-caption (car lines))
  		      (get-text-property (or (next-single-property-change
  					      0 'org-caption (car lines))
  					     0)
-					 'org-caption (car lines))))
+					 'org-caption (car lines)))))
  	 (attributes (or (get-text-property 0 'org-attributes (car lines))
  			 (get-text-property (or (next-single-property-change
  						 0 'org-attributes (car lines))

             reply	other threads:[~2010-03-29  5:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-29  5:45 Thomas S. Dye [this message]
2010-03-29 11:39 ` [PATCH] Emphasize caption in html output Carsten Dominik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=42A8856C-EF43-408A-8646-D386760175A7@tsdye.com \
    --to=tsd@tsdye.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).