Skip to content

Commit

Permalink
Fix the chemical equation.
Browse files Browse the repository at this point in the history
  • Loading branch information
cedounet committed Jan 21, 2025
1 parent d994342 commit be63126
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
14 changes: 14 additions & 0 deletions book/tex4ebook.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,18 @@
font-family: 'Open Sans';
}
</style>}}

% Deal with chemical equations in a single svg
\ExplSyntaxOn
\def\standaloneenv#1{}
\pend:def\schemestart{\Picture+{}}
\append:def\CF_schemestop{\EndPicture}
\ExplSyntaxOff
\makeatletter
\def\texfourht@tikz@begin{
\protect\csname nested:math\endcsname% support display math
\Picture+[\csname a:Picture-alt\endcsname]{}%
}
\makeatother

\EndPreamble
12 changes: 12 additions & 0 deletions book/website.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -47,5 +47,17 @@
}
\ConfigureToc{loc}{\HCode{<span class="lofToc">}}{\ }{}{\HCode{</span><br />}}

\ExplSyntaxOn
\def\standaloneenv#1{}
\pend:def\schemestart{\Picture+{}}
\append:def\CF_schemestop{\EndPicture}
\ExplSyntaxOff
\makeatletter
\def\texfourht@tikz@begin{
\protect\csname nested:math\endcsname% support display math
\Picture+[\csname a:Picture-alt\endcsname]{}%
}
\makeatother

\begin{document}
\EndPreamble

0 comments on commit be63126

Please sign in to comment.