4

I am using biblatex with the biber backend for my bibliography. The problem I encountered is that margins are not always respected. It seems to be a fairly common issue, cf. these possibly related questions (answers do not apply as far as I can tell):

Repro code

I used the showframe package to help visualize the spilling.

\documentclass[12pt,draft]{report}
\usepackage{showframe}
\usepackage[backend=biber]{biblatex}

\begin{filecontents}{testbib.bib}
@article{cheng:ijrr:2004,
    author = {Cheng, Peng and LaValle, Steven M.},
    journal = {International Journal of Robotics Research},
    pages = {1--37},
    title = {{Resolution completeness for sampling-based motion planning with differential constraints}},
    year = {2004}
}
\end{filecontents}
\bibliography{testbib.bib}

\begin{document}

\cite{cheng:ijrr:2004}

\printbibliography

\end{document}

Reference spilling in margin

So how can I solve this? Who's the culprit here? Is there workaround for this issue?

BenC
  • 549

1 Answers1

5

As @Johannes_B pointed out, the issue is with the hyphenation. Possible workarounds involve \raggedright (see No hyphens in biblatex) or \sloppy (see Hyphenation in bibliography with Biblatex).

With \appto{\bibsetup}{\raggedright}:

enter image description here

With \appto{\bibsetup}{\sloppy}:

enter image description here

BenC
  • 549
  • or directly write samp-ling, or maybe sam-pling in your bib file. – pluton Jan 15 '16 at 09:36
  • In this particular case the problem is that words already containing a hyphen cannot be hyphenated anywhere except at the hyphen. So sampling-based only breaks at the -. It may already help to add the possible break-points sampling and based back in manually. See also https://tex.stackexchange.com/q/2706/35864, https://tex.stackexchange.com/q/63232/35864. (This is mentioned in the comments under the question that this answer refers to, but it might still be good to have it mentioned here explicitly.) – moewe Aug 02 '21 at 06:34
  • For more help on general line breaking problems, see https://tex.stackexchange.com/q/442308/35864 – moewe Aug 02 '21 at 06:35