refactor SimpleQueryParser settings into separate class, add "lenient" option

Fixes #5011