MCPcopy Create free account
hub / github.com/altairwei/WizNotePlus / formatOption

Function formatOption

lib/extensionsystem/pluginmanager.cpp:597–610  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

595}
596
597static inline void formatOption(QTextStream &str,
598 const QString &opt, const QString &parm, const QString &description,
599 int optionIndentation, int descriptionIndentation)
600{
601 int remainingIndent = descriptionIndentation - optionIndentation - opt.size();
602 indent(str, optionIndentation);
603 str << opt;
604 if (!parm.isEmpty()) {
605 str << " <" << parm << '>';
606 remainingIndent -= 3 + parm.size();
607 }
608 indent(str, qMax(1, remainingIndent));
609 str << description << '\n';
610}
611
612/*!
613 Formats the startup options of the plugin manager for command line help.

Callers 2

formatOptionsMethod · 0.85
formatPluginOptionsMethod · 0.85

Calls 3

indentFunction · 0.85
sizeMethod · 0.80
isEmptyMethod · 0.80

Tested by

no test coverage detected