TX Text Control .NET Server

Javascript: Line.getBaseline Method

Method|Introduced in 28.0

Description

Gets the line's baseline position.

Syntax

<void> Line.getBaseline(<RequestNumberCallback> callback, [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
callback

Receives the line's baseline position.

errorCallback

Optional. Is called when the operation failed with an error.

Examples

The following example demonstrates Line.getBaseline in a practical document-editing workflow. It gets the line's baseline position.

function onTxError(error) {
    console.error("TX Text Control error:", error.msg);
    error.handled = true;
}

function inspectBaseline(line) {
    line.getBaseline(
        function(result) {
            console.log("get baseline result:", result);
        },
        onTxError
    );
}