%%
% \iffalse meta-comment
%
% Copyright 2019, 2023--2025 Brian Dunn
%
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either version 1.3
% of this license or (at your option) any later version.
% The latest version of this license is in
%   http://www.latex-project.org/lppl.txt
% and version 1.3 or later is part of all distributions of LaTeX
% version 2005/12/01 or later.
%
% \fi
%
% \iffalse
%<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
%<package>\ProvidesPackage{metalogox}
%<package>    [2025/01/23 v1.07 Extends the metalogo package with font detection.]
%
%<*driver>
\documentclass{ltxdoc}

\makeatletter
\def\index@prologue{\section*{Index}%
                 \markboth{Index}{Index}%
                 Numbers written in italic refer to the page
                 where the corresponding entry is described.
    Square brackets indicate the option used by a given package or synonym option.
                 }
\makeatother

\newcommand{\mypackagename}{metalogox}

\newcommand{\quicksummary}{Automatically adjusts the \TeX\ logo and related,
    depending on the font.}


\usepackage{erewhon}

\usepackage{aurical}


\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}


\usepackage[svgnames]{xcolor}
\definecolor{myurlcolor}{rgb}{0,0,.7}
\definecolor{mylinkcolor}{rgb}{.7,0,0}
\definecolor{codecolor}{rgb}{0,.4,.2}
\definecolor{overviewcolor}{rgb}{0,.2,.4}


\usepackage{microtype}

\usepackage{etoolbox}

\usepackage{dtxdescribe}[2023/01/03]

\usepackage{booktabs}

\usepackage{titleps}

\newpagestyle{pageheadfoot}{
    \headrule
    \sethead{\pkg{\mypackagename}}{}{\thepage}
%   \renewcommand{\makefootrule}{\rule[2.5ex]{\linewidth}{.4pt}}
    \setfoot{}{}{}
}

\pagestyle{pageheadfoot}

\usepackage{needspace}




\AtBeginDocument{
\hypersetup{%
pdfinfo={%
Title={LaTeX \mypackagename{} package},%
Author={Brian Dunn},%
Subject={LaTeX metalogox package},%
Keywords={LaTeX, metalogox, logo},%
colorlinks,%
linkcolor=mylinkcolor,%
urlcolor=myurlcolor,%
pageanchor=true,
}}

\pdfstringdefDisableCommands{
\def\quad{ }
\def\\{ }
\def\pkg#1{#1}
\def\cs#1{\textbackslash#1}
\def\env#1{#1}
\def\,{ }
\def\prog#1{#1}
\def\LuaLaTeX{LuaLaTeX}
\def\XeLaTeX{XeLaTeX}
\def\TeX{TeX}
\def\LaTeX{LaTeX}
\def\Dash{ --- }
\def\dash{ -- }
\def\element#1{#1}
\def\attribute#1{#1}
\def\DVI{DVI}
\def\PDF{PDF}
}
}% AtBeginDocument

\AddToHook{begindocument/before}{% Before .aux file is loaded.
\usepackage{cleveref}
}

% from dtxdescribe:
\setlength{\marginparsep}{1em}
\setlength{\marginparpush}{.7ex}



\setlength{\parindent}{0em}
\setlength{\parskip}{2ex}
\setlength{\IndexMin}{40ex}


\usepackage{\mypackagename}

