From: Rasmus <rasmus@gmx.us>
To: emacs-orgmode@gnu.org
Subject: Re: Embedding diagrams in Org
Date: Wed, 04 Mar 2015 20:37:35 +0100 [thread overview]
Message-ID: <87lhjc1rls.fsf@gmx.us> (raw)
In-Reply-To: 874mq0d0zg.fsf@amu.edu.pl
Marcin Borkowski <mbork@wmi.amu.edu.pl> writes:
> Did anyone use the ability to inline tikz pictures (i.e., pictures in
> a file with =tikz= or =pgf= extension)? If so, could you share some
> examples, or at least success stories?
>
> Also, org-latex--inline-image seems to provide for including svg images,
> but I could not find a \usepackage{svg}, nor a provision for enabling
> shell-escape (like in the case of minted). Again: any success stories
> or is there a bug?
The following seem to work with pdflatex. You need svg and tikz from
CTAN. I use tikz frequently via matplotlib in Python and tikzDevice in R.
#+CAPTION: a svg drawing
[[file:circle.svg]]
#+CAPTION: a tikz drawing
[[file:fig.tikz]]
* assets :noexport:
#+BEGIN_SRC emacs-lisp
(org-babel-tangle)
#+END_SRC
#+RESULTS:
| fig.tikz | circle.svg |
#+LATEX_HEADER: \usepackage{tikz}
#+BEGIN_SRC latex :tangle fig.tikz
\begin{tikzpicture}
\node [draw=red,circle] at (0,0) {X};
\end{tikzpicture}
#+END_SRC
#+LATEX_HEADER: \usepackage{svg}
#+BEGIN_SRC html :tangle circle.svg
<svg xmlns="http://www.w3.org/2000/svg" width="200" height="200">
<circle r="100" cx="100" cy="100"></circle>
</svg>
#+END_SRC
--
Got mashed potatoes. Ain't got no T-Bone. No T-Bone
next prev parent reply other threads:[~2015-03-04 19:37 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-18 12:34 Embedding diagrams in Org Marcin Borkowski
2015-02-18 14:19 ` Eric S Fraga
2015-02-18 15:51 ` Eduardo Ochs
2015-02-18 19:01 ` Eric S Fraga
2015-02-19 8:45 ` Sebastien Vauban
2015-02-18 19:37 ` Andreas Leha
2015-02-19 8:49 ` Sebastien Vauban
2015-02-21 11:06 ` Andreas Leha
2015-02-19 14:10 ` Eric S Fraga
2015-03-21 11:23 ` Marcin Borkowski
2015-03-21 21:41 ` Andreas Leha
2015-02-24 0:01 ` Marcin Borkowski
2015-02-24 8:04 ` Eric S Fraga
2015-02-24 17:00 ` Charles C. Berry
2015-03-05 8:51 ` Sebastien Vauban
2015-03-04 19:19 ` Marcin Borkowski
2015-03-04 19:37 ` Rasmus [this message]
2015-03-04 21:22 ` Andreas Leha
2015-03-05 8:12 ` Eric S Fraga
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=87lhjc1rls.fsf@gmx.us \
--to=rasmus@gmx.us \
--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).