Closed DurhamSmith closed 2 years ago
As a quick fix, would you consider using the standalone package in your setup? If haven't tested this, but my understanding is that if you include \usepackage{standalone}
in your main file, then you can use
\documentclass{standalone}
\begin{document}
...
\end{document}
in the files that you want to include
.
It probably wouldn't be too difficult to fix the behaviour of the addon, but now that people have been using it for years I'm a bit afraid of breaking other peoples' workflows by changing it.
I wrote a fix for this problem for Anki 2.1. Could you test this and see whether it works for you before I deploy it via Ankis website? You just need to copy the current version of lateximport.py
to your installation of the add-on. To find that installation, open Anki, go to Tools
> Add-ons
, select LatTeX Note Importer
and click on View Files
.
Marcus,
Thanks for the suggestion and fix. Both worked for me. I (quickly) tried some expected failure mode for the fix and it held up well. I will notify if I run into any issues with it. Appreciate the fast work and wonderful plugin.
D
First off thanks for the great tool.
I often write multiple .tex files and
\include{}
or\input{}
them. These files do not contain\begin{document}
and\end{document}
. This leads to a problem in importing them into anki, and the following error is reported:With included
\begin{document}
and\end{document}
the file is imported correctly. Would it be possible to remove the requirement for these tags for correct import?