@@ -135,11 +135,6 @@ $if(beamerarticle)$
135
135
$endif$
136
136
\usepackage{amsmath,amssymb}
137
137
\usepackage{mathtools}
138
- $if(fontfamily)$
139
- \usepackage[$for(fontfamilyoptions)$$fontfamilyoptions$$sep$,$endfor$]{$fontfamily$}
140
- $else$
141
- \usepackage{lmodern}
142
- $endif$
143
138
$if(linestretch)$
144
139
\usepackage{setspace}
145
140
$else$
@@ -162,69 +157,17 @@ $if(mathspec)$
162
157
$else$
163
158
\usepackage{unicode-math}
164
159
$endif$
165
- \defaultfontfeatures{Scale=MatchLowercase}
166
- \defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
167
- $if(mainfont)$
168
- \setmainfont[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$]{$mainfont$}
169
- $endif$
170
- $if(sansfont)$
171
- \setsansfont[$for(sansfontoptions)$$sansfontoptions$$sep$,$endfor$]{$sansfont$}
172
- $endif$
173
- $if(monofont)$
174
- \setmonofont[$for(monofontoptions)$$monofontoptions$$sep$,$endfor$]{$monofont$}
175
- $endif$
176
- $for(fontfamilies)$
177
- \newfontfamily{$fontfamilies.name$}[$for(fontfamilies.options)$$fontfamilies.options$$sep$,$endfor$]{$fontfamilies.font$}
178
- $endfor$
179
- $if(mathfont)$
180
- $if(mathspec)$
181
- \ifxetex
182
- \setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
183
- \else
184
- \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
185
- \fi
186
- $else$
187
- \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$}
188
- $endif$
189
- $endif$
190
- $if(CJKmainfont)$
191
- \ifxetex
192
- \usepackage{xeCJK}
193
- \setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
194
- \fi
195
- $endif$
160
+
161
+ \defaultfontfeatures{Scale=MatchLowercase}
162
+ \defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
163
+
196
164
$if(luatexjapresetoptions)$
197
165
\ifluatex
198
166
\usepackage[$for(luatexjapresetoptions)$$luatexjapresetoptions$$sep$,$endfor$]{luatexja-preset}
199
167
\fi
200
168
$endif$
201
- $if(CJKmainfont)$
202
- \ifluatex
203
- \usepackage[$for(luatexjafontspecoptions)$$luatexjafontspecoptions$$sep$,$endfor$]{luatexja-fontspec}
204
- \setmainjfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$}
205
- \fi
206
- $endif$
207
169
\fi
208
- $if(beamer)$
209
- $if(theme)$
210
- \usetheme[$for(themeoptions)$$themeoptions$$sep$,$endfor$]{$theme$}
211
- $endif$
212
- $if(colortheme)$
213
- \usecolortheme{$colortheme$}
214
- $endif$
215
- $if(fonttheme)$
216
- \usefonttheme{$fonttheme$}
217
- $endif$
218
- $if(mainfont)$
219
- \usefonttheme{serif} % use mainfont rather than sansfont for slide text
220
- $endif$
221
- $if(innertheme)$
222
- \useinnertheme{$innertheme$}
223
- $endif$
224
- $if(outertheme)$
225
- \useoutertheme{$outertheme$}
226
- $endif$
227
- $endif$
170
+
228
171
% Use upquote if available, for straight quotes in verbatim environments
229
172
\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
230
173
\IfFileExists{microtype.sty}{% use microtype if available
@@ -639,45 +582,29 @@ $endif$
639
582
\unskip\unskip\endlist\end{customblockquote}
640
583
}
641
584
642
- %
643
- % Source Sans Pro as the default font family
644
- % Source Code Pro for monospace text
645
- %
646
- % 'default' option sets the default
647
- % font family to Source Sans Pro, not \sfdefault.
648
- %
649
- \ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
650
- $if(fontfamily)$
651
- $else$
652
- \usepackage[default]{sourcesanspro}
653
- \usepackage{sourcecodepro}
654
- $endif$
655
- \else % if not pdftex
656
- $if(mainfont)$
657
- $else$
658
- \usepackage[default]{sourcesanspro}
659
- \usepackage{sourcecodepro}
585
+ \usepackage{fontspec}
586
+ \setmainfont{Arial}
587
+ \setsansfont{Arial}
588
+ \setmonofont{Source Code Pro}
660
589
661
- % XeLaTeX specific adjustments for straight quotes: https://tex.stackexchange.com/a/354887
662
- % This issue is already fixed (see https://github.com/silkeh/latex-sourcecodepro/pull/5) but the
663
- % fix is still unreleased.
664
- % TODO: Remove this workaround when the new version of sourcecodepro is released on CTAN.
665
- \ifxetex
666
- \makeatletter
667
- \defaultfontfeatures[\ttfamily]
668
- { Numbers = \sourcecodepro@figurestyle,
669
- Scale = \SourceCodePro@scale,
670
- Extension = .otf }
671
- \setmonofont
672
- [ UprightFont = *-\sourcecodepro@regstyle,
673
- ItalicFont = *-\sourcecodepro@regstyle It,
674
- BoldFont = *-\sourcecodepro@boldstyle,
675
- BoldItalicFont = *-\sourcecodepro@boldstyle It ]
676
- {SourceCodePro}
677
- \makeatother
678
- \fi
679
- $endif$
680
- \fi
590
+ \usepackage{newunicodechar}
591
+ % Use Arial Unicode to display various unicode symbols that might be present
592
+ \newfontfamily{\fallbackfont}{Arial Unicode MS}[Scale=MatchLowercase]
593
+ \DeclareTextFontCommand{\textfallback}{\fallbackfont}
594
+ % TODO: Cover more characters with a nice loop or macro.
595
+ \newunicodechar{≔}{\textfallback{≔}}
596
+ \newunicodechar{⌊}{\textfallback{⌊}}
597
+ \newunicodechar{⌋}{\textfallback{⌋}}
598
+ \newunicodechar{⌈}{\textfallback{⌈}}
599
+ \newunicodechar{⌉}{\textfallback{⌉}}
600
+ \newunicodechar{⊕}{\textfallback{⊕}}
601
+ \newunicodechar{·}{\textfallback{·}}
602
+ \newunicodechar{≥}{\textfallback{≥}}
603
+ \newunicodechar{≤}{\textfallback{≤}}
604
+ \newunicodechar{≠}{\textfallback{≠}}
605
+ \newunicodechar{©}{\textfallback{©}}
606
+ \newunicodechar{™}{\textfallback{™}}
607
+ \newunicodechar{→}{\textfallback{→}}
681
608
682
609
%
683
610
% heading color
0 commit comments