1

I am trying to properly break some of the url in my references. When using \usepackage[breaklinks]{hyperref}, the url breaks but the link disappear (not clickable) even though the blue color is still present. I tried various combinations of the url and hyperrefpackages with their options, I still face the same issue : either the url does not break, or the link disapper.

As my file includes PostScript files, I have to compile through DVI->PS->PDF.It seems the problem comes mainly from here, as compiling the MWE directly to PDF works. I use TeXStudio.

EDIT: shorter MWE, clarification of the issue. The use of breakurl or url packages don't break the url.

\documentclass[aps, reprint,prmat,twocolumn]{revtex4-1}

\usepackage[breaklinks]{hyperref}
\hypersetup{
colorlinks=true,
linkcolor=blue,
citecolor=blue,
urlcolor=blue,}

\begin{document}
Short citation\cite{takeda_visualization_2005}. Long citation\cite{LandoltBornstein2002}

\bibliography{bibliography}
\end{document}

MWE of the url not breaking but working

\documentclass[aps, reprint,prmat,twocolumn]{revtex4-1}
\usepackage{url}

\usepackage{hyperref}
\usepackage{breakurl}

\hypersetup{
colorlinks=true,
linkcolor=blue,
citecolor=blue,
urlcolor=blue,}

\begin{document}
blabla\cite{takeda_visualization_2005}. Ahahah\cite{LandoltBornstein2002}

\bibliography{bibliography}
\end{document}

bibliography.bib

@book{LandoltBornstein2002,
editor="Madelung, O.
and R{\"o}ssler, U.
and Schulz, M.",
title="Silicon ({Si}), band structure: Datasheet from {L}andolt-{B}{\"o}rnstein - {Group III Condensed Matter {\textperiodcentered} Volume 41A1$\beta$: ``Group IV Elements, IV-IV and III-V Compounds. Part b - Electronic, Transport, Optical and Other Properties''}",
publisher= "Springer-Verlag Berlin Heidelberg",
doi="10.1007/10832182_432",
url="https://materials.springer.com/lb/docs/sm_lbs_978-3-540-31356-4_432",
urldate ={2018-06-11},
year={2002}
}

@article{takeda_visualization_2005,
title = {Visualization of In-Plane Dispersion of Hole Subbands by Photoelectron Spectroscopy},
volume = {94},
year = 2005,
month = Jan,
issn = {0031-9007, 1079-7114},
url = {https://link.aps.org/doi/10.1103/PhysRevLett.94.037401},
doi = {10.1103/PhysRevLett.94.037401},
number = {3},
journal = {Physical Review Letters},
author = {Takeda, Sakura Nishino and Higashi, Naoto and Daimon, Hiroshi},
urldate = {2018-05-12},
date = {2005-01-24},
pages={-},
langid = {english}}
  • 2
    I get a warning that the driver for dvi does not support the option breaklinks for hyperref. There is a package called ctan.org/pkg/breakurl that says it could help here. – moewe Oct 30 '18 at 10:26
  • 1
    You wrote that "I am trying to properly break some of the url in my references." However, the two formatted bibliographic entries shown above do not appear to contains URL strings. This makes it very difficult to tell what may be going on. Please edit your code and provide examples of bibliographic entries that contain URL strings. – Mico Oct 30 '18 at 10:37
  • Please also tell us how you created the thebibliography environment shown above. Did you create it entirely by hand, or with the help of either natbib/bibtex or biblatex/biber? – Mico Oct 30 '18 at 11:30
  • @moewe : the package breakurl does not break my url. @Mico indeed. I made substential changes in my exemple. The issue seems to be the size of the title, and not of the url in itself. I decided to use a .bib file for the MWE, as it displays the same issue. – Mathis Oct 30 '18 at 12:28
  • tex.stackexchange.com/questions/456680/… may help you, but this expect biblatex to work – MadyYuvi Oct 30 '18 at 12:48
0

I found a solution : use EPS files instead of PS.

There is a conflict between the way hyperref handles the url in the references and the DVI->PS->PDF process. By converting my PS figures to EPS, I was able to compile directecly to PDF as EPS are automatically converted to pdf during the compilation, but PS files are not.

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.