diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/lobster2/LobsterTwo.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/lobster2/LobsterTwo.sty | 78 |
1 files changed, 48 insertions, 30 deletions
diff --git a/Master/texmf-dist/tex/latex/lobster2/LobsterTwo.sty b/Master/texmf-dist/tex/latex/lobster2/LobsterTwo.sty index 324c209567e..c8bca9b8fb8 100644 --- a/Master/texmf-dist/tex/latex/lobster2/LobsterTwo.sty +++ b/Master/texmf-dist/tex/latex/lobster2/LobsterTwo.sty @@ -1,46 +1,64 @@ \ProvidesPackage{LobsterTwo}[% - 2020/07/22 (Bob Tennent) Supports Lobster Two fonts for modern LaTeX engines. ] + 2020/07/29 (Bob Tennent) Supports Lobster Two fonts for all LaTeX engines. ] -\RequirePackage{iftex} - -\ifpdftex -\PackageError{lobster2}{% - *****************************************\MessageBreak - Please Process using xelatex or lualatex\MessageBreak - *****************************************} -\fi +\RequirePackage{ifxetex,ifluatex,textcomp} +\newif\ifLobsterTwo@otf +\ifxetex + \LobsterTwo@otftrue +\else\ifluatex + \LobsterTwo@otftrue +\else % [pdf]LaTeX + \LobsterTwo@otffalse +\fi\fi \newcommand*{\LobsterTwo@scale}{1} \RequirePackage{xkeyval} \DeclareOptionX{scaled}{\renewcommand*{\LobsterTwo@scale}{#1}} \DeclareOptionX{scale}{\renewcommand*{\LobsterTwo@scale}{#1}} +\DeclareOptionX{type1}{\LobsterTwo@otffalse} + \ProcessOptionsX\relax -\RequirePackage{fontspec} - -\ifxetex\XeTeXtracingfonts=1\fi -\defaultfontfeatures{ - Ligatures = TeX , - Extension = .ttf , - Scale = \LobsterTwo@scale , -} -\setmainfont - [ UprightFont = *-Regular , - ItalicFont = *-Italic , - BoldFont = *-Bold , - BoldItalicFont = *-BoldItalic ] - {LobsterTwo} -\newfontfamily\LobsterTwo - [ UprightFont = *-Regular , - ItalicFont = *-Italic , - BoldFont = *-Bold , - BoldItalicFont = *-BoldItalic ] - {LobsterTwo} +\ifLobsterTwo@otf + \RequirePackage{fontspec} +\else + \RequirePackage{fontenc,fontaxes} +\fi + +\ifLobsterTwo@otf + \ifxetex\XeTeXtracingfonts=1\fi + \defaultfontfeatures{ + Ligatures = TeX , + Extension = .otf , + Scale = \LobsterTwo@scale , + } + \setmainfont + [ UprightFont = *-Regular , + ItalicFont = *-Italic , + BoldFont = *-Bold , + BoldItalicFont = *-BoldItalic ] + {LobsterTwo} + \newfontfamily\LobsterTwo + [ UprightFont = *-Regular , + ItalicFont = *-Italic , + BoldFont = *-Bold , + BoldItalicFont = *-BoldItalic ] + {LobsterTwo} + +\else % type1 + + \def\LobsterTwofamily{Lbstr-LF} + \renewcommand*\rmdefault{\LobsterTwofamily} + \newcommand*\LobsterTwo{\fontfamily{\LobsterTwofamily}\selectfont} + +\fi % turn off defaults in case other fonts are selected: -\defaultfontfeatures{} +\ifLobsterTwo@otf + \defaultfontfeatures{} +\fi \endinput |