After reformatting SQL code, unify new lines to Windows line feeds, so the selection's end in SynMemo is correct

This commit is contained in:
Ansgar Becker
2024-01-21 16:10:23 +01:00
parent 79ce5edcf3
commit ad3709529c

View File

@ -63,6 +63,8 @@ begin
FOutputCode := FormatSqlOnlineSqlformatOrg(FInputCode);
end;
end;
// Unify line breaks, so selection end will be correct:
FOutputCode := fixNewlines(FOutputCode);
TimeElapsed := GetTickCount64 - StartTime;
MainForm.LogSQL(f_('Code reformatted in %s, using formatter %s', [FormatTimeNumber(TimeElapsed/1000, True, 3), '#'+grpReformatter.ItemIndex.ToString]));
except