emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[O] TikZ (circuitikz) and org-preview-latex-fragment don't play nicely t


From: Mark Edgington
Subject: [O] TikZ (circuitikz) and org-preview-latex-fragment don't play nicely together
Date: Tue, 10 Dec 2013 10:37:33 -0500

Hello everyone,

Assume I have an org-mode file that contains the following:

----------------------

#+OPTIONS: tex:imagemagick
#+LaTeX_HEADER: \usepackage[siunitx]{circuitikz}

* Test circuit
#+begin_lateX
    \begin{circuitikz}[scale = 1.0] \draw
        (0,0) node[anchor=east]{$V_{in} -$}
        to[short, o-] (4,0)
        to[V, v_=$V_{s}(t)$] (4,2)
        to[L, l_=$L_m$] (2,2)
        to[R, l_=3<\kilo\ohm>] (1,2) -- (0,2)
        to[short, o-] (0,2)
        node[anchor=east]{$V_{in} +$};
    \end{circuitikz}
#+end_latex

--------------------

If my current emacs color-theme background is black, running
org-preview-latex-fragment on the latex block results in all
electrical-elements being invisible (only labels and lines are
visible).  The only (poor) workaround I have for this is to add the
configuration option:

#+LaTeX_HEADER: \tikzset{every picture/.style={color=gray}}

Which means that I can barely see the picture when previewed in emacs,
and that it appears in gray on the exported PDF instead of black.

Is there any way that I can make it so that without a lot of "hacks" I
can make the previews appear as white-on-black, and the PDFs print
black on white?  Would something need to change with how org-mode
handles previewing to make this possible?

Regards,

Mark



reply via email to

[Prev in Thread] Current Thread [Next in Thread]