diff --git a/src/document/katedocument.cpp b/src/document/katedocument.cpp --- a/src/document/katedocument.cpp +++ b/src/document/katedocument.cpp @@ -3583,7 +3583,7 @@ // Insert only enough spaces to align to the next indentWidth column // This fixes bug #340212 int spacesToInsert = indentWidth - (column % indentWidth); - result += QStringLiteral(" ").repeated(spacesToInsert); + result += QString(spacesToInsert, QLatin1Char(' ')); column += spacesToInsert; } else { // Just keep all other typed characters as-is