[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] html-email in org-mode
From: |
John Kitchin |
Subject: |
Re: [O] html-email in org-mode |
Date: |
Sun, 30 Oct 2016 17:45:21 -0400 |
User-agent: |
mu4e 0.9.16; emacs 25.1.50.1 |
Do you mean monospace in the whole html message, e.g. something like Courier?
Or just in a table? I do not think you can control the font in plain
text emails.
You can set the font in the td elements of a table like this (I used
cursive because it was easy to see.
#+BEGIN_SRC emacs-lisp
(defun italicize-table (data backend info)
(with-temp-buffer
(insert data)
(goto-char (point-min))
(while (re-search-forward "<td" nil t)
(replace-match "<td style=\"font-family:cursive;\""))
(message"got %s" (buffer-string))
(buffer-string)))
(add-to-list 'org-export-filter-table-functions 'italicize-table)
#+END_SRC
After you run that, the tables in html have italicized/cursive elements
in them. And probably all other exports to html too ;)
Eric Brown writes:
> John Kitchin <address@hidden> writes:
>
>> 1.1.3 Tables
>>
>> Table 1: A table for you.
>> x y
>> 1 2
>>
>
> Hi John,
>
> I haven't (yet) found the email thread that you had alluded to, but I
> think this post is awesome. Works well for me!
>
> One suggestion/thought:
>
> I would like to do is force monospace font in these messages, since the
> recipients I typically send to will have variable width fonts, and
> tables and the like tend to get messed up.
>
> How might this be done?
>
> Best regards,
> Eric
--
Professor John Kitchin
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
@johnkitchin
http://kitchingroup.cheme.cmu.edu