add separate options x and options macros
This commit is contained in:
parent
0e90f82076
commit
d1a269b56b
1 changed files with 7 additions and 1 deletions
|
@ -31,12 +31,18 @@ def make_default_commands(package_formatter: PackageFormatter):
|
|||
prefix=Attributes.package_prefix, condition=Args.one, value=Args.two)
|
||||
package_formatter.add_arg_replacement(1, 'if', r'\if{prefix}{condition}', prefix=Attributes.package_prefix,
|
||||
condition=Args.one)
|
||||
package_formatter.add_replacement('language options',
|
||||
package_formatter.add_replacement('language options x',
|
||||
r'\newif\if{prefix}english\{prefix}englishtrue' + '\n' +
|
||||
r'\DeclareOptionX{{german}}{{\{prefix}englishfalse}}' + '\n' +
|
||||
r'\DeclareOptionX{{ngerman}}{{\{prefix}englishfalse}}' + '\n' +
|
||||
r'\DeclareOptionX{{english}}{{\{prefix}englishtrue}}',
|
||||
prefix=Attributes.package_prefix)
|
||||
package_formatter.add_replacement('language options',
|
||||
r'\newif\if{prefix}english\{prefix}englishtrue' + '\n' +
|
||||
r'\DeclareOption{{german}}{{\{prefix}englishfalse}}' + '\n' +
|
||||
r'\DeclareOption{{ngerman}}{{\{prefix}englishfalse}}' + '\n' +
|
||||
r'\DeclareOption{{english}}{{\{prefix}englishtrue}}',
|
||||
prefix=Attributes.package_prefix)
|
||||
package_formatter.add_arg_replacement(1, 'info', r'\PackageInfo{{{name}}}{{{info}}}', name=Attributes.package_name,
|
||||
info=Args.one)
|
||||
package_formatter.add_arg_replacement(1, 'warning', r'\PackageWarning{{{name}}}{{{warning}}}',
|
||||
|
|
Loading…
Reference in a new issue