
\iupac
명령 을 사용할 때 LaTeX가 이름과 위치를 분할할 수 있다는 것을 알 수 있도록 chemmacros
다음과 같은 작업을 수행할 수 있습니다 . \ch{1,2\-dimethyl|really|long|name}
그러나 매우 긴 공식이 있는 경우 \ch{UO2}
(하위 패키지에서 chemformula
) 명령에는 설명서에 나열된 옵션이 없습니다(그리고 이미 |를 시도했습니다). 긴(45자) 화학식을 분해할 수 있는 방법이 있나요?
MWE:
\documentclass[letterpaper]{article}
%\usepackage[left = 1.5 in, right = 1.5 in]{geometry}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[language=british]{chemmacros}
\chemsetup[iupac]{coord-use-hyphen=true} %Puts hypens after bridging and hapto
%misc
%Load last stuff.
\begin{document}
This works See, it breaks at where I tell it to: \iupac{methyl|phenyl|piperidin|yl|acetate}
Here is a chemical formula: \ch{Cu(NCMe)2(pyz)[AuCl2(CN)2]2UO2(NO3)2}
Here is that same chemical formula with a bunch of filler text: \ch{Cu(NCMe)2(pyz)[AuCl2(CN)2]2UO2(NO3)2}
Here is that same chemical formula with a bunch of filler text: \ch{Cu(NCMe)2(pyz)|[AuCl2(CN)2]|2UO2(NO3)2}
Here is that same chemical formula with a bunch of filler text: \ch{Cu(NCMe)2(pyz) [AuCl2(CN)2] 2UO2(NO3)2}
Note a complete lack of this working despite spaces and such.
The one way I've seen it work is (filler text filler text) \ch{Cu(NCMe)2(pyz)[AuCl2(CN)2] * 2 MeCN}
\end{document}
답변1
이것이 올바른 방법인지는 확실하지 않지만, 작동합니다!
줄 바꿈을 허용하는 새 속성을 추가합니다. 저는 두 가지를 제안합니다. 하나는 구분만 허용하는 것이고 다른 하나는 하이픈도 추가하는 것입니다. 골라보세요.
\documentclass[letterpaper]{article}
%\usepackage[left = 1.5 in, right = 1.5 in]{geometry}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[language=british]{chemmacros}
\chemsetup[iupac]{coord-use-hyphen=true} %Puts hypens after bridging and hapto
\NewChemCompoundProperty{|}{\linebreak[0]}
\NewChemCompoundProperty{?}{\-}
%misc
%Load last stuff.
\begin{document}
This works See, it breaks at where I tell it to: \iupac{methyl|phenyl|piperidin|yl|acetate}
Here is a chemical formula: \ch{Cu(NCMe)2(pyz)[AuCl2(CN)2]2UO2(NO3)2}
Here is that same chemical formula with a bunch of filler text:
\ch{Cu(NCMe)2 | (pyz) | [AuCl2(CN)2]2 | UO2(NO3)2}
Here is that same chemical formula with a bunch of filler text:
\ch{Cu(NCMe)2 ? (pyz) ? [AuCl2(CN)2]2 ? UO2(NO3)2}
\end{document}