2

I'd like to write a reaction mechanics in Latex, but the output differs from what I expected.

\documentclass{jlreq}
\usepackage[dvipdfmx]{graphicx}
\usepackage{chemfig}

\usetikzlibrary{calc}

\begin{document}
\schemestart \chemfig{@{a}A-@{b}B} \arrow{->[\chemfig{@{h}H^{+}}]} \chemfig{A} + \chemfig{B} \schemestop \chemmove{ \draw($(a)!0.5!(b)$)..controls +(90:5mm) and +(90:5mm)..(h); } \end{document}

Below is the output(black) and what I want to write(red). All I know is this occurs when the start/end point of the curve arrow is above the straight arrow.enter image description here

  • 2
    You are presumably using platex+dvipdfmx. If I change the class to article so I can use latex, it gives the same wrong output with latex+dvipdfmx , if I delete [dvipdfmx] and use pdflatex, it works. So possibly an error in the dvipdfmx back end file, (no time to look now but leaving a comment in case others are checking) – David Carlisle Jul 16 '21 at 08:21
  • Testing using XeLaTeX (to force dvipdfmx as a backend easily), I see the issue. As @DavidCarlisle says, it's likely a fault in the backend files for pgf, which is being used for the drawing. – Joseph Wright Jul 16 '21 at 08:41
  • @JosephWright I think it is this problem https://tex.stackexchange.com/questions/229500/tikzmark-and-xelatex – Ulrike Fischer Jul 16 '21 at 09:31
  • @DavidCarlisle Thanks to you, I succeeded to print what I want to write with pdflatex. However, I'm writing a document in Japanese and pdflatex can't deal with Japanese. I guess the best way is making a small size of pdf file of the figure and pasting it on the main tex file, do you know if it is possible or not? I couldn't find any information about the way. – someone who likes chemistry Jul 17 '21 at 10:55
  • yes you could do it as a separate file or you could perhaps use luatex which has some support for Japanese or you could use platex and dvips rather then dvipdfmx – David Carlisle Jul 17 '21 at 10:57
  • @DavidCarlisle I tried with LuaLatex but it didn't work. In addition, I'm not sure how to make the proper size of figure file. I think I make an A4 size of file when I normally try to make it. I'm really sorry for my ignorance. – someone who likes chemistry Jul 17 '21 at 11:05

0 Answers0