Mercurial > hgrepos > Python > libs > pygments-lexer-pseudocode2
comparison docs/_latex/my-doc-fonts.sty @ 191:c10b2092c48f
Also make a PDF style variant using Adobe Source Serif/Sans/Code Pro
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Wed, 13 May 2026 09:48:52 +0200 |
| parents | 91e8fb8cf67b |
| children | d57cf1bb96d6 |
comparison
equal
deleted
inserted
replaced
| 190:8825282f6900 | 191:c10b2092c48f |
|---|---|
| 14 \RequirePackage{color} | 14 \RequirePackage{color} |
| 15 } | 15 } |
| 16 | 16 |
| 17 \newif\if@mdf@WithDejaVuSansMono | 17 \newif\if@mdf@WithDejaVuSansMono |
| 18 \newif\if@mdf@WithPlexMono | 18 \newif\if@mdf@WithPlexMono |
| 19 \newif\if@mdf@WithAdobeSource | |
| 19 | 20 |
| 20 \def\@mdf@reset@font@options{\@mdf@WithDejaVuSansMonofalse\@mdf@WithPlexMonofalse} | 21 \def\@mdf@reset@font@options{\@mdf@WithDejaVuSansMonofalse\@mdf@WithPlexMonofalse\@mdf@WithAdobeSourcefalse} |
| 21 | 22 |
| 22 \DeclareOptionX{dejavusansmono}[true]{\@mdf@reset@font@options\csname @mdf@WithDejaVuSansMono#1\endcsname} | 23 \DeclareOptionX{dejavusansmono}[true]{\@mdf@reset@font@options\csname @mdf@WithDejaVuSansMono#1\endcsname} |
| 23 \DeclareOptionX{plexmono}[true]{\@mdf@reset@font@options\csname @mdf@WithPlexMono#1\endcsname} | 24 \DeclareOptionX{plexmono}[true]{\@mdf@reset@font@options\csname @mdf@WithPlexMono#1\endcsname} |
| 25 \DeclareOptionX{adobesource}[true]{\@mdf@reset@font@options\csname @mdf@WithAdobeSource#1\endcsname} | |
| 24 | 26 |
| 25 % | 27 % |
| 26 % By default use the safe option dejavusansmono because is contains | 28 % By default use the safe option dejavusansmono because is contains |
| 27 % all characters without any hacks. | 29 % all characters without any hacks. |
| 28 % | 30 % |
| 68 \PassOptionsToPackage{% | 70 \PassOptionsToPackage{% |
| 69 verbatimvisiblespace={\textcolor{red}{{\DejaVuSansMono^^^^2423}}},% | 71 verbatimvisiblespace={\textcolor{red}{{\DejaVuSansMono^^^^2423}}},% |
| 70 verbatimcontinued={\textcolor{red}{{\DejaVuSansMono^^^^21aa}}}}% | 72 verbatimcontinued={\textcolor{red}{{\DejaVuSansMono^^^^21aa}}}}% |
| 71 {sphinx} | 73 {sphinx} |
| 72 \fi | 74 \fi |
| 75 \if@mdf@WithAdobeSource | |
| 76 \RequirePackage{newunicodechar} | |
| 77 \defaultfontfeatures{Ligatures=TeX,Numbers={Lining,Tabular}} | |
| 78 \setmainfont{Source Serif Pro}[ | |
| 79 UprightFont = *, | |
| 80 BoldFont = * Bold, | |
| 81 ItalicFont = * Italic, | |
| 82 BoldItalicFont = * Bold Italic, | |
| 83 ] | |
| 84 \setsansfont{Source Sans Pro}[ | |
| 85 UprightFont = *, | |
| 86 BoldFont = * Bold, | |
| 87 ItalicFont = * Italic, | |
| 88 BoldItalicFont = * Bold Italic, | |
| 89 ] | |
| 90 \setmonofont{Source Code Pro}[ | |
| 91 UprightFont = *, | |
| 92 BoldFont = * Bold, | |
| 93 ItalicFont = * Italic, | |
| 94 BoldItalicFont = * Bold Italic, | |
| 95 Scale = MatchLowercase, | |
| 96 ] | |
| 97 \defaultfontfeatures{} | |
| 98 \newfontfamily\DejaVuSansMono{DejaVu Sans Mono}[% | |
| 99 UprightFont = *, | |
| 100 BoldFont = * Bold, | |
| 101 ItalicFont = * Oblique, | |
| 102 BoldItalicFont = * Bold Oblique, | |
| 103 Scale=MatchLowercase, | |
| 104 Ligatures=TeX, | |
| 105 ] | |
| 106 \newunicodechar{∶}{{\DejaVuSansMono ∶}}% U+2236 | |
| 107 \newunicodechar{⟵}{{\DejaVuSansMono ⟵}}% U+27F5 | |
| 108 \newunicodechar{⟶}{{\DejaVuSansMono ⟶}}% U+27F6 | |
| 109 \newunicodechar{⟷}{{\DejaVuSansMono ⟷}}% U+27F7 | |
| 110 \newunicodechar{⇒}{{\DejaVuSansMono ⇒}}% U+21D2 | |
| 111 \newunicodechar{⇔}{{\DejaVuSansMono ⇔}}% U+21D4 | |
| 112 \newunicodechar{≟}{{\DejaVuSansMono ≟}}% U+225F | |
| 113 \newunicodechar{∈}{{\DejaVuSansMono ∈}}% U+2208 | |
| 114 \newunicodechar{∌}{{\DejaVuSansMono ∌}}% U+220C | |
| 115 \PassOptionsToPackage{% | |
| 116 verbatimvisiblespace={\textcolor{red}{{\DejaVuSansMono^^^^2423}}},% | |
| 117 verbatimcontinued={\textcolor{red}{{\DejaVuSansMono^^^^21aa}}}}% | |
| 118 {sphinx} | |
| 119 \fi | |
| 73 \endinput | 120 \endinput |
