Converts a multi-line string to a single line of text.
Source position: lazstringutils.pas line 96
function TextToSingleLine( |
const AText: string |
):string; |
AText |
|
Text values examined and converted in the routine. |
Text after removing end-of-line characters and duplicate space characters.
TextToSingleLine is a String function used to replace end-of-line characters (like CR (#13) and LF (#10)) in AText with Space (#32) characters. Duplicate adjacent Space characters are converted to a single Space character in the return value.
// uses LazStringUtils; // var sMultiLn, sSingleLn: String; sMultiLn := 'The rain '#10' in Spain '#13#10' falls mainly on the plain. '; sSingleLn := TextToSingleLine(sMultiLn); // value is: 'The rain in Spain falls mainly on the plain.'
| Version 4.4 | Generated 2025-11-08 | Home |