@@ -56,9 +56,9 @@ QString optionsToString(const QList<CommandOption>& options,
5656 QStringLiteral (" " ).repeated (size + 4 ).prepend (" \n " );
5757 for (int i = 0 ; i < options.length (); ++i) {
5858 result += QStringLiteral (" %1 %2\n " )
59- .arg (dashedOptionList.at (i).leftJustified (size, ' ' ))
60- . arg ( options.at (i).description ().replace (
61- QLatin1String (" \n " ), linePadding));
59+ .arg (dashedOptionList.at (i).leftJustified (size, ' ' ),
60+ options.at (i).description ().replace (
61+ QLatin1String (" \n " ), linePadding));
6262 }
6363 if (!subcommands.isEmpty ()) {
6464 result += QLatin1String (" \n " );
@@ -69,8 +69,8 @@ QString optionsToString(const QList<CommandOption>& options,
6969 }
7070 for (const auto & subcommand : subcommands) {
7171 result += QStringLiteral (" %1 %2\n " )
72- .arg (subcommand.name ().leftJustified (size, ' ' ))
73- . arg ( subcommand.description ());
72+ .arg (subcommand.name ().leftJustified (size, ' ' ),
73+ subcommand.description ());
7474 }
7575 return result;
7676}
@@ -142,8 +142,7 @@ bool CommandLineParser::processOptions(const QStringList& args,
142142 }
143143 err << QStringLiteral (" the option '%1' is not a valid option "
144144 " for the argument '%2'." )
145- .arg (arg)
146- .arg (argName);
145+ .arg (arg, argName);
147146 ok = false ;
148147 return ok;
149148 }
@@ -329,9 +328,7 @@ void CommandLineParser::printHelp(QStringList args, const Node* node)
329328 node->subNodes .isEmpty () ? " " : " [" + QObject::tr (" subcommands" ) + " ]" ;
330329 helpText += (QObject::tr (" Usage" ) + " : %1 [%2-" + QObject::tr (" options" ) +
331330 QStringLiteral (" ] %3\n\n " ))
332- .arg (args.join (QStringLiteral (" " )))
333- .arg (argName)
334- .arg (argText);
331+ .arg (args.join (QStringLiteral (" " )), argName, argText);
335332
336333 // short section about default behavior
337334 helpText += QObject::tr (" Per default runs Flameshot in the background and "
0 commit comments