JCL Help:TJclTabSet.UpdatePosition@string@SizeInt@SizeInt
JCL Help: TJclTabSet.UpdatePosition Method (string, SizeInt, SizeInt)
Search in JCL Help
Search in all projects
Summary
Calculates the ending line and column after expanding tabs in the provided string.
Pascal
public function UpdatePosition(const S: string; var Column: SizeInt; var Line: SizeInt): SizeInt; overload;
Parameters
Parameters | Description |
const S: string | The string to expand tabs in. |
var Column: SizeInt | On entry: The starting column to use when expanding the tabs. On return: The ending column after expanding the tabs. |
var Line: SizeInt | On entry: The starting line to use when expanding the tabs. On return: The ending line after expanding the tabs. |
Return Value
The ending column after expanding tabs in the provided string.
Description
Calculate will simulate the Expand method, updating the line and column variables only. For convenience, the ending column is also the method's result value.
Multi-line strings, ie. strings containing one or more newline sequences (eg. CrLf, but also single Cr of Lf characters are treated as newlines), are handled properly, with all but the first line starting at column 0 (zero-based set to True
) or 1 (zero-based set to False
).
Examples
See the TJclTabSet help for an example.
See Also
TJclTabSet TJclTabSet.Expand@string@SizeInt TJclTabSet.TabFrom
About
Donator
Marcel Bestebroer
Notes
This method is nil-safe; when invoked on a nil-reference, this method will assume a tab width of two on a zero-based tab set.
Contribute to this help topic
This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page