all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Lawrence Bottorff <borgauf@gmail.com>
To: emacs-orgmode Mailinglist <emacs-orgmode@gnu.org>
Subject: Import and run tizk code in org-mode
Date: Fri, 13 Jan 2017 08:37:35 -0500	[thread overview]
Message-ID: <CAFAhFSXz5bEzb3Z1-NuhD5+qPKBsnrmaBGupbFeuOtEri8F0dg@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1399 bytes --]

If I have an org-mode file where I want to embed a TikZ rendering at a
certain place, I've found the simplest is just to throw something like this
in where you want it, i.e., no latex code block necessary:

\begin{figure}
    \centering
    \newlength\figureheight
    \newlength\figurewidth
    \setlength\figureheight{6cm}
    \setlength\figurewidth{8cm}
    \input{x2vxlogx.tikz}
    %\caption{A graph}
    %\label{fig:graph}
\end{figure}

Works just fine. The whole motivation of . . .\imput{mytikzfile} being, the
.tikz code can be huge (e.g., GeoGebra sometimes coughs up massive TikZ
code brute-force-style), i.e., you don't want your orgmode file thousands
of lines longer just for a single tikz image. But in order to have it work,
I've had to change my file headers, i.e., before I had

#+OPTIONS: tex:t

this makes MathJax work, but the above tex code import not

versus

#+OPTIONS: tex:imagemagick

This makes MathJax not work, but the tex code import work. Is there anyway
to get both, i.e., have my math done by MathJax and my tikz file import
work too? I could leave it with #+OPTIONS: tex:imagemagick, but then my
math formulae are done as little pngs, which line up poorly on the page.

If no one knows a quick answer, fine. I'm coming to believe TikZ and
orgmode is just too heroic a struggle for an irregular like me. Better to
simply embed ready-made pngs and call it a day.

LB

[-- Attachment #2: Type: text/html, Size: 1784 bytes --]

             reply	other threads:[~2017-01-13 13:37 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-13 13:37 Lawrence Bottorff [this message]
2017-01-13 15:13 ` Import and run tizk code in org-mode Nick Dokos

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAFAhFSXz5bEzb3Z1-NuhD5+qPKBsnrmaBGupbFeuOtEri8F0dg@mail.gmail.com \
    --to=borgauf@gmail.com \
    --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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.