From: Jens Lechtenboerger <lechten@wi.uni-muenster.de>
To: Marcin Borkowski <mbork@mbork.pl>
Cc: Org-Mode mailing list <emacs-orgmode@gnu.org>
Subject: Re: How to tell `org-html-link' to create a link with some HTML class?
Date: Tue, 20 Jun 2023 08:07:47 +0200 [thread overview]
Message-ID: <87sfamll8s.fsf@wi.uni-muenster.de> (raw)
In-Reply-To: <87jzvyeoci.fsf@mbork.pl> (Marcin Borkowski's message of "Tue, 20 Jun 2023 06:42:37 +0200")
On 2023-06-20, Marcin Borkowski wrote:
> Dear Orgers,
>
> as I mentioned some time ago, I'm writing a custom exporter (actually,
> a very thin wrapper around the HTML exporter). I'd like `org-html-link'
> to add some class to the links it generates. Is that possible?
Dear Marcin,
yes, that’s possible, ":attr_html" is read in `org-html-link'. You
have to set that in your code, see [1] for an example for classes in
my reveal.js backend.
Briefly, with `elem' being the link, I use this:
`(org-element-put-property elem :attr_html (list newattrs))'
Best wishes
Jens
[1] https://gitlab.com/oer/org-re-reveal/-/blob/master/org-re-reveal.el#L2167
next prev parent reply other threads:[~2023-06-20 6:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-20 4:42 How to tell `org-html-link' to create a link with some HTML class? Marcin Borkowski
2023-06-20 6:07 ` Jens Lechtenboerger [this message]
2023-06-20 15:20 ` Marcin Borkowski
2023-06-20 16:30 ` Max Nikulin
2023-06-21 19:17 ` Marcin Borkowski
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=87sfamll8s.fsf@wi.uni-muenster.de \
--to=lechten@wi.uni-muenster.de \
--cc=emacs-orgmode@gnu.org \
--cc=mbork@mbork.pl \
/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).