1

If I don't use hyperref package everything's fine, but if I use it, after a while a message appears with something like "Command dvilualatex "filename.tex" has not yet completed. Do you want to stop it?" and I don't get my pdf. I use Lualatex.
These are the packages that I use:

\usepackage[version=3]{mhchem}
\usepackage{fancyhdr}
\usepackage{colortbl}
\usepackage{caption}
\usepackage{varwidth}
\usepackage[breaklinks,colorlinks=true,linkcolor=red,citecolor=red, urlcolor=blue]{hyperref}
  • What \documentclass are you using? – Werner Oct 18 '13 at 21:49
  • 2
    If you're using a recent version of LyX, it has native support for hyperref. Check Document -> Settings... -> PDF Properties. – juliohm Oct 18 '13 at 23:40
  • 1
    Do you really use dvilualatex, that is lualatex with dvi output? Imho this doesn't make much sense as there is no sensible driver to handle the dvi. – Ulrike Fischer Oct 19 '13 at 11:09
  • I'm on version 2.0.6 and I use article as class. Ulrike, to be honest I have no idea of what I'm using, I just press View PDF (LuaTeX)... It doesn't work even if I check the option in PDF properties. – Arch Stanton Oct 19 '13 at 12:46
  • If I try to export it as a pdf with lualatex, the message is "The command lualatex "filename.tex"..." No mention of dvi but still no pdf either. – Arch Stanton Oct 19 '13 at 13:05
1

This is due to conflict of mhchem and hyperref packages. The hyperref package seems not be able to handle titles (section, subsection...) that contain the \ce{} command.

A temporary solution is:

\section[title H$_2$O]{title \ce{H2O}}

This keeps the H2O in the title in the font of \section (bold, bigger), while hyperref still functions (for putting the tile in TOC for example).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.