2

I'm trying to submit proposal documents to NSF Fastlane. I'm generating PDF documents using lualatex. My file contains hyperref links internally and externally, but they are removed by Fastlane's upload PDF redistillation. The text remains and is visible, but there is no link to click on.

Here is my minimal non-working example. I compile it using lualatex from the TeXLive 2016 distribution on Windows. The culprit seems to be fontspec. If I remove that line, the links work, but I'd like to use fontspec so I can choose fonts.

\documentclass[fontsize=10pt,paper=letter,twoside=false,onecolumn]{scrartcl} 
\usepackage{fontspec} % This seems to be the problem.
\usepackage{hyperref}
\setmainfont{Palatino Linotype}

\begin{document}
\section{Section}\label{sec}
This is an explicit external url: \url{http://tex.stackexchange.com}.

This is an external link: \href{http://tex.stackexchange.com}{Link}.

This is an internal link to Sec.~\ref{sec}.
\end{document}

My questions are:

  • What about fontspec makes my links get eaten by Fastlane?
  • Is there a workaround?

Edit: The issue is something with how Fastlane handles fonts when it re-distills PDFs.
For example, in the example give, if I run pdffonts on file generated by lualatex I get the following output:

name                                 type              emb sub uni object ID
------------------------------------ ----------------- --- --- --- ---------
TYJNNQ+PalatinoLinotype-Roman        CID TrueType      yes yes yes     19  0

but after uploading the file to Fastlane and re-downloading, the output of pdffonts gives

name                                 type              emb sub uni object ID
------------------------------------ ----------------- --- --- --- ---------
EKFDNL+PalatinoLinotype-Roman        CID TrueType      yes yes no      31  0
EKFFKE+PalatinoLinotype-Roman        TrueType          yes yes no      36  0
EKFFNF+PalatinoLinotype-Roman        TrueType          yes yes no       2  0

Somehow the font is being broken up and re-encoded, breaking hyperlinks in the process.

Edit 2: I'm uncertain that the fonts are really the issue. After changing the fonts, \url{} links work, but \href{}{} links still do not.

  • You are not using hyperref in your example, so whatever links you are getting are a result of the pdfviewer heuristic. – Ulrike Fischer Jul 17 '17 at 21:54
  • @UlrikeFischer - Sorry, that was a pasting error. The actual example does have hyperref. Now edited to fix. – Ted Corcovilos Jul 17 '17 at 21:55
  • Don't load fontenc when using lualatex. Does that change anything? I don't recall having this problem, and use fontspec and lualatex also. – Alan Munn Jul 17 '17 at 22:10
  • 1
    @UlrikeFischer - you were right. The fine print on Fastlane says that Type 3 fonts will not work. If I explicitly declare some ttf fonts (e.g. Times New Roman and Courier New), then the distillation preserves the links. – Ted Corcovilos Jul 17 '17 at 22:26
  • 1
    Also, the PDF versions need to be <=1.4. I don't understand the various PDF versions, but the fonts are stored differently in 1.5 and up. I'll amend my answer below. – Ted Corcovilos Jul 18 '17 at 3:01
5

The problem is that Fastlane's PDF distiller can't process all fonts. See page 1346 of the Fastlane docs: https://www.research.gov/common/attachment/Desktop/FastLane_Help.pdf (Warning: the file is 30MB large.)

The instructions explicitly say to use only Type 1 or TrueType fonts. In particular, hyperref uses the mono font family for typesetting URLs, so this must be explicitly set.

That is the technical issue. But also, per the most recent NSF guidelines (https://www.nsf.gov/pubs/policydocs/pappg17_1/pappg_2.jsp#IIB2), the only allowed fonts are

Arial, Courier New, or Palatino Linotype at a font size of 10 points or larger;

Times New Roman at a font size of 11 points or larger; or

Computer Modern family of fonts at a font size of 11 points or larger.

Of these choices, I believe the only monospaced fonts are Courier New or Computer Modern Typewriter (if you have the .ttf version), so it is necessary to use something like

\setmonofont{Courier New}

to override the default (e.g. lm-mono) or otherwise disable all monospaced fonts in the document.

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.