27.4 Capturing settings with configuration variables
You can access the current value of a configuration setting with a configuration variable. A configuration variable is a macro variable that looks like this:
is the keyword, format name, or other identifier that appears to the left of the equals sign in a setting in that configuration-file section. |
<$_if($$[HTMLOptions]ExtractEnable) ... >
Accessing a configuration value by using $$_Section[Key] as a predefined list variable is deprecated, though still supported for backward compatibility. |
Value is the latest override (if any)
The value of a configuration variable is the value of the setting in question at the time the macro is executed. If the original setting in your configuration file was overridden by a configuration-variable assignment in a marker or another macro, the override, not the original value, is the value returned for <$$[section]key>. See §31.2 Overriding settings with markers or macros.
Value is the default, for missing settings
If you use a configuration variable to retrieve the value of a setting when the key is not present in your configuration file, or the section itself is missing from your configuration file, the value of <$$[section]key> is the default value specified for that key in one of the following references:
In some cases the default value is an empty string, as for a missing [Style*Prefix] or [Style*Suffix] setting.
Value is zero, for invalid settings
If you use a configuration variable to retrieve a value when <$$[section]key> refers to an invalid configuration-file section, or to an invalid key, Mif2Go returns 0 (zero), which is interpreted as false in a conditional expression <$_if($$[section]key ...)>; see §27.5.4.2 Using conditional expressions.
> 27 Working with Mif2Go macros > 27.4 Capturing settings with configuration variables
