ISourceFormatter::formatSourceWithStyle: take style by reference
This should be faster than copying SourceFormatterStyle
at each call of
this function.
Introduce a QString styleContent
variable in
CustomScriptPlugin::formatSourceWithStyle()
for these reasons:
-
style
is now a reference toconst
and cannot be assigned to; - the name of an incomplete style matches the name of the corresponding
predefined style, so using unmodified
style.name()
below is correct; -
QString content()
is the only other member of style used below.
Reformat the lines touched by this change.
Don't refer to the previous name of kdevcustomscript plugin "indent" in the warning message touched by this change.