\newcommand*{\onetex}[3]{%
    \usefont{T1}{#1}{m}{#3}%
    \adjustlogos{default}%
    \LaTeX &
    \usefont{T1}{#1}{m}{#3}%
%     \adjustlogos{#2}%
    \autoadjustlogos%
    \LaTeX \\
}

\newcommand*{\textblue}[1]{\textcolor{blue!70!black}{#1}}

\setcounter{IndexColumns}{2}
\setcounter{GlossaryColumns}{2}

\DisableCrossrefs
\CodelineIndex
\RecordChanges
\begin{document}
  \DocInput{\mypackagename.dtx}
\end{document}
%</driver>
% \fi
%


% \changes{v1.00}{2019/01/20}{\ 2019/01/20 Initial version.}
% \changes{v1.01}{2023/01/03}{Docs adjusted for \pkg{dtxdescribe}.}
% \changes{v1.01}{2023/01/03}{\ 2023/01/03}
% \changes{v1.02}{2024/01/12}{Updated contact info.}
% \changes{v1.02}{2024/01/12}{\ 2024/01/12}
% \changes{v1.03}{2024/01/18}{Improved TOC change log and index entries.}
% \changes{v1.03}{2024/01/18}{Added Atkinson Hyperlegible, Charis SIL, Cuprum,
%                               Eczar, Ibarra, Inria, Inter, MLModern, Nunito, Oswald.}
% \changes{v1.03}{2024/01/19}{2024/01/19}
% \changes{v1.04}{2024/01/26}{2024/01/26}
% \changes{v1.05}{2024/03/01}{2024/03/01}
% \changes{v1.06}{2024/03/07}{2024/03/07}
% \changes{v1.07}{2025/01/23}{2025/01/23}



% \GetFileInfo{\mypackagename.sty}
%
% \DoNotIndex{\newcommand,\renewcommand,\addtocounter,\begin,\end,\begingroup,\endgroup}
% \DoNotIndex{\global,\ifbool,\ifthenelse,\isequivalentto,\let}
% \DoNotIndex{\booltrue,\boolfalse}
% \expandafter\DoNotIndex\expandafter{\detokenize{\(,\),\,,\\,\#,\$,\%,\^,\_,\~,\ ,\&,\{,\}}}
%
% \begin{center}
% \thispagestyle{empty}
% \vfill
% {\Huge The \LaTeX\ \pkg{\mypackagename} package}
%
% \fileversion{} --- \filedate
%
% \bigskip
%
% {\small\textcopyright{} 2019, 2023--2025} Brian Dunn\\ \small \url{https://github.com/bdtc/metalogox}
%
% \vspace{.5in}
%
% {\normalsize\textup{\quicksummary}}
%
% \vfill
%
% {
% \Large
% \begin{tabular}{ccc}
% \toprule
% Font & Default & \pkg{metalogox} \\ \midrule
% Latin Modern & \onetex{lmr}{lmodern}{n}
% Times & \onetex{ptm}{times}{n}
% Bookman & \onetex{pbk}{bookman}{n}
% Erewhon & \onetex{erewhon-TLF}{utopia}{n}
% Libre Caslon & \onetex{LibreCsln-TLF}{baskerville}{n}
% Libertinus & \onetex{LibertinusSerif-TLF}{libertinus-type1}{n}
% IM Fell English & \onetex{IMFELLEnglish-TLF}{baskerville}{n}
% Coelacanth & \onetex{Coelacanth-TLF}{coelacanth}{n}
% Alegreya & \onetex{Alegreya-TLF}{alegreya}{n}
% Helvetica & \onetex{phv}{helvetica}{n}
% Antiqua & \onetex{uaq}{antiqua}{n}
% \bottomrule
% \end{tabular}
% }
%
% \vfill
%
% \begin{abstract}
% \noindent
% The \pkg{metalogox} package extends the \pkg{metalogo} package to
% automatically adjust the appearance of the logos
% \TeX, \LaTeX, \LaTeXe, \XeLaTeX, and \LuaLaTeX,
% depending on the font detected or the option given to \pkg{metalogox}.
%
% \changes{v1.01}{2023/01/03}{Updated \LaTeX\ Font Catalog website.}
% Most of the serif and sans fonts listed at
% \href{https://tug.org/FontCatalogue/}{The \LaTeX\ Font Catalogue}
% are supported.
% \end{abstract}
%
% \vspace*{\fill}
% \vspace*{\fill}
% \vspace*{\fill}
% \end{center}
%
% \clearpage
%
% \tableofcontents
% \clearpage
%
%
% \thispagestyle{pageheadfoot}
%
% \clearpage
%
% \section{Introduction}
%
% \setlength{\parindent}{2em}
% \setlength{\parskip}{0ex}
%
% The rendering of the logos \TeX, \LaTeX, \LaTeXe, \XeLaTeX, \XeTeX, and \LuaLaTeX\
% depends on the font, and in some cases the appearance of these logos may be
% improved with some minor adjustments of the positions of each of the elements.
% The \pkg{metalogo} package, by \textsc{Andrew Gilbert Moschou},
% allows the user to specify these adjustments, but it is left to the user
% to determine the values to use.  The correct value may depend on the font size,
% but in most cases predefined settings may be used.
%
% The \pkg{metalogox} package assigns these settings for \pkg{metalogo}.
% The default is for \brand{Latin Modern} and similar.
% IF the font in use is supported by \pkg{metalogox},
% settings for that font are automatically assigned,
% overriding the \brand{Latin Modern} default.
% If the user specifies a package option, its settings override the default and
% also anything set by font detection.
%
% The \LaTeX\ packages \pkg{hologo} and \pkg{hvlogos} are also supported
% when used with \pkg{metalogox}.
%
%
% \setlength{\parindent}{0em}
% \setlength{\parskip}{2ex}
%
% \section{Using the \pkg{metalogox} package}
%
% \DescribePackage{metalogox}
% In most cases, it is sufficient to simply load the \pkg{metalogox} package
% after the fonts have been selected:
% \begin{sourcedisplay}
% \cs{usepackage}\{<font packages>\} \\
% \cs{setmainfont}\{Font Name\} \hfill \textrm{(if using \pkg{fontspec})}\\
% \dots etc \dots \\
% \% \cs{renewcommand}\{\cs{familydefault}\}\{\cs{sfdefault}\} \hfill \textrm{(optional)} \\
% \dots \\
% \cs{usepackage}\{metalogox\} \\
% \end{sourcedisplay}
% Many fonts are supported by \pkg{metalogox}, and if one of these is in use
% then the appropriate settings are assigned automatically, according to
% the default text body font:
% \qquad \LaTeXe
%
% If several font packages are used, or a font is not recognized,
% \margintag{options}
% it may be necessary to specify a \pkg{metalogox} package option,
% which overrides the font detection:
% \begin{sourcedisplay}
% \cs{usepackage}\textblue{[baskerville]}\{metalogox\}
% \end{sourcedisplay}
%
% \DescribeMacro{\adjustlogos} \marg{package option}
%
% \cs{adjustlogos} may be used to adjust the logos for an unknown font.
% The mandatory argument is the same as the package options.
% This is a local change, and may be adjusted as needed.
% \begin{sourcedisplay}
% \cs{Fontskrivan} \hfill \textrm{(from the \pkg{aurical} package)} \\
% \cs{adjustlogos}\{default\} \cs{LaTeXe} \hfill
%       {\Fontskrivan\adjustlogos{default}\LaTeXe} \\
% \cs{adjustlogos}\{baskerville\} \cs{LaTeXe} \hfill
%       {\Fontskrivan\adjustlogos{baskerville}\LaTeXe}
% \end{sourcedisplay}
%
% \needspace{3\baselineskip}
%
% \DescribeMacro{\autoadjustlogos}
% \cs{autoadjustlogos} may be used to make local changes
% according to the current font:
% \begin{sourcedisplay}
% \cs{textsf}\{Using \textblue{\cs{autoadjustlogos}}\cs{LaTeXe}\}
% \hfill \mbox{\textsf{Using \autoadjustlogos\LaTeXe}} \\
% \cs{textsf}\{Using \cs{textrm}\{\textblue{\cs{autoadjustlogos}}\cs{LaTeXe}\}\}
% \hfill \mbox{\textsf{Using \textrm{\autoadjustlogos\LaTeXe}}} \\
% \end{sourcedisplay}
%
% \DescribeMacro{\autoadjustlogos*}
% The starred form, \cs{autoadjustlogos*},
% is used by \pkg{metalogox} at the beginning of the document to set
% according to the default text body font.
%
%
% \paragraph{Notes:}
% \begin{itemize}
% \item \pkg{metalogox} option names may be found in the following pages,
% or in the index.
%
% \item \pkg{metalogox} options are always lowercase, even if a related package
% name may have uppercase letters.
%
% \item Many options, such as \optn{times}, are used to cover an entire category
% of related fonts.
%
% \item Other options, such as \optn{baskerville}, may be used for
% unrelated fonts which just happen to work well with the same logo settings.
%
% \item For some fonts, \XeLaTeX\ renders the reversed |E| in the \XeLaTeX\ logo
% differently than pdf\LaTeX\ and \LuaLaTeX.
%
% \item There are sometimes differences between the \brand{Type1} and
% the \acro{OTF} \Slash \acro{TTF} fonts.
%
% \item \PDF\ display software may not render logos well on the screen
% at small display sizes.  Zoom in to judge the quality of the logos.
%
% \item The \pkg{metalogox} parameters were set according to the design preferences of
% the author of the \pkg{metalogo} package.  Some may disagree with the design choices
% which were made, but the results are probably better than the defaults, and the
% user may take control using the \pkg{metalogo} package directly.
%
% \item Since the same settings are usually shared by many fonts,
% some logos may not be perfect.
%
% \item If a font is not known by \pkg{metalogox} then a warning is issued,
% and a few common options are recommended.
%
% \item Please contact the author of \pkg{metalogox} if an unknown font is found,
% \margintag{Unknown font?}
% especially if it is a common font, as sometimes the font family names
% are changed.  See the contact link on the title page of this document.
% \end{itemize}
%
%
% \StopEventually{
% \appendix
% \GlossaryPrologue{\section{Change History}}
% \PrintChanges
% \IndexPrologue{\section{Index}}
% \PrintIndex}
%
% \clearpage
%
% \section{Code}
%
% \subsection{Required packages}
%
% \changes{v1.07}{2024/09/15}{\pkg{xparse} only if old format.}
%    \begin{macrocode}
\RequirePackage{metalogo}

\IfFormatAtLeastTF{2020-10-01}{}{\RequirePackage{xparse}}

\RequirePackage{etoolbox}
%    \end{macrocode}
%
%
% \subsection{Package options}
%
% Each of the following is a macro which is activated by
% passing the option of the same name to \pkg{metalogox},
% or by calling \cs{adjustlogos}.
%
% For example, either of the following sets the default \pkg{metalogo} logo adjustments:
% \begin{sourcedisplay}
% \cs{usepackage}[\textblue{default}]\{metalogox\} \\
% \fqquad\textrm{--- or ---} \\
% \cs{adjustlogos}\{\textblue{default}\}
% \end{sourcedisplay}
%
% \DescribeOption{default} The \LaTeX\ and \pkg{metalogo} default settings.
%    \begin{macrocode}
\newcommand*{\MLX@default}{%
    \setlogokern{Te}{-0.1667em}%
    \setlogokern{eX}{-0.125em}%
    \setlogokern{La}{-.36em}%
    \setlogokern{aT}{-.15em}%
    \setlogokern{Xe}{-.125em}%
    \setlogokern{eT}{-.1667em}%
    \setlogokern{eL}{-.125em}%
    \setlogodrop{0.5ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{accanthis}
%    \begin{macrocode}
\newcommand*{\MLX@accanthis}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.05em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.25ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{alegreya}
%    \begin{macrocode}
\newcommand*{\MLX@alegreya}{%
    \setlogokern{Te}{-0.14em}%
    \setlogokern{eX}{-0.12em}%
    \setlogokern{La}{-.23em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.12em}%
    \setlogodrop{0.36ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{algolrevived}
%    \begin{macrocode}
\newcommand*{\MLX@algolrevived}{%
    \setlogokern{Te}{-0.17em}%
    \setlogokern{eX}{-0.17em}%
    \setlogokern{La}{-.40em}%
    \setlogokern{aT}{-.06em}%
    \setlogokern{Xe}{-.18em}%
    \setlogokern{eT}{-.18em}%
    \setlogokern{eL}{-.12em}%
    \setlogodrop{0.28ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{antpolt}
%    \begin{macrocode}
\newcommand*{\MLX@antpolt}{%
    \setlogokern{Te}{-0.09em}%
    \setlogokern{eX}{-0.08em}%
    \setlogokern{La}{-.33em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.36ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{avantgarde}
%    \begin{macrocode}
\newcommand*{\MLX@avantgarde}{%
    \setlogokern{Te}{-0.10em}%
    \setlogokern{eX}{-0.04em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.10em}%
    \setlogokern{Xe}{-.04em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.02em}%
    \setlogodrop{0.40ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{baskerville}
%    \begin{macrocode}
\newcommand*{\MLX@baskerville}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.07em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.36ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{berenis}
%    \begin{macrocode}
\newcommand*{\MLX@berenis}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.23em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.02em}%
    \setlogodrop{0.58ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{bodoni} Also see \optn{librebodoni}.
%    \begin{macrocode}
\newcommand*{\MLX@bodoni}{%
    \setlogokern{Te}{-0.11em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.10em}%
    \setlogodrop{0.37ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{boisik}
%    \begin{macrocode}
\newcommand*{\MLX@boisik}{%
    \setlogokern{Te}{-0.09em}%
    \setlogokern{eX}{-0.07em}%
    \setlogokern{La}{-.35em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.55ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{bookman}
%    \begin{macrocode}
\newcommand*{\MLX@bookman}{%
    \setlogokern{Te}{-0.03em}%
    \setlogokern{eX}{-0.035em}%
    \setlogokern{La}{-.25em}%
    \setlogokern{aT}{-.00em}%
    \setlogokern{Xe}{-.030em}%
    \setlogokern{eT}{-.02em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.36ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{charter}
%    \begin{macrocode}
\newcommand*{\MLX@charter}{%
    \setlogokern{Te}{-0.10em}%
    \setlogokern{eX}{-0.07em}%
    \setlogokern{La}{-.24em}%
    \setlogokern{aT}{-.06em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.28ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{crimson}
%    \begin{macrocode}
\newcommand*{\MLX@crimson}{%
    \setlogokern{Te}{-0.05em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.23em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.05em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.36ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{coelacanth}
%    \begin{macrocode}
\newcommand*{\MLX@coelacanth}{%
    \setlogokern{Te}{-0.09em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.32ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{didot}
%    \begin{macrocode}
\newcommand*{\MLX@didot}{%
    \setlogokern{Te}{-0.11em}%
    \setlogokern{eX}{-0.09em}%
    \setlogokern{La}{-.34em}%
    \setlogokern{aT}{-.11em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.12em}%
    \setlogokern{eL}{-.09em}%
    \setlogodrop{0.44ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{droidserif}
%    \begin{macrocode}
\newcommand*{\MLX@droidserif}{%
    \setlogokern{Te}{-0.11em}%
    \setlogokern{eX}{-0.10em}%
    \setlogokern{La}{-.30em}%
    \setlogokern{aT}{-.08em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.08em}%
    \setlogodrop{0.30ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{droidsans}
%    \begin{macrocode}
\newcommand*{\MLX@droidsans}{%
    \setlogokern{Te}{-0.11em}%
    \setlogokern{eX}{-0.10em}%
    \setlogokern{La}{-.24em}%
    \setlogokern{aT}{-.08em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.08em}%
    \setlogodrop{0.30ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{gentium}
%    \begin{macrocode}
\newcommand*{\MLX@gentium}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.07em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.06em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.24ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{helvetica}
%    \begin{macrocode}
\newcommand*{\MLX@helvetica}{%
    \setlogokern{Te}{-0.15em}%
    \setlogokern{eX}{-0.08em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.08em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.15em}%
    \setlogokern{eL}{-.04em}%
    \setlogodrop{0.40ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{kerkis}
%    \begin{macrocode}
\newcommand*{\MLX@kerkis}{%
    \setlogokern{Te}{-0.02em}%
    \setlogokern{eX}{-0.02em}%
    \setlogokern{La}{-.25em}%
    \setlogokern{aT}{-.00em}%
    \setlogokern{Xe}{-.00em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.05em}%
    \setlogodrop{0.38ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{kpfonts}
%    \begin{macrocode}
\newcommand*{\MLX@kpfonts}{%
    \setlogokern{Te}{-0.11em}%
    \setlogokern{eX}{-0.08em}%
    \setlogokern{La}{-.30em}%
    \setlogokern{aT}{-.11em}%
    \setlogokern{Xe}{-.10em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.33ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{libertine} Also see \optn{libertinus}, below.
%    \begin{macrocode}
\newcommand*{\MLX@libertine}{%
    \setlogokern{Te}{-0.05em}%
    \setlogokern{eX}{-0.06em}%
    \setlogokern{La}{-.25em}%
    \setlogokern{aT}{-.05em}%
    \setlogokern{Xe}{-.05em}%
    \setlogokern{eT}{-.05em}%
    \setlogokern{eL}{-.02em}%
    \setlogodrop{0.32ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{libertinus} There is a difference
%       in the raised `A' vs. \pkg{libertine}.
%    \begin{macrocode}
\newcommand*{\MLX@libertinus}{%
    \setlogokern{Te}{-0.05em}%
    \setlogokern{eX}{-0.06em}%
    \setlogokern{La}{-.28em}%
    \setlogokern{aT}{-.05em}%
    \setlogokern{Xe}{-.05em}%
    \setlogokern{eT}{-.05em}%
    \setlogokern{eL}{-.02em}%
    \setlogodrop{0.32ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{librebodoni} Specific to \pkg{LibreBodoni} only.
%    \begin{macrocode}
\newcommand*{\MLX@librebodoni}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.02em}%
    \setlogodrop{0.49ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{lmodern}
%    \begin{macrocode}
\newcommand*{\MLX@lmodern}{%
    \setlogokern{Te}{-0.10em}%
    \setlogokern{eX}{-0.06em}%
    \setlogokern{La}{-.33em}%
    \setlogokern{aT}{-.15em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.08em}%
    \setlogodrop{0.52ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{lmodernsans}
%    \begin{macrocode}
\newcommand*{\MLX@lmodernsans}{%
    \setlogokern{Te}{-0.20em}%
    \setlogokern{eX}{-0.06em}%
    \setlogokern{La}{-.29em}%
    \setlogokern{aT}{-.12em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.20em}%
    \setlogokern{eL}{-.08em}%
    \setlogodrop{0.45ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{merriweather}
%    \begin{macrocode}
\newcommand*{\MLX@merriweather}{%
    \setlogokern{Te}{-0.09em}%
    \setlogokern{eX}{-0.09em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.32ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{newcent}
%    \begin{macrocode}
\newcommand*{\MLX@newcent}{%
    \setlogokern{Te}{-0.08em}%
    \setlogokern{eX}{-0.09em}%
    \setlogokern{La}{-.30em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.07em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.49ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{noto}
%    \begin{macrocode}
\newcommand*{\MLX@noto}{%
    \setlogokern{Te}{-0.11em}%
    \setlogokern{eX}{-0.10em}%
    \setlogokern{La}{-.30em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.10em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.26ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{palatino}
%    \begin{macrocode}
\newcommand*{\MLX@palatino}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.09em}%
    \setlogokern{La}{-.33em}%
    \setlogokern{aT}{-.10em}%
    \setlogokern{Xe}{-.09em}%
    \setlogokern{eT}{-.08em}%
    \setlogokern{eL}{-.07em}%
    \setlogodrop{0.35ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{pandora}
%    \begin{macrocode}
\newcommand*{\MLX@pandora}{%
    \setlogokern{Te}{-0.09em}%
    \setlogokern{eX}{-0.08em}%
    \setlogokern{La}{-.32em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.08em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.53ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{paratype}
%    \begin{macrocode}
\newcommand*{\MLX@paratype}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.10em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.34ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{plexserif}%
%    \begin{macrocode}
\newcommand*{\MLX@plexserif}{%
    \setlogokern{Te}{-0.1667em}%
    \setlogokern{eX}{-0.125em}%
    \setlogokern{La}{-.30em}%
    \setlogokern{aT}{-.10em}%
    \setlogokern{Xe}{-.125em}%
    \setlogokern{eT}{-.16em}%
    \setlogokern{eL}{-.10em}%
    \setlogodrop{0.5ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{plexsans}%
%    \begin{macrocode}
\newcommand*{\MLX@plexsans}{%
    \setlogokern{Te}{-0.1667em}%
    \setlogokern{eX}{-0.10em}%
    \setlogokern{La}{-.25em}%
    \setlogokern{aT}{-.10em}%
    \setlogokern{Xe}{-.10em}%
    \setlogokern{eT}{-.17em}%
    \setlogokern{eL}{-.10em}%
    \setlogodrop{0.5ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{quattrocento}
% Compromises must be made here.
% It appears that the height of |1ex| is incorrect for serif with \XeLaTeX, \LuaLaTeX.
%    \begin{macrocode}
\newcommand*{\MLX@quattrocento}{%
    \setlogokern{Te}{-0.09em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.26em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{.4ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{sourceserifpro}
%    \begin{macrocode}
\newcommand*{\MLX@sourceserifpro}{%
    \setlogokern{Te}{-0.12em}%
    \setlogokern{eX}{-0.09em}%
    \setlogokern{La}{-.29em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.09em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.09em}%
    \setlogodrop{0.30ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{sourcesanspro}
%    \begin{macrocode}
\newcommand*{\MLX@sourcesanspro}{%
    \setlogokern{Te}{-0.12em}%
    \setlogokern{eX}{-0.09em}%
    \setlogokern{La}{-.22em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.09em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.09em}%
    \setlogodrop{0.30ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{times}
%    \begin{macrocode}
\newcommand*{\MLX@times}{%
    \setlogokern{Te}{-0.06em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.28em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.06em}%
    \setlogokern{eL}{-.02em}%
    \setlogodrop{0.34ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{utopia}
%    \begin{macrocode}
\newcommand*{\MLX@utopia}{%
    \setlogokern{Te}{-.08em}%
    \setlogokern{eX}{-0.04em}%
    \setlogokern{La}{-.21em}%
    \setlogokern{aT}{-.10em}%
    \setlogokern{Xe}{-.02em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.30ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{venturis}
%    \begin{macrocode}
\newcommand*{\MLX@venturis}{%
    \setlogokern{Te}{-0.07em}%
    \setlogokern{eX}{-0.05em}%
    \setlogokern{La}{-.22em}%
    \setlogokern{aT}{-.07em}%
    \setlogokern{Xe}{-.06em}%
    \setlogokern{eT}{-.06em}%
    \setlogokern{eL}{-.06em}%
    \setlogodrop{0.36ex}%
}
%    \end{macrocode}
%
%
% \DescribeOption{vera}
%    \begin{macrocode}
\newcommand*{\MLX@vera}{%
    \setlogokern{Te}{-0.12em}%
    \setlogokern{eX}{-0.14em}%
    \setlogokern{La}{-.32em}%
    \setlogokern{aT}{-.05em}%
    \setlogokern{Xe}{-.14em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.10em}%
    \setlogodrop{0.235ex}%
}
%    \end{macrocode}
%
% \DescribeOption{verasans}
%    \begin{macrocode}
\newcommand*{\MLX@verasans}{%
    \setlogokern{Te}{-0.12em}%
    \setlogokern{eX}{-0.10em}%
    \setlogokern{La}{-.28em}%
    \setlogokern{aT}{-.05em}%
    \setlogokern{Xe}{-.10em}%
    \setlogokern{eT}{-.10em}%
    \setlogokern{eL}{-.10em}%
    \setlogodrop{0.35ex}%
}
%    \end{macrocode}
%
%
%
%
% \subsubsection{Common synonyms}
%
% Synonyms for commonly-used fonts.
%
% \DescribeOption{tgbonum}
%    \begin{macrocode}
\newcommand*{\MLX@tgbonum}{\MLX@bookman}
%    \end{macrocode}
%
%
% \DescribeOption{tgheros}
%    \begin{macrocode}
\newcommand*{\MLX@tgheros}{\MLX@helvetica}
%    \end{macrocode}
%
%
% \DescribeOption{tgpagella}
%    \begin{macrocode}
\newcommand*{\MLX@tgpagella}{\MLX@palatino}
%    \end{macrocode}
%
%
% \DescribeOption{tgschola}
%    \begin{macrocode}
\newcommand*{\MLX@tgschola}{\MLX@newcent}
%    \end{macrocode}
%
%
% \DescribeOption{tgtermes}
%    \begin{macrocode}
\newcommand*{\MLX@tgtermes}{\MLX@times}
%    \end{macrocode}
%
%
%
% \subsubsection{Similar fonts}
%
% The following work well enough that a separate definition is probably
% not necessary.
%
% \DescribeOption{antiqua}
%    \begin{macrocode}
\newcommand*{\MLX@antiqua}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{anttor}
%    \begin{macrocode}
\newcommand*{\MLX@anttor}{\MLX@antpolt}
%    \end{macrocode}
%
%
% \DescribeOption{artemisia}
%    \begin{macrocode}
\newcommand*{\MLX@artemisia}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{caladea}
%    \begin{macrocode}
\newcommand*{\MLX@caladea}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{caslon}
%    \begin{macrocode}
\newcommand*{\MLX@caslon}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{cochineal}
%    \begin{macrocode}
\newcommand*{\MLX@cochineal}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{concmath}
%    \begin{macrocode}
\newcommand*{\MLX@concmath}{\MLX@lmodern}
%    \end{macrocode}
%
%
% \DescribeOption{drm}
%    \begin{macrocode}
\newcommand*{\MLX@drm}{\MLX@lmodern}
%    \end{macrocode}
%
%
% \DescribeOption{garamond}
%    \begin{macrocode}
\newcommand*{\MLX@garamond}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{imfellenglish}
%    \begin{macrocode}
\newcommand*{\MLX@imfellenglish}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{literat}
%    \begin{macrocode}
\newcommand*{\MLX@literat}{\MLX@baskerville}
%    \end{macrocode}
%
%
% \DescribeOption{roboto}
%    \begin{macrocode}
\newcommand*{\MLX@roboto}{\MLX@pandora}
%    \end{macrocode}
%
%
% \DescribeOption{romande}
%    \begin{macrocode}
\newcommand*{\MLX@romande}{\MLX@baskerville}
%    \end{macrocode}
%
%
%
% \subsection{Manual adjust selection}
%
% \begin{macro}{\adjustlogos} \marg{package option}
%
% If the given option matches a predefined \cs{MLX@...} macro, use it.
%
%    \begin{macrocode}
\newcommand*{\adjustlogos}[1]{%
    \ifcsdef{MLX@#1}{%
        \PackageInfo{metalogox}{Setting #1}%
        \csuse{MLX@#1}%
    }{%
        \PackageError{metalogox}{Unknown setting #1}%
        {See the metalogox documentation for a list of options.}%
    }%
}
%    \end{macrocode}
% \end{macro}
%
%
% \subsection{Font detection}
%

% \DescribeBoolean{MLX@@foundfont} Found the font?
% \changes{v1.03}{2024/01/18}{Warning if font was not found.}
%    \begin{macrocode}
\newbool{MLX@@foundfont}
%    \end{macrocode}


% \begin{macro}{\MLX@@detectvariant}
%   \marg{1: family} \marg{2: variant} \marg{3: name} \marg{4: setting}
%
% If the font variant matches, adjust accordingly.
%
% (The doubled |@| is to distinguish this from a valid \pkg{metalogox} option.)
%
% \changes{v1.03}{2024/01/18}{Warning if font was not found.}
%    \begin{macrocode}
\newcommand*{\MLX@@detectvariant}[4]{%
\ifdefstring{\MLX@@thisfont}{#1#2}{%
    \booltrue{MLX@@foundfont}%
    \PackageInfo{metalogox}{Detected #1#2, #3.  Using #4}%
    \adjustlogos{#4}%
}{}%
}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\MLX@@detectone} \marg{1: family} \marg{2: name} \marg{3: setting}
%
% Tests variants.
% If a font family and variant matches, select the \pkg{metalogox} option.
%
% (The doubled |@| is to distinguish this from a valid \pkg{metalogox} option.)
%    \begin{macrocode}
\NewDocumentCommand{\MLX@@detectone}{m m m}{%
\MLX@@detectvariant{#1}{}{#2}{#3}%
\MLX@@detectvariant{#1}{-TLF}{#2}{#3}%
\MLX@@detectvariant{#1}{-LF}{#2}{#3}%
\MLX@@detectvariant{#1}{-OsF}{#2}{#3}%
\MLX@@detectvariant{#1}{-TOsF}{#2}{#3}%
\MLX@@detectvariant{#1}{Condensed-TLF}{#2}{#3}%
\MLX@@detectvariant{#1}{Condensed-LF}{#2}{#3}%
\MLX@@detectvariant{#1}{Condensed-OsF}{#2}{#3}%
\MLX@@detectvariant{#1}{Condensed-TOsF}{#2}{#3}%
\MLX@@detectvariant{#1}{(0)}{#2}{#3}%
\MLX@@detectvariant{#1}{(1)}{#2}{#3}%
}
%    \end{macrocode}
% \end{macro}
%
%
% \begin{macro}{\autoadjustlogos} *
%
% Search a list of fonts and variants, looking for a match with the current one.
%    \begin{macrocode}
\NewDocumentCommand{\autoadjustlogos}{s}{%
%    \end{macrocode}
%
% Not yet discovered the font:
%    \begin{macrocode}
\boolfalse{MLX@@foundfont}%
%    \end{macrocode}
%
% If starred, use the text body font, else use the local font:
%    \begin{macrocode}
\IfBooleanTF{#1}{%
    \edef\MLX@@thisfont{\familydefault}%
}{%
    \edef\MLX@@thisfont{\f@family}%
}%
%    \end{macrocode}
%
% Announce the desired font:
%    \begin{macrocode}
\PackageInfo{metalogox}{Searching for \MLX@@thisfont}%
%    \end{macrocode}
%
% Default if nothing is found:
%    \begin{macrocode}
\adjustlogos{lmodern}%
%    \end{macrocode}
%
% Seach a list of possibilities:
% \changes{v1.03}{2024/01/19}{Updated many fonts for changed family names.}
% \changes{v1.05}{2024/03/01}{Fixed Erewhon.}
% \changes{v1.06}{2024/03/04}{Improved detection of Archiv0,
%               Atkinson Hyperlegible, Cuprum, Eczar, Ibarra, Nunito.}
% \changes{v1.07}{2025/01/23}{Added arsenal.}
%    \begin{macrocode}
\MLX@@detectone{AccanthisADFStdNoThree}{accanthis}{accanthis}%
\MLX@@detectone{AccanthisADFStdNo3}{accanthis}{accanthis}%
\MLX@@detectone{Alegreya}{Alegreya}{alegreya}%
\MLX@@detectone{AlegreyaSans}{AlegreyaSans}{alegreya}%
\MLX@@detectone{AlgolRevived}{algolrevived}{algolrevived}%
\MLX@@detectone{uaq}{antiqua}{baskerville}%
\MLX@@detectone{antp}{antpolt}{antpolt}%
\MLX@@detectone{AntykwaPoltawskiego}{antpolt}{antpolt}%
\MLX@@detectone{antt}{anttor}{antpolt}%%
\MLX@@detectone{AntykwaTorunska}{anttor}{antpolt}%
\MLX@@detectone{ArchivZero}{Archiv0}{helvetica}%
\MLX@@detectone{Archiv0}{Archiv0}{helvetica}%
\MLX@@detectone{arsenal}{Arsenal}{alegreya}%
\MLX@@detectone{fav}{arev}{vera}%
\MLX@@detectone{Arimo}{Arimo}{helvetica}%
\MLX@@detectone{atkinsn}{Atkinson Hyperlegible}{helvetica}%
\MLX@@detectone{AtkinsonHyperlegible}{Atkinson Hyperlegible}{helvetica}%
\MLX@@detectone{pag}{Avant Garde}{avantgarde}%
\MLX@@detectone{qag}{tgadventor}{avantgarde}%
\MLX@@detectone{ybv}{baskervald}{baskerville}%
\MLX@@detectone{ybvw}{baskervald}{baskerville}%
\MLX@@detectone{Baskervaldx}{Baskervaldx}{baskerville}%
\MLX@@detectone{BaskervilleF}{baskervillef}{baskerville}%
\MLX@@detectone{fve}{beraserif}{vera}%
\MLX@@detectone{fvs}{berasans}{verasans}%
\MLX@@detectone{ybd}{berenis}{berenis}%
\MLX@@detectone{ybd2}{berenis}{berenis}%
\MLX@@detectone{ybd2j}{berenis}{berenis}%
\MLX@@detectone{ybdj}{berenis}{berenis}%
\MLX@@detectone{BerenisADFPro}{berenis}{berenis}%
\MLX@@detectone{LinuxBiolinumT}{biolinum}{helvetica}%
\MLX@@detectone{Cabin}{Cabin}{helvetica}%
\MLX@@detectone{CabinCondensed}{CabinCondensed}{helvetica}%
\MLX@@detectone{Caladea}{caladea}{baskerville}%
\MLX@@detectone{cantarell}{cantarell}{helvetica}%
\MLX@@detectone{Crlt}{Carlito}{crimson}%
\MLX@@detectone{Carlito}{Carlito}{crimson}%
\MLX@@detectone{charssil}{CharisSIL}{times}%
\MLX@@detectone{CharisSIL}{CharisSIL}{times}%
\MLX@@detectone{mdbch}{mdbch - Math Design Bitstream Charter}{charter}%
\MLX@@detectone{Chivo}{Chivo}{helvetica}%
\MLX@@detectone{ClearSans}{Clear Sans}{helvetica}%
\MLX@@detectone{Cochineal}{cochineal}{baskerville}%
\MLX@@detectone{Coelacanth}{coelacanth}{coelacanth}%
\MLX@@detectone{comfortaa}{comfortaa}{avantgarde}%
\MLX@@detectone{ComicNeue}{comicneue}{avantgarde}%
\MLX@@detectone{cmbr}{Computer Modern Bright}{lmodern}%
\MLX@@detectone{lcmss}{Computer Modern Sans Quote}{lmodern}%
\MLX@@detectone{cmr}{Computer Modern Roman}{lmodern}%
\MLX@@detectone{cmss}{Computer Modern Sans}{lmodernsans}%
\MLX@@detectone{ccr}{concmath}{lmodern}%
\MLX@@detectone{CormorantGaramond}{CormorantGaramond}{garamond}%
\MLX@@detectone{Crimson}{crimson}{crimson}%
\MLX@@detectone{CrimsonPro}{CrimsonPro}{crimson}%
\MLX@@detectone{cpr}{Cuprum}{utopia}%
\MLX@@detectone{Cuprum}{Cuprum}{utopia}%
\MLX@@detectone{cyklop}{Cyklop}{lmodern}%
\MLX@@detectone{DejaVuSerif}{DejaVuSerif}{vera}%
\MLX@@detectone{DejaVuSerifCondensed}{DejaVuSerif Condensed}{vera}%
\MLX@@detectone{DejaVuSans}{DejaVuSans}{verasans}%
\MLX@@detectone{drm}{DRM}{lmodern}%
\MLX@@detectone{droidserif}{Droid Serif}{droidserif}%%
\MLX@@detectone{droidsans}{Droid Sans}{droidsans}%%
\MLX@@detectone{DroidSerif}{Droid Serif}{droidserif}%%
\MLX@@detectone{DroidSans}{Droid Sans}{droidsans}%%
\MLX@@detectone{EBGaramond}{EB Garamond}{garamond}%
\MLX@@detectone{EBGaramond12}{EB Garamond}{garamond}%
\MLX@@detectone{Eczar}{Eczar}{times}%
\MLX@@detectone{erewhon}{erewhon}{utopia}%
\MLX@@detectone{Erewhon}{erewhon}{utopia}%
\MLX@@detectone{fbb}{fbb}{baskerville}%
\MLX@@detectone{FiraSans}{Fira Sans}{helvetica}%
\MLX@@detectone{FiraSansBook}{Fira Sans}{helvetica}%
\MLX@@detectone{FiraSansThin}{Fira Sans}{helvetica}%
\MLX@@detectone{FiraSansLight}{Fira Sans}{helvetica}%
\MLX@@detectone{FiraSansExtraLight}{Fira Sans}{helvetica}%
\MLX@@detectone{FiraSansUltraLight}{Fira Sans}{helvetica}%
\MLX@@detectone{futs}{fourier}{utopia}%
\MLX@@detectone{fnc}{fouriernc}{newcent}%
\MLX@@detectone{gentium}{gentium}{gentium}%
\MLX@@detectone{GentiumPlus}{gentium}{gentium}%
\MLX@@detectone{artemisia}{gfsartemisia}{baskerville}%
\MLX@@detectone{GFSArtemisia}{gfsartemisia}{baskerville}%
\MLX@@detectone{artemisiaeuler}{gfsartemisia}{baskerville}%
\MLX@@detectone{bodoni}{gfsbodoni}{bodoni}%
\MLX@@detectone{GFSBodoni}{gfsbodoni}{bodoni}%
\MLX@@detectone{udidot}{gfsdidot}{didot}%
\MLX@@detectone{FreeSerif}{GNU Freeserif}{times}%
\MLX@@detectone{FreeSans}{GNU Freesans}{helvetica}%
\MLX@@detectone{neohellenic}{GFS Neohellenic}{helvetica}%
\MLX@@detectone{GFSNeohellenic}{GFS Neohellenic}{helvetica}%
\MLX@@detectone{Gillius}{Gillius}{avantgarde}%
\MLX@@detectone{GilliusADF}{Gillius}{avantgarde}%
\MLX@@detectone{GilliusADFCond}{Gillius}{avantgarde}%
\MLX@@detectone{GilliusADFNo2}{Gillius}{avantgarde}%
\MLX@@detectone{GilliusADFNo2Cond}{Gillius}{avantgarde}%
\MLX@@detectone{Go}{Go Sans}{helvetica}%
\MLX@@detectone{phv}{helvet}{helvetica}%
\MLX@@detectone{Heuristica}{heuristica}{utopia}%
\MLX@@detectone{heuristica}{heuristica}{utopia}%
\MLX@@detectone{IbarraRealNova}{Ibarra}{times}%
\MLX@@detectone{IMFELLEnglish}{imfellEnglish}{baskerville}%
\MLX@@detectone{InriaSans}{Inria Sans}{helvetica}%
\MLX@@detectone{InriaSerif}{Inria Serif}{baskerville}%
\MLX@@detectone{Inter}{Inter}{helvetica}%
\MLX@@detectone{iwona}{Iwona}{helvetica}%
\MLX@@detectone{Iwona}{Iwona}{helvetica}%
\MLX@@detectone{IwonaLight}{Iwona}{helvetica}%
\MLX@@detectone{IwonaMedium}{Iwona}{helvetica}%
\MLX@@detectone{IwonaHeavy}{Iwona}{helvetica}%
\MLX@@detectone{IwonaCond}{Iwona}{helvetica}%
\MLX@@detectone{IwonaCondLight}{Iwona}{helvetica}%
\MLX@@detectone{IwonaCondMedium}{Iwona}{helvetica}%
\MLX@@detectone{IwonaCondHeavy}{Iwona}{helvetica}%
\MLX@@detectone{Junicode}{Junicode}{times}%
\MLX@@detectone{mak}{kerkis}{kerkis}%
\MLX@@detectone{maksf}{kerkis sans}{kerkis}%
\MLX@@detectone{jkp}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpk}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpkf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpkfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpkos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpkosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpkvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpl}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplk}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplkf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplkfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplkos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplkosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplkvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkplvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkposn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpss}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpssf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpssfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpssk}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpsskf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpsskfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpsskos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpsskosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpsskvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpssos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpssosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpssvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkptt}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpttos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpttosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpttvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpx}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxk}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxkf}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxkfosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxkos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxkosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxkvos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxos}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxosn}{kpfonts}{kpfonts}%
\MLX@@detectone{jkpxvos}{kpfonts}{kpfonts}%
\MLX@@detectone{JosefinSans}{Josefin}{lmodern}%
\MLX@@detectone{kurier}{Kurier}{helvetica}%
\MLX@@detectone{Kurier}{Kurier}{helvetica}%
\MLX@@detectone{KurierLight}{Kurier}{helvetica}%
\MLX@@detectone{KurierMedium}{Kurier}{helvetica}%
\MLX@@detectone{KurierHeavy}{Kurier}{helvetica}%
\MLX@@detectone{KurierCond}{Kurier}{helvetica}%
\MLX@@detectone{KurierCondLight}{Kurier}{helvetica}%
\MLX@@detectone{KurierCondMedium}{Kurier}{helvetica}%
\MLX@@detectone{KurierCondHeavy}{Kurier}{helvetica}%
\MLX@@detectone{lato}{Lato}{helvetica}%
\MLX@@detectone{Lato}{Lato}{helvetica}%
\MLX@@detectone{lmr}{lmodern}{lmodern}%
\MLX@@detectone{mlmr}{MLModern}{lmodern}%
\MLX@@detectone{mlmss}{MLModern}{lmodern}%
\MLX@@detectone{lmss}{lmodern sans}{lmodernsans}%
\MLX@@detectone{lmssq}{lmodern sans}{lmodernsans}%
\MLX@@detectone{LatinModernRoman}{Latin Modern Roman}{lmodern}%
\MLX@@detectone{LatinModernSans}{Latin Modern Sans}{lmodernsans}%
\MLX@@detectone{LinuxLibertineT}{libertine}{libertine}%
\MLX@@detectone{LinLibertine}{libertine}{libertine}%
\MLX@@detectone{LinBiolinum}{libertine}{helvetica}%
\MLX@@detectone{LibertinusSerif}{libertinus-type1}{libertinus}%
\MLX@@detectone{LibertinusSans}{libertinus-type1}{helvetica}%
\MLX@@detectone{libertinusserif}{libertinus-otf}{libertinus}%
\MLX@@detectone{libertinussans}{libertinus-otf}{helvetica}%
\MLX@@detectone{LibreBskvl}{librebaskerville}{baskerville}%
\MLX@@detectone{LibreBaskerville}{librebaskerville}{baskerville}%
\MLX@@detectone{LibreBodoni}{LibreBodoni}{librebodoni}%
\MLX@@detectone{LibreCaslonText}{Libre Caslon}{baskerville}%
\MLX@@detectone{LibreCsln}{Libre Caslon}{baskerville}%
\MLX@@detectone{yly}{libris}{avantgarde}%
\MLX@@detectone{llcmss}{LX Fonts}{avantgarde}%
\MLX@@detectone{ptm}{mathptmx}{times}%
\MLX@@detectone{ppl}{mathpazo}{palatino}%
\MLX@@detectone{bch}{mdbch}{charter}%
\MLX@@detectone{mdput}{mdput - Math Design Utopia}{utopia}%
\MLX@@detectone{mdugm}{mdugm - Math Design URW Garamond}{baskerville}%
\MLX@@detectone{Merriwthr}{merriweather}{merriweather}%
\MLX@@detectone{MerriwthrSans}{merriweather}{merriweather}%
\MLX@@detectone{Merriweather}{merriweather}{merriweather}%
\MLX@@detectone{MerriweatherSans}{merriweather}{merriweather}%
\MLX@@detectone{MintSpirit}{Mint Spirit}{avantgarde}%
\MLX@@detectone{MintSpiritNoTwo}{Mint Spirit No 2}{avantgarde}%
\MLX@@detectone{MintSpiritNo2}{Mint Spirit No 2}{avantgarde}%
\MLX@@detectone{Montserrat}{Montserrat}{helvetica}%
\MLX@@detectone{MontserratAlternates}{Montserrat}{helvetica}%
\MLX@@detectone{pnc}{newcent}{newcent}%
\MLX@@detectone{zpltlf}{newpxtext}{palatino}%
\MLX@@detectone{minntx}{newtxtext}{times}%
\MLX@@detectone{ntxtlf}{newtxtext}{times}%
\MLX@@detectone{nimbussans}{nimbussans}{helvetica}%
\MLX@@detectone{NimbusSans}{nimbusserif}{helvetica}%
\MLX@@detectone{NimbusSerif}{nimbusserif}{times}%
\MLX@@detectone{NimbusSansL}{nimbussans}{helvetica}%
\MLX@@detectone{ztm}{nimbusserif}{times}%
\MLX@@detectone{zhv}{nimbussans}{helvetica}%
\MLX@@detectone{NotoSerif}{noto}{noto}%
\MLX@@detectone{NotoSans}{noto}{noto}%
\MLX@@detectone{Nunito}{Nunito}{helvetica}%
\MLX@@detectone{OldStandard}{Old Standard}{didot}%
\MLX@@detectone{fosj}{opensans}{avantgarde}%
\MLX@@detectone{opensans}{opensans}{avantgarde}%
\MLX@@detectone{OpenSans}{Open Sans}{avantgarde}%
\MLX@@detectone{Zeroswald}{Oswald}{utopia}%
\MLX@@detectone{Ovrlck}{Overlock}{avantgarde}% bug with XeLaTeX%
\MLX@@detectone{Overlock}{Overlock}{avantgarde}% bug with XeLaTeX%
\MLX@@detectone{panr}{pandora}{pandora}%
\MLX@@detectone{pss}{pandora}{pandora}%
\MLX@@detectone{PTSerif}{paratype}{paratype}%
\MLX@@detectone{PTSans}{paratype}{paratype}%
\MLX@@detectone{PTSansNarrow}{paratype}{paratype}%
\MLX@@detectone{IBMPlexSerif}{plex-serif}{plexserif}%
\MLX@@detectone{IBMPlexSans}{plex-sans}{plexsans}%
\MLX@@detectone{pxr}{pxfonts}{palatino}%
\MLX@@detectone{pxss}{pxfonts}{helvetica}%
\MLX@@detectone{Quattro}{quattrocento}{quattrocento}%
\MLX@@detectone{QuattroSans}{quattrocento}{quattrocento}%
\MLX@@detectone{Quattrocento}{quattrocento}{quattrocento}%
\MLX@@detectone{QuattrocentoSans}{quattrocento}{quattrocento}%
\MLX@@detectone{Raleway}{raleway}{helvetica}%
\MLX@@detectone{Roboto}{roboto}{helvetica}%
\MLX@@detectone{RobotoSlab}{roboto}{roboto}%
\MLX@@detectone{RobotoCondensed}{roboto}{helvetica}%
\MLX@@detectone{yrd}{romande}{baskerville}%
\MLX@@detectone{yrda}{romande}{baskerville}%
\MLX@@detectone{yrdw}{romande}{baskerville}% todo swash style%
\MLX@@detectone{yrdaw}{romande}{baskerville}% todo swash style%
\MLX@@detectone{Shobhika}{Shobhika}{paratype}%
\MLX@@detectone{SourceSerifPro}{sourceserifpro}{sourceserifpro}%
\MLX@@detectone{SourceSansPro}{sourcesanspro}{sourcesanspro}%
\MLX@@detectone{SticksTooText}{stickstootext}{times}%
\MLX@@detectone{stix}{stix}{times}%
\MLX@@detectone{stix2}{stix2}{times}%
\MLX@@detectone{STIXTwoText}{stix2}{times}%
\MLX@@detectone{pbk}{bookman}{bookman}%
\MLX@@detectone{qbk}{tgbonum}{bookman}%
\MLX@@detectone{qhv}{tgheros}{helvetica}%
\MLX@@detectone{qpl}{tgpagella}{palatino}%
\MLX@@detectone{qcs}{tgschola}{newcent}%
\MLX@@detectone{qtm}{tgtermes}{times}%
\MLX@@detectone{TeXGyreAdventor}{TeX Gyre Adventor}{avantgarde}%
\MLX@@detectone{TeXGyreBonum}{TeX Gyre Bonum}{bookman}%
\MLX@@detectone{TeXGyreHeros}{TeX Gyre Heros}{helvetica}%
\MLX@@detectone{TeXGyrePagella}{TeX Gyre Pagella}{palatino}%
\MLX@@detectone{TeXGyreSchola}{TeX Gyre Schola}{newcent}%
\MLX@@detectone{TeXGyreTermes}{TeX Gyre Termes}{times}%
\MLX@@detectone{txr}{txfonts}{times}%
\MLX@@detectone{txss}{txfonts}{times}%
\MLX@@detectone{UniversalisADFStd}{Universalis ADF Std}{crimson}%
\MLX@@detectone{ugq}{URW Grotesk}{crimson}%
\MLX@@detectone{put}{utopia}{utopia}%
\MLX@@detectone{yvt}{venturis}{venturis}%
\MLX@@detectone{yvtj}{venturis}{venturis}%
\MLX@@detectone{yvtw}{venturis}{venturis}%
\MLX@@detectone{yvtjw}{venturis}{venturis}%
\MLX@@detectone{yvtaw}{venturis}{venturis}%
\MLX@@detectone{yvtajw}{venturis}{venturis}%
\MLX@@detectone{yv1}{venturissans}{venturis}%
\MLX@@detectone{yv2}{venturis2}{venturis}%
\MLX@@detectone{yv3}{venturissans2}{venturis}%
\MLX@@detectone{yvo}{venturisold}{venturis}%
\MLX@@detectone{yvoa}{venturisold}{venturis}%
\MLX@@detectone{XCharter}{XCharter}{charter}%
\MLX@@detectone{XITS}{XITS}{times}%
%    \end{macrocode}
%
% Warning if font was not found:
% \changes{v1.03}{2024/01/18}{Warning if font was not found.}
%    \begin{macrocode}
\ifbool{MLX@@foundfont}%
    {}%
    {%
        \PackageWarningNoLine{metalogox}
            {%
                Did not find font \MLX@@thisfont.\MessageBreak%
                To improve \string\LaTeX, and related logos:\MessageBreak%
                \string\usepackage[option]{metalogox}\MessageBreak%
                Common options: times, bookman for serif,\MessageBreak%
                helvetica, avantgarde for sans%
            }
    }
}
%    \end{macrocode}
% \end{macro}
%
%
% \subsection{Option declaration}
%
%    \begin{macrocode}
\DeclareOption*{%
    \adjustlogos{\CurrentOption}%
}
%    \end{macrocode}
%
%
% \subsection{Default settings}
%
% Adjust according to the text body font, if detected, or use defaults otherwise:
%    \begin{macrocode}
\autoadjustlogos*
%    \end{macrocode}
%
%
% \subsection{Option trigger}
%
% Any \pkg{metalogox} package option will next override the above settings.
%
%    \begin{macrocode}
\ProcessOptions\relax
%    \end{macrocode}
%
%
% \subsection{Support for the \pkg{hologo} and \pkg{hvlogos} packages}
%
% If \pkg{hologo} is used, a few macros are defined to use \pkg{metalogo} kerning.
% (\pkg{hvlogos} uses \pkg{hologo}, so is also supported.)
% \changes{v1.04}{2024/01/25}{Added support for \pkg{hologo}, \pkg{hvlogos}.}
%    \begin{macrocode}
\AtBeginDocument{

\IfPackageLoadedTF{hologo}
{
\def\HoLogo@TeX#1{\TeX}

\def\HoLogo@La#1{%
  \@xl@everylogo
  L\kern\xl@kern@La@La
   {\ifxetex
      \XeTeXuseglyphmetrics\@ne
    \fi
    \sbox\z@ T%
    \sbox\@ne{\xl@LaTeX@a}%
    \vbox to\ht\z@{%
      \hbox{%
        \ltx@sh@ft{\ht\z@}%
        \xl@sh@ft{\ht\@ne}%
        \xl@LaTeX@a
        \xl@sh@ft{\ht\z@}%
        \ltx@sh@ft{\ht\@ne}}%
      \vss}}%
  }

\def\HoLogo@LaTeX#1{\HoLogo@La{La}\kern\xl@kern@LaTeX@aT\TeX}

\def\HoLogo@LaTeXe#1{%
  \hologo{LaTeX}%
  \kern\xl@kern@LaTeXe@Xii%
  \hbox{%
    \HOLOGO@MathSetup
    2%
    $_{\textstyle\varepsilon}$%
  }%
}

\def\HoLogo@LaTeXTeX#1{%
  (%
    \kern\xl@kern@LaTeX@aT
  \hologo{La}%
    \kern\xl@kern@LaTeX@aT
  )%
    \kern\xl@kern@LaTeX@aT
  \hologo{TeX}%
}
\expandafter\let\csname HoLogo@(La)TeX\endcsname\HoLogo@LaTeXTeX

\def\HoLogo@XeTeX#1{\Xe\kern\xl@kern@XeTeX@eT\TeX}

\def\HoLogo@XeLaTeX#1{\Xe\kern\xl@kern@XeLaTeX@eL\LaTeX}

}
{}% hologo not loaded

}% AtBeginDocument
%    \end{macrocode}
%
%
%
% ^^A At end:
%
% \clearpage
% ^^A \pagestyle{plain}
%
% \pagestyle{plain}
%
% \Finale
\endinput





