From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Doyley, Marvin M." Subject: Re: New markup for revising manuscripts Date: Mon, 13 Mar 2017 17:25:44 +0000 Message-ID: <30057CD2-C4B3-4C69-B807-2D6D5F3FDECF@ur.rochester.edu> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="Apple-Mail=_9081D086-56D6-4783-B29E-6B374EC3C302"; protocol="application/pgp-signature"; micalg=pgp-sha512 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:58310) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cnTjE-00082G-QX for emacs-orgmode@gnu.org; Mon, 13 Mar 2017 13:25:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cnTj9-0006IU-O4 for emacs-orgmode@gnu.org; Mon, 13 Mar 2017 13:25:52 -0400 Received: from mail-sn1nam02on0123.outbound.protection.outlook.com ([104.47.36.123]:56768 helo=NAM02-SN1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cnTj9-0006ID-Bh for emacs-orgmode@gnu.org; Mon, 13 Mar 2017 13:25:47 -0400 Content-Language: en-US List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Eric S Fraga Cc: "emacs-orgmode@gnu.org" , John Kitchin --Apple-Mail=_9081D086-56D6-4783-B29E-6B374EC3C302 Content-Type: multipart/alternative; boundary="Apple-Mail=_9388BE24-062F-4D46-8332-4E770B76FB79" --Apple-Mail=_9388BE24-062F-4D46-8332-4E770B76FB79 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Hi Eric, I really appreciate this. I will try it out too. Cheers, M On Friday, 10 Mar 2017 at 20:33, Doyley, Marvin M. wrote: > Hi there, > > When revising manuscripts, I usually highlight the changes (response > to reviewer) in red. I use typically do this as follows: > (1) #+latex_header: \newcommand{\response}[1]{\textcolor{red}{#1}} > (2) \response{changes) > > Is there a more elegant way to do this ? I don't know about elegant but my approach is to subvert the +...+ emphasis markers. These usually indicate strike-through, something I never use. Instead, I have +some text+ be highlighted and exported to LaTeX and HTML as such. To achieve this, I customise a number org variables. It took me some time to find how I actually did this as it's been part of my org setup for years, so much so that I almost thought it was default behaviour! In any case, the following is an elided extract from my customised variables: #+begin_src emacs-lisp (custom-set-variables '(org-emphasis-alist (quote (("*" bold) ("/" italic) ("_" underline) ("=3D" org-verbatim verbatim) ("~" org-code verbatim) ("+" highlight)))) '(org-html-text-markup-alist (quote ((bold . "%s") (code . "%s") (italic . "%s") (strike-through . "%s") (underline . "%s") (verbatim . "%s")))) '(org-latex-text-markup-alist (quote ((bold . "\\textbf{%s}") (code . protectedtexttt) (italic . "\\emph{%s}") (strike-through . "\\hl{%s}") (underline . "\\uline{%s}") (verbatim . protectedtexttt))))) #+end_src There are basically copies of the defaults with the strike-through element changed. Now I can write +highlighted text+ which appears as you wish in both HTML and LaTeX exports as well as on the screen (customise the highlight face to get what you want on screen). For LaTeX, you also have to (add-to-list 'org-latex-packages-alist '("" "soul")) --Apple-Mail=_9388BE24-062F-4D46-8332-4E770B76FB79 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset=us-ascii
Hi Eric,

I really appreciate this. I will try it out too.

Cheers,
M
On Friday, 10 Mar 2017 at 20:33, Doyley, Marvin M. wrote:
> Hi there,
>
> When revising manuscripts, I usually highlight the changes (response
> to reviewer) in red. I use typically do this as follows:
> (1) #+latex_header: \newcommand{\response}[1]{\textcolor{red}{#1}}
> (2) \response{changes)
>
> Is there a more elegant way to do this ?

I don't know about elegant but my approach is to subvert the +...+
emphasis markers.  These usually indicate strike-through, something I
never use.  Instead, I have +some text+ be highlighted and exported to
LaTeX and HTML as such.

To achieve this, I customise a number org variables.  It took me some
time to find how I actually did this as it's been part of my org setup
for years, so much so that I almost thought it was default behaviour!
In any case, the following is an elided extract from my customised
variables:

#+begin_src emacs-lisp
  (custom-set-variables
   '(org-emphasis-alist
     (quote
      (("*" bold)
       ("/" italic)
       ("_" underline)
       ("=" org-verbatim verbatim)
       ("~" org-code verbatim)
       ("+" highlight))))
   '(org-html-text-markup-alist
     (quote
      ((bold . "<b>%s</b>")
       (code . "<code>%s</code>")
       (italic . "<i>%s</i>")
       (strike-through . "<span style=\"background-color: #ffff80;\">%s</span>")
       (underline . "<span class=\"underline\">%s</span>")
       (verbatim . "<code>%s</code>"))))
   '(org-latex-text-markup-alist
     (quote
      ((bold . "\\textbf{%s}")
       (code . protectedtexttt)
       (italic . "\\emph{%s}")
       (strike-through . "\\hl{%s}")
       (underline . "\\uline{%s}")
       (verbatim . protectedtexttt)))))
#+end_src 

There are basically copies of the defaults with the strike-through
element changed.

Now I can write +highlighted text+ which appears as you wish in both
HTML and LaTeX exports as well as on the screen (customise the highlight
face to get what you want on screen).  For LaTeX, you also have to

  (add-to-list 'org-latex-packages-alist '("" "soul"))

--Apple-Mail=_9388BE24-062F-4D46-8332-4E770B76FB79-- --Apple-Mail=_9081D086-56D6-4783-B29E-6B374EC3C302 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQEcBAEBCgAGBQJYxtYXAAoJEMSux/2CXSY9VioH/R1AswMc/QjT2Jb2cD2ckvjG jYlPterzYf4eYTuWLRvTb8IwH9OeiuOZ05YRFVQVz/4PRCHE8QZ6Sck1ziL3jocA R59Vl3ywN33WTY37+jPTopTdA1mZEHMt0nnfOekk8IGdKGfM0u38wKZal3/YgYeQ OIHEXmPaymmeL5veL6MRDMcULkSlNa9dNrDS2OKs67rMduUUHBmRb35L6Prc4x53 Z3SDi+oM4GAcYhfCLsNQovnUYCfeoff3O3klOuiYugWAN9Q9Ym22CEJrLmwqiCaV gOnmZWKTTs+ktaG4T8pE691FsignpoDvQ72/sKjfWyez+3pe+atmbBfcXIs5cwI= =+5Sy -----END PGP SIGNATURE----- --Apple-Mail=_9081D086-56D6-4783-B29E-6B374EC3C302--