For setting particular context flags there are these functions:
#include <cfg+.h>
void cfg_set_context_flag
(const CFG_CONTEXT con, int flag);
void cfg_clear_context_flag
(const CFG_CONTEXT con, int flag);
int cfg_get_context_flag
(const CFG_CONTEXT con, int flag);
void cfg_set_context_flags
(const CFG_CONTEXT con, int flags);
int cfg_get_context_flags
(const CFG_CONTEXT con, int flags);
These functions and macros manipulate with context flags. The function cfg_set_context_flag() sets one particular context flag. Similary, function cfg_clear_context_flag() clears one context flags. Function cfg_get_context_flag() detects if particular context flag is set. It has the macro alias cfg_is_context_flag() which is indentical in every way.
Remaining two functions cfg_set_context_flags() and cfg_get_context_flags() can set and get all flags in one call. Note that when you set flags with cfg_set_context_flags() current flag state of context is overwritten by flags parameter passed to this function.
List of setable context flags is described in following table.
Context flags
Ignore multiple arguments for single option. First one will be used to store option value, furthers are skipped.
By default, multiple arguments for option that has not allowed them, cause CFG_ERROR_MULTI error.
Ignore all unknown options.
The default behaviour is, that any unknown option causes CFG_ERROR_UNKNOWN error.
Processing of the first argument on command line is skipped. This flag affects only command line related context.
By default is also the first argument on command line processed.
Advanced leftover arguments. It means that leftover arguments do not need to be be posixly correct.
The default behaviour is, that leftover arguments have to be posixly correct. Thus all options must go before any leftover argument. Once the first leftover argument is found, all further arguments are considered as leftovers.
Strict leftover arguments initialization in file.
By default are leftover arguments in file initialized in normal way (as they are).
Positions and size in configuration file are specified in lines starting from 0.
The default behaviour is, that positions and size in configuration file are specified in bytes starting from 0.
If you have some flag set and you want to get default behaviour back, simply clear that flag using cfg_clear_context_flag() function.