Ok, this is a pretty strange problem based on a workaround suggested here: Reference name of description list item in LaTeX
I am trying to hyperlink/refer back to descriptions by their name in this paper, but for some reason the formatting sometimes adds a number of spaces after the name of the description, making for ugly long red boxes.
Here is some code that compiles this way. I left all my packages in to see if anyone can guess complications from that:
\documentclass[12pt]{article}
\usepackage{lingmacros,
amssymb,
setspace,
units,
tabto,
array,
nameref,
enumitem,
footnote,
cite,
changes,
epigraph}
\usepackage[square,sort,comma]{natbib}
\usepackage[margin=1in]{geometry}
\usepackage[utf8]{inputenc}
\usepackage{hyperref}
%----------- Command to make description Labels
\makeatletter
\let\orgdescriptionlabel\descriptionlabel
\renewcommand*{\descriptionlabel}[1]{%
\let\orglabel\label
\let\label\@gobble
\phantomsection
\edef\@currentlabel{#1}%
%\edef\@currentlabelname{#1}%
\let\label\orglabel
\orgdescriptionlabel{#1}%
}
\makeatother
%---------- This is a new draft toggle to turn of sections with \ifdraft
\newif\ifdraft
%opening
\title{Group Skepticism}
\author{}
\begin{document}
\maketitle
\begin{description}
\item [NSC\label{NSC}] No true theory of testimonial evidence is inconsistent with the extent of testimonial evidence clear critical common sense says that we have.
\end{description}
The second assumption is a transmission principle. Jennifer Lackey clarifies the discussion about these principles by giving the following proposal.
\begin{description}
\item[TEP-N\label{TEP-N}] For every speaker, S, and hearer, A, A knows (believes with justification/warrant/ has evidence\footnote{The `has evidence that' condition is not found in Lackey, but having evidence will feature prominently in the discussion below, so I have included it here.}) that p on the basis of S’s testimony that p only if S knows (believes with justification/warrant/ has evidence) that p.
\end{description}
Though Lackey argues against this transmission principle, \ref{TEP-N} and principles like it have not completely fallen out of fashion. Such transmission principles could provide the needed link from individual epistemology to group epistemology. If we assume that learning something entails being justified in believing it and that 2 is a common sense instance of learning, we can infer from \ref{TEP-N} and \ref{NSC} that Wikipedia believes with justificaiton that Abraham Lincoln died on April 15, 1865. Hence, groups have epistemic states.
\end{document}
This is not the worst example but it shows how sometimes the spacing is right and sometimes it is off, especially in the first line of a paragraph. In case this compiles fine for you, here is the worst this looks in my paper:
Any ideas?
\usepackage{foo,bar,foobar}
list -- it's allowed, but it looks weird. Also load 'hyperref` as the last package here!enumitem
is the culprit here or the redefinition of the description labelenumitem
, the extra spaces disappear.\item
command here, since it wraps a 'faulty`enit@align
around the \item [foo]` arg