Closed zhantyzgz closed 4 months ago
Thanks for raising the issue! Okay, I think I understand the problem. I don't understand completely how to use \mmzUnmemoizable
, however. Should the command just go inside the tikzpicture
environment?
Yes, that is right. I have done a quick test and it seems to work fine.
When writing a presentation, it is often helpful to externalize the figures so that they don't get recompiled each time. One modern way to do this is with the Memoize package (https://github.com/sasozivanovic/memoize). But some elements such as progress bars are not well-suited for memoization, since they depend on external factors to compute the lengths.
Currently, trying to use Moloch and Memoize together results in auto-memoization of the progress bars, which is undesirable. In practice, this means that each progress bar in the document is filled to the same amount.
Both Metropolis and Moloch already disable the TikZ externalization library, in the beamer templates for
title separator
,progress bar in section page
, andprogress bar in head/foot
. It suffices to add\mmznext(disable}
to their definition. Currently, one solution for the end-user is to input the following into the preamble of their document, after loading Moloch.Of course, should it be implemented in this way, Moloch should also
\providecommand{\mmznext}{}
, like it already does for\tikzexternalenable
and\tikzexternaldisable
. According to Memoize's documentation, using\RequirePackage{memoizable}
works, too.But I think a theoretical better way would be to input
\mmzUnmemoizable
in the code of each relevanttikzpicture
, since this should also prevent the use of any previously memoized progress bars. I have not tested this yet, though.