diff options
Diffstat (limited to 'fonts/charissil/latex/CharisSIL.sty')
-rw-r--r-- | fonts/charissil/latex/CharisSIL.sty | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/fonts/charissil/latex/CharisSIL.sty b/fonts/charissil/latex/CharisSIL.sty new file mode 100644 index 0000000000..4d50080243 --- /dev/null +++ b/fonts/charissil/latex/CharisSIL.sty @@ -0,0 +1,66 @@ +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{CharisSIL} + [2020/07/19 (Bob Tennent and autoinst) Style file for CharisSIL fonts.] + +\RequirePackage{iftex,xkeyval,textcomp} + +\newif\ifCharisSIL@ttf +\ifxetex + \CharisSIL@ttftrue +\else\ifluatex + \CharisSIL@ttftrue +\else % [pdf]LaTeX + \CharisSIL@ttffalse + \fi\fi + +\RequirePackage{fontaxes} + +\newcommand*{\CharisSIL@scale}{1} +\RequirePackage{xkeyval} +\DeclareOptionX{scaled}{\renewcommand*{\CharisSIL@scale}{#1}} +\DeclareOptionX{scale}{\renewcommand*{\CharisSIL@scale}{#1}} +\DeclareOptionX{type1}{\CharisSIL@ttffalse} + +\ProcessOptionsX\relax + +\ifCharisSIL@ttf + \RequirePackage{fontspec} +\else + \RequirePackage{fontenc,fontaxes} +\fi + +\ifCharisSIL@ttf + \ifxetex\XeTeXtracingfonts=1\fi + \defaultfontfeatures{ + Ligatures = TeX , + Scale = \CharisSIL@scale , + Extension = .ttf } + \setmainfont + [ UprightFont = *-R, + ItalicFont = *-I, + BoldFont = *-B, + BoldItalicFont = *-BI , + ] + {CharisSIL} + \newfontfamily\CharisSIL + [ UprightFont = *-R, + ItalicFont = *-I, + BoldFont = *-B, + BoldItalicFont = *-BI , + ] + {CharisSIL} + + +\else % type1 + + \def\CharisSIL@family{CharisSIL-TLF} + \renewcommand*\rmdefault{\CharisSIL@family} + \newcommand*\CharisSIL{\fontfamily{\CharisSIL@family}\selectfont} + +\fi + +\ifCharisSIL@ttf + \defaultfontfeatures{} +\fi + +\endinput |