Parameters
allowNewLine - Indicates if a new line can be added.
Returns
true if allowed to start with a newline; otherwise false.
Syntax
| JavaScript |
|
StartWithNewLine(allowNewLine)
|
Checks if the text can start with a newline.
Example
| JavaScript |
// Checks if the text can start with a newline.
StartWithNewLine()
{
const tb = new LJCTextBuilder();
tb.Text("First Line");
const allowNewLine = true;
// Example Method:
let result = tb.StartWithNewLine(allowNewLine);
// result:
// true
tb.Line();
// Example Method:
result = tb.StartWithNewLine(allowNewLine);
// result:
// false
}
|
Copyright © Lester J. Clark and Contributors.
Licensed under the MIT License.