From: Johannes Brauer <brauer@nordakademie.de>
To: John Kitchin <jkitchin@andrew.cmu.edu>
Cc: Bastien <bzg@gnu.org>, "emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: Re: equal syntax highlighting for publishing code blocks to html and pdf
Date: Sat, 29 Feb 2020 10:55:06 +0000 [thread overview]
Message-ID: <A7B10A2E-759D-4796-B9C1-7B38DFA6BF71@nordakademie.de> (raw)
In-Reply-To: <CAJ51ETosuMM5Z=kPM5Em_xvsKj7bKgrEXMwYCq+WYmQ9nCodNA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1885 bytes --]
In the meantime I figure out these two options, too. But I decided the effort seems to high for me. Especially as emacs an minted use different syntactic categories.
Johannes
Am 01.02.2020 um 14:50 schrieb John Kitchin <jkitchin@andrew.cmu.edu<mailto:jkitchin@andrew.cmu.edu>>:
My guess is you have two options:
1. Customize the colors in minted to match what is on your screen. I am pretty sure that code in html looks very much like what is on your screen. This might be an entry point to customizing minted style. https://tex.stackexchange.com/questions/131456/customize-comment-color-in-minted-style
2. Customize the faces emacs uses for syntax highlighting to match the look in minted.
either way, I don't see a simple way to have a common theme between them, and they will probably always have some minor differences. It might be easier to hack a new exporter for src blocks that turns the htmlized code into latex markup perhaps.
John
-----------------------------------
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<http://kitchingroup.cheme.cmu.edu/>
On Sat, Feb 1, 2020 at 4:28 AM Bastien <bzg@gnu.org<mailto:bzg@gnu.org>> wrote:
Hi Johannes,
Johannes Brauer <brauer@nordakademie.de<mailto:brauer@nordakademie.de>> writes:
> Frequently I publish org-mode documents containing source code blocks
> to html (htmlize) and pdf (minted). I would like to see the same
> colors in both export types. But
> I cannot figure out, what’s the best way to achieve this.
>
> Has anyone solved this problem? Are there any hints?
I don't know how to do this and I guess it's difficult.
If you find a solution, please mention it here, others may be
interested.
Thanks!
--
Bastien
[-- Attachment #2: Type: text/html, Size: 3772 bytes --]
next prev parent reply other threads:[~2020-02-29 10:55 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-26 18:34 equal syntax highlighting for publishing code blocks to html and pdf Johannes Brauer
[not found] ` <gtgq2ENI7XZ0oW25n6FBp-9xejE6p6qXvCyA4q6yI2vq4UjIAPMo3ZkKPYZv6_Ne8HmjbWBRGayPrX7D7CVUFA==@protonmail.internalid>
2020-02-01 9:28 ` Bastien
2020-02-01 13:50 ` John Kitchin
2020-02-29 10:55 ` Johannes Brauer [this message]
2020-02-01 14:53 ` Norman Tovey-Walsh
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=A7B10A2E-759D-4796-B9C1-7B38DFA6BF71@nordakademie.de \
--to=brauer@nordakademie.de \
--cc=bzg@gnu.org \
--cc=emacs-orgmode@gnu.org \
--cc=jkitchin@andrew.cmu.edu \
/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).