From f46083a40c9a6a9aa92f8883115087e28a806169 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Thu, 31 Oct 2019 14:26:21 -0600 Subject: [PATCH] LaTeX output: \protect before \colorbox Avoid problems when `\colorbox` ends up in a section title. --- scribble-lib/scribble/scribble.tex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scribble-lib/scribble/scribble.tex b/scribble-lib/scribble/scribble.tex index 1905e892..249fa4e7 100644 --- a/scribble-lib/scribble/scribble.tex +++ b/scribble-lib/scribble/scribble.tex @@ -83,8 +83,8 @@ \newcommand{\textsuper}[1]{$^{\hbox{\textsmaller{#1}}}$} \newcommand{\intextcolor}[2]{\textcolor{#1}{#2}} \newcommand{\intextrgbcolor}[2]{\textcolor[rgb]{#1}{#2}} -\newcommand{\incolorbox}[2]{{\fboxrule=0pt\fboxsep=0pt\colorbox{#1}{#2}}} -\newcommand{\inrgbcolorbox}[2]{{\fboxrule=0pt\fboxsep=0pt\colorbox[rgb]{#1}{#2}}} +\newcommand{\incolorbox}[2]{{\fboxrule=0pt\fboxsep=0pt\protect\colorbox{#1}{#2}}} +\newcommand{\inrgbcolorbox}[2]{{\fboxrule=0pt\fboxsep=0pt\protect\colorbox[rgb]{#1}{#2}}} \newcommand{\plainlink}[1]{#1} \newcommand{\techoutside}[1]{#1} \newcommand{\techinside}[1]{#1}