Bonds not displayed
alexander-schoch-github opened this issue · 3 comments
alexander-schoch-github commented
kilacoda commented
alexander-schoch-github commented
Of course I forgot the minus sign...
corresponding .tex
-file:
\documentclass[preview]{standalone}
\usepackage[english]{babel}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{dsfont}
\usepackage{setspace}
\usepackage{tipa}
\usepackage{relsize}
\usepackage{textcomp}
\usepackage{mathrsfs}
\usepackage{calligra}
\usepackage{wasysym}
\usepackage{ragged2e}
\usepackage{physics}
\usepackage{xcolor}
\usepackage{microtype}
\usepackage{tikz}
\usetikzlibrary{arrows}
\usetikzlibrary{shapes.geometric}
\usepackage{chemfig}
\usepackage{mhchem}
\DisableLigatures{encoding = *, family = * }
%\usepackage[UTF8]{ctex}
\linespread{1}
\begin{document}
\begin{align*}
\setchemfig{atom sep = 2em}
\chemfig{-[:30](=[2]O)-[:-30]OH}
\end{align*}
\end{document}
I don't see anything wrong with it at a short glance.
alexander-schoch-github commented
Update: After some messing around, I found out that the compilation from .dvi
to .svg
failed. This issue could be resolved by using \documentclass[preview,dvisvgm]{standalone}
in the preamble. Now, the .svg
file is generated correctly.
However, afterwards, this .svg
file is not inserted into the video/image correctly, as seen here (code below):
This appears to be a general manim problem, though, which is why I opened an issue on 3b1b/manim
.
As this problem does not occur in your case, I am assuming that it only happens on linux-based operating systems.
Code for image above:
from manimlib.imports import *
class TikzMobject(TextMobject):
CONFIG = {
"stroke_width": 3,
"fill_opacity": 0,
"stroke_opacity": 1,
}
class ExampleTikz(Scene):
def construct(self):
circuit = TikzMobject(r"""
\begin{tikzpicture}
\draw (0,0) -- (1,0);
\node at (1,0) {sometext};
\end{tikzpicture}
"""
)
self.play(Write(circuit))
self.wait()