Topic Path: Symbol Reference > Functions > WrapText Function
ContentsIndexHome
PreviousUpNext
WrapText Function
File
function WrapText(
    const ALine: string; 
    const ABreakStr: string; 
    const ABreakChars: string; 
    MaxCol: Integer
): string;
Parameters 
Description 
ALine 
  • content to be folded.

 
ABreakStr 
Sequence of characters used to cause text to be folded to the next line.
 
ABreakChars 
Characters considered as possible line break positions.
 
MaxCol 
Maximum line length to use in the line folding algorithm. 

string - Content after applying theline folding algorithm.

WrapText is an String function used to perform line folding for the content found in messages and responses conforming to the Intermet Message format. Typically, WrapText can used when handling email message, and protocol reponses like HTTP. 

ALine is the original content to be folded using arguments passed to the function. 

ABreakStr indicates a sequence of characters used to cause text to be folded to the next line. Data in ALine that matches ABreakStr is not subjected to the line folding algorithm (since it already represents a line break). 

ABreakChars indicates characters that can be considered as a possible line break position when applying the line folding algorithm. 

MaxCol indicates the desired maximum line length after applying the line folding algorithm. 

WrapText iterates over the contents of Aline, and applies line folding to the content specified in ALine and stores the result in the return value for the method. Leading characters and text appearing after Quotation characters (QuoteChars) are not bubjected to the line folding algorithm.

Copyright 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.