[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Chemfig Latex compile program



Hi,

When I updated the system, the following .tex code does not work, it shows the error likes this:

(/usr/share/texlive/texmf-dist/tex/latex/chemformula/chemformula.sty
(/usr/share/texlive/texmf-dist/tex/latex/l3packages/xfrac/xfrac.sty
(/usr/share/texlive/texmf-dist/tex/latex/base/textcomp.sty)
(/usr/share/texlive/texmf-dist/tex/latex/l3packages/xtemplate/xtemplate.sty))
(/usr/share/texlive/texmf-dist/tex/latex/units/nicefrac.sty
(/usr/share/texlive/texmf-dist/tex/latex/base/ifthen.sty)))
! Undefined control sequence.
l.24 \setdoublesep
                  {0.2 em}  % 'Bond Spacing'



\NeedsTeXFormat{LaTeX2e}[1997/12/01]
\documentclass[
    journal=jacsat,
    manuscript=article
    ]{achemso}

\usepackage[version=3]{mhchem}
\usepackage{wrapfig}
\usepackage{subfig}
\usepackage{graphicx}
\usepackage{threeparttable}
\usepackage{longtable,booktabs}
\usepackage[table, svgnames, dvipsnames]{xcolor}
\usepackage[first=0,last=9]{lcg}


\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{chemfig,chemmacros}
%\chemsetup[chemformula]{format=\sffamily}
\usepackage{chemformula}
\renewcommand*\printatom[1]{\ensuremath{\mathsf{#1}}}

\setdoublesep{0.2 em}  % 'Bond Spacing'
\setatomsep{1.45 em}    % 'Fixed Length'
\setbondoffset{0.1 em} % 'Margin Width'
\newcommand{\bondwidth}{0.08 em} % 'Line Width'
\setbondstyle{line width = \bondwidth}
\setcrambond{2pt}{}{}

\usetikzlibrary{decorations}
\pgfdeclaredecoration{ddbond}{initial}{
  \state{initial}[width=4pt]{
    \pgfpathlineto{\pgfpoint{4pt}{0pt}}
    %\pgfpathmoveto{\pgfpoint{2pt}{2pt}}
    \pgfpathmoveto{\pgfpoint{1pt}{2pt}}
    \pgfpathlineto{\pgfpoint{2pt}{2pt}}
   \pgfpathmoveto{\pgfpoint{3pt}{2pt}}
    \pgfpathlineto{\pgfpoint{4pt}{2pt}}
    \pgfpathmoveto{\pgfpoint{4pt}{0pt}}
  }
  \state{final}{
    \pgfpathlineto{\pgfpointdecoratedpathlast}
  }
}


\begin{document}

\end{document}

Reply to: