diff options
Diffstat (limited to 'src/libs/qmljs/qmljsreformatter.cpp')
-rw-r--r-- | src/libs/qmljs/qmljsreformatter.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/libs/qmljs/qmljsreformatter.cpp b/src/libs/qmljs/qmljsreformatter.cpp index a9eede5e3e..b3d5d1e7d3 100644 --- a/src/libs/qmljs/qmljsreformatter.cpp +++ b/src/libs/qmljs/qmljsreformatter.cpp @@ -255,14 +255,13 @@ protected: qreal result = badnessFromSplits; foreach (const QString &line, lines) { // really long lines should be avoided at all cost - if (line.size() > strongMaxLineLength) + if (line.size() > strongMaxLineLength) { result += 50 + (line.size() - strongMaxLineLength); // having long lines is bad - else if (line.size() > maxLineLength) { + } else if (line.size() > maxLineLength) { result += 3 + (line.size() - maxLineLength); - } // and even ok-sized lines should have a cost - else { + } else { result += 1; } |