summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/libertine/libertineMono.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-07-23 22:26:44 +0000
committerKarl Berry <karl@freefriends.org>2013-07-23 22:26:44 +0000
commitc053ff39827357f7a2b7c78400192d49274a1a7a (patch)
tree3d81a8aa4bc416c1c4c0824e76e2cab5a4e911ab /Master/texmf-dist/tex/latex/libertine/libertineMono.sty
parent92d4baa14f458c225ecfdc514e33ee0a87d23020 (diff)
libertine (23jul13)
git-svn-id: svn://tug.org/texlive/trunk@31272 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/libertine/libertineMono.sty')
-rw-r--r--Master/texmf-dist/tex/latex/libertine/libertineMono.sty70
1 files changed, 70 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/libertine/libertineMono.sty b/Master/texmf-dist/tex/latex/libertine/libertineMono.sty
new file mode 100644
index 00000000000..9038f8a88cd
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/libertine/libertineMono.sty
@@ -0,0 +1,70 @@
+\ProvidesPackage{libertineMono}[%
+ 2013/07/19 (Bob Tennent) Supports Libertine Mono fonts for all LaTeX engines.]
+
+\RequirePackage{ifxetex,ifluatex,xkeyval,textcomp}
+
+\newif\iflibertine@otf
+\ifxetex
+ \libertine@otftrue
+\else\ifluatex
+ \libertine@otftrue
+\else % [pdf]LaTeX
+ \libertine@otffalse
+\fi\fi
+
+\DeclareOptionX{type1}[true]{%
+\@nameuse{if#1}\libertine@otffalse\fi
+}
+\DeclareOptionX{nofontspec}[true]{%
+\@nameuse{if#1}\libertine@otffalse\fi
+}
+
+\newcommand*{\LinuxLibertineMonoT@scale}{1}
+\DeclareOptionX{ttscaled}{\renewcommand*{\LinuxLibertineMonoT@scale}{#1}}
+\DeclareOptionX{ttscale}{\renewcommand*{\LinuxLibertineMonoT@scale}{#1}}
+\DeclareOptionX{scale}{\renewcommand*{\LinuxLibertineMonoT@scale}{#1}}
+\DeclareOptionX{scaled}{\renewcommand*{\LinuxLibertineMonoT@scale}{#1}}
+
+\ProcessOptionsX\relax
+
+\iflibertine@otf
+ \RequirePackage{fontspec}
+\else
+ \RequirePackage{mweights}
+ \RequirePackage{fontenc,fontaxes}
+\fi
+
+% Set mono fonts:
+
+\iflibertine@otf
+
+ \def\libertine@base{LinLibertine}
+ \defaultfontfeatures{ Extension = .otf } % Don't want ligatures for mono
+ \setmonofont
+ [ Scale = \LinuxLibertineMonoT@scale,
+ UprightFont = *_M,
+ ItalicFont = *_MO, % oblique to fake italic
+ BoldFont = *_MB, % fontforge
+ BoldItalicFont = *_MBO, % fontforge
+ ] {\libertine@base}
+ \newfontfamily\libmono
+ [ Scale = \LinuxLibertineMonoT@scale,
+ UprightFont = *_M,
+ ItalicFont = *_MO, % oblique to fake italic
+ BoldFont = *_MB, % fontforge
+ BoldItalicFont = *_MBO, % fontforge
+ ] {\libertine@base}
+
+\else % type1
+
+ \def\ttdefault{LinuxLibertineMonoT-TLF}
+ \providecommand*\libmono{\fontfamily{LinuxLibertineMonoT-TLF}\selectfont}
+
+\fi
+
+\iflibertine@otf
+% turn off defaults in case other fonts are selected:
+ \defaultfontfeatures{}
+\fi
+
+\endinput