aboutsummaryrefslogtreecommitdiff
path: root/fmt
diff options
context:
space:
mode:
authorHolden Rohrer <hr@hrhr.dev>2020-07-06 17:18:29 -0400
committerHolden Rohrer <hr@hrhr.dev>2020-07-06 18:42:06 -0400
commit0245930909caa958b8dcf810d85e542796a8b74d (patch)
tree50af3951de76233076097f04a841892d211c518f /fmt
parentc4b7eefa36f35e2b13e91ca66d3c4b7711167e72 (diff)
links are anysplit (all chars are breakable)
Diffstat (limited to 'fmt')
-rw-r--r--fmt/com.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/fmt/com.h b/fmt/com.h
index e8388ae..8083172 100644
--- a/fmt/com.h
+++ b/fmt/com.h
@@ -1,5 +1,12 @@
%% links
+\def\anysplit#1{%
+ \ifx#1\relax\let\next\relax\else
+ #1\discretionary{}{}{}\let\next\anysplit
+ \fi
+ \next
+}
+
\def\link#1{%
\pdfstartlink
user{/Subtype /Link
@@ -9,7 +16,7 @@
/S /URI
/URI (#1)
>>}%
- {\tt \color{blue} #1}%
+ {\tt \color{blue} \anysplit #1\relax}%
\pdfendlink
}