1

This is essentially an expansion on my earlier problem (Chemfig curved arrows in the wrong place) to which I have found a fix, but not really a solution.

I made a document using a header file which I called in my main document with \include{chem-hdr}. Here is what this file looks like:

% LaTeX header file for chemistry

% Packages \usepackage{chemfig} \usepackage[version=4]{mhchem} \usepackage{siunitx}

% Chemfig settings \setchemfig{atom sep=2em}

% Print atoms with a sans-serif font \renewcommand*\printatom[1]{% \ensuremath{\mathsf{#1}}% }

This would cause any curly arrows to be placed beside my reaction scheme, instead of inside. In this incomplete reaction scheme, the arrow should be on the aldehyde.

incomplete reaction scheme

Now with the background covered here's my actual problem:

In my earlier question, I did not specify that I used a header file; instead, I just pasted the header-file code into the MWE. I assumed this would make no difference. But it does!

Replacing the \include{chem-hdr} line in my preamble with the actual code in the file makes everything work as expected. Would anyone happen to know why?

Thanks all.

ajzcole
  • 31

0 Answers0