bug with hyperref/mdframed/TikZ/imakeidx with \fbox in section command
Heiko Oberdiek
heiko.oberdiek at googlemail.com
Tue Sep 14 18:35:13 CEST 2021
Hello,
On 2021-09-14 15:15, Patrice Dumas wrote:
> Hello,
>
> I found two bugs (I think) related to \fbox{} in section command
> (\chapter) in relatively precise cases in term of packages use,
> hyperref, mdframed with framemethod=TikZ and also imakeidx.
> The first case is with hyperref and mdframed with framemethod=TikZ and
> changing the order can prevent the failure. The message is
>
> ! Argument of \boxframe has an extra }.
> <inserted text>
> \par
> l.19 \chapter{chap \fbox{toto}}
Minimal example:
\documentclass{report}
\usepackage{tikz}
\usepackage{hyperref}
%\pdfstringdefDisableCommands{\let\fbox\relax}
\begin{document}
\chapter{Hello \fbox{World}}
\end{document}
Fix: Enable the line with \pdfstringdefDisableCommands.
This avoids the error with the redefinition of \fbox of TikZ
and warnings otherwise.
> The second case happens [...]
> l.23 \chapter{chap \fbox{toto}}
Maybe, this is fixed the same way as above.
Otherwise provide a minimal working example that shows the problem.
Yours sincerely
Heiko
More information about the texhax
mailing list.