Switch to lualatex and generate accessible PDF/UA-2 output
Add \DocumentMetadata for PDF 2.0 / PDF/UA-2, load tagpdf with activate-all, extend hypersetup with pdftitle/pdfauthor/pdflang/ pdfdisplaydoctitle, and add alt text to the letterhead and signature images. Drop xetex-only xltxtra and switch the Makefile from xelatex to lualatex. Verified compliant with verapdf's PDF/UA-2 profile. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2
Makefile
2
Makefile
@@ -11,7 +11,7 @@ figures/signature.pdf:
|
||||
gpg --yes --output $(DEC_SIGIMAGE) --decrypt $(ENC_SIGIMAGE)
|
||||
|
||||
%.pdf: %.tex
|
||||
latexmk -f -xelatex $<
|
||||
latexmk -f -lualatex $<
|
||||
|
||||
clean:
|
||||
latexmk -C *.tex
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
\DocumentMetadata{
|
||||
pdfversion=2.0,
|
||||
pdfstandard=ua-2,
|
||||
lang=en-US,
|
||||
}
|
||||
\documentclass[11pt,letterpaper]{article}
|
||||
|
||||
% MODIFY THE DETAILS IN THIS SECTION TO MATCH WHAT YOU WANT ON /YOUR/ LETTERHEAD
|
||||
@@ -6,12 +11,16 @@
|
||||
\def\phone{mobile 206-409-7191}
|
||||
\def\email{makohill@uw.edu}
|
||||
\def\web{https://mako.cc/academic/}
|
||||
\def\lettertitle{Letter from \email}
|
||||
\def\letterauthor{John Hancock}
|
||||
|
||||
\usepackage[top=1.25in,left=1.25in,bottom=1.20in,right=1.25in]{geometry}
|
||||
|
||||
\usepackage{xltxtra}
|
||||
|
||||
\usepackage{fontspec}
|
||||
\usepackage{tagpdf}
|
||||
\tagpdfsetup{activate-all}
|
||||
\newopentypefeature{Contextuals}{NoAlternate}{-calt}
|
||||
\defaultfontfeatures{Kerning=Uppercase,Ligatures=TeX}
|
||||
|
||||
\setsansfont{OpenSans}[
|
||||
Path = ./fonts/OpenSans/,
|
||||
@@ -31,6 +40,11 @@ BoldItalicFont = *-BoldItalic
|
||||
\usepackage[colorlinks=false,
|
||||
pdfborder={0 0 0},
|
||||
]{hyperref}
|
||||
\hypersetup{unicode=true,
|
||||
pdftitle={\lettertitle},
|
||||
pdfauthor={\letterauthor},
|
||||
pdflang={en-US},
|
||||
pdfdisplaydoctitle=true}
|
||||
\usepackage{tikz}
|
||||
|
||||
\usepackage{lastpage}
|
||||
@@ -43,7 +57,7 @@ BoldItalicFont = *-BoldItalic
|
||||
\ifnum\thepage=1
|
||||
\begin{tikzpicture}[remember picture,overlay,every node/.style={inner sep=0,outer sep=0}]
|
||||
\node at (current page.north west) [anchor=north west]
|
||||
{\includegraphics{figures/matrix_header.pdf}};
|
||||
{\includegraphics[alt={University of Washington letterhead}]{figures/matrix_header.pdf}};
|
||||
% add the department name
|
||||
\node at (current page.north west) [anchor=north west, xshift=1.19in, yshift=-0.56in]
|
||||
{{\fontsize{14pt}{16pt} \fontspec{MatrixIIOT-Book.otf}[
|
||||
@@ -127,7 +141,7 @@ Sed ullamcorper morbi tincidunt ornare massa eget egestas purus. Feugiat pretium
|
||||
|
||||
Sincerely,
|
||||
|
||||
\includegraphics[width=1.7in]{figures/signature.pdf}\\
|
||||
\includegraphics[width=1.7in,alt={Signature of \letterauthor}]{figures/signature.pdf}\\
|
||||
John Hancock\\
|
||||
Assistant Professor of Communication\\
|
||||
Adjunct Assistant Professor of Human-Centered Design and Engineering
|
||||
|
||||
Reference in New Issue
Block a user