update package with proper naming conventions
This commit is contained in:
parent
52438fd0a3
commit
91db761097
1 changed files with 8 additions and 7 deletions
|
@ -10,16 +10,17 @@ __NEW_IF__(extended,false)
|
|||
|
||||
__END_OPTIONS_X__
|
||||
|
||||
%Usage: \makealiasesforwith\<mathcommand>{<prefix>}{<Set of letters>}
|
||||
%Usage: \MakeAliasesForwith\<mathcommand>{<prefix>}{<Set of letters>}
|
||||
% to declare commands of form \<prefix><Letter> as \<mathcommand>{<Letter>} for each
|
||||
% of the specfied letters
|
||||
%
|
||||
% E.g. \makealiasesforwith\mathcal{c}{ABC} will declare
|
||||
% E.g. \MakeAliasesForwith\mathcal{c}{ABC} will declare
|
||||
% \cA \cB \cC \cD as \mathcal{A}, \mathcal{B}, \mathcal{C}
|
||||
% This is also ensuring math context, so that
|
||||
% \cA will be valid even in normal text.
|
||||
|
||||
\def\makealiasesforwith#1#2#3{
|
||||
\NewDocumentCommand{\MakeAliasesForwith}{m m m}
|
||||
{
|
||||
\def__PACKAGE_MACRO__(makealias)##1{
|
||||
\expandafter\def\csname #2##1\endcsname{\ensuremath{#1{##1}}}
|
||||
}
|
||||
|
@ -34,11 +35,11 @@ __END_OPTIONS_X__
|
|||
|
||||
__IF__(basic)
|
||||
\RequirePackage{amsfonts}
|
||||
\makealiasesforwith\mathbb{}{CFKNQRZ}
|
||||
\MakeAliasesForwith\mathbb{}{CFKNQRZ}
|
||||
\fi
|
||||
|
||||
__IF__(extended)
|
||||
\expandafter\makealiasesforwith\expandafter\mathcal\expandafter{\expandafter c\expandafter}\expandafter{__PACKAGE_MACRO__(all)}
|
||||
\expandafter\makealiasesforwith\expandafter\mathfrak\expandafter{\expandafter f\expandafter}\expandafter{__PACKAGE_MACRO__(all)}
|
||||
\expandafter\makealiasesforwith\expandafter\mathbb\expandafter{\expandafter b\expandafter}\expandafter{__PACKAGE_MACRO__(all)}
|
||||
\expandafter\MakeAliasesForwith\expandafter\mathcal\expandafter{\expandafter c\expandafter}\expandafter{__PACKAGE_MACRO__(all)}
|
||||
\expandafter\MakeAliasesForwith\expandafter\mathfrak\expandafter{\expandafter f\expandafter}\expandafter{__PACKAGE_MACRO__(all)}
|
||||
\expandafter\MakeAliasesForwith\expandafter\mathbb\expandafter{\expandafter b\expandafter}\expandafter{__PACKAGE_MACRO__(all)}
|
||||
\fi
|
||||
|
|
Loading…
Reference in a new issue