# HG changeset patch # User František Kučera # Date 1703720279 -3600 # Node ID dcb2ad86e23c4b27ce66aa3d3b8fb17f9d805348 # Parent 7ea796b005385c2fddc4d4db30a80905d84e3535 add undocumented option: --dpi diff -r 7ea796b00538 -r dcb2ad86e23c CLIParser.h --- a/CLIParser.h Thu Dec 28 00:32:23 2023 +0100 +++ b/CLIParser.h Thu Dec 28 00:37:59 2023 +0100 @@ -29,6 +29,7 @@ static const std::string OPTION_SHADER; static const std::string OPTION_BACKGROUND_COLOR; static const std::string OPTION_ROOT_WINDOW; + static const std::string OPTION_DPI; const std::string readNext(const std::vector& arguments, int& i) { @@ -73,6 +74,11 @@ Configuration::Document document; document.fileName = readNext(arguments, i); c.documents.push_back(document); + } else if (option == OPTION_DPI) { + // intentionally not documented + // will be probably replaced with absolute resolution + // or removed (dynamic rendering accorging to the zoom level) + c.dpi = std::stod(readNext(arguments, i)); } else if (option == OPTION_SHADER) { const auto type = readNext(arguments, i); const auto file = readNext(arguments, i); @@ -92,3 +98,4 @@ const std::string CLIParser::OPTION_SHADER = "--shader"; const std::string CLIParser::OPTION_BACKGROUND_COLOR = "--background-color"; const std::string CLIParser::OPTION_ROOT_WINDOW = "--root-window"; +const std::string CLIParser::OPTION_DPI = "--dpi";