summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/tagpdf/ex-softhyphen.tex
blob: a4454b2d2691a8e8b52c9a1203cdadd18c4cfa20 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
% !Mode:: "TeX:DE:UTF-8:Main"
% !! needs lualatex
% this sets the hyphen used by automatic hyphenation to 00AD
% this improves copy&pasting
% the example gives 
%  aaaaaaa-aaaaaa aaaaaaa-aaaaaa
%  Ministerpräsident
% when copied from adobe
% sumatra doesn't understand this and copies Mi­nisterprä­sident

\DocumentMetadata{testphase=phase-II,pdfversion=1.7,uncompress}
\documentclass{book}

\usepackage[ngerman]{babel} %to get some hyphenation

\usepackage{fontspec}
%with older luaotfload we must remove the invisible feature!
\setmainfont{TeX Gyre Pagella}[RawFeature={-invisible}]
\prehyphenchar"AD

\pagestyle{empty}
\textwidth=1cm
\begin{document}

aaaaaaa-aaaaaa aaaaaaa-aaaaaa

Ministerpräsident

\end{document}



aaaaaaa-aaaaaa aaaaaaa-aaaaaa
Ministerpräsident

aaaaaaa-aaaaaa aaaaaaa-aaaaaa
Ministerpräsident