Carbon


TEGetOffset

Header: TextEdit.h Carbon status: Not Recommended

Finds the byte offset of a character in an edit structure’s text that corresponds to the specified point.

SInt16 TEGetOffset (
    Point pt, 
    TEHandle hTE
);
Parameter descriptions
pt

A point in the displayed text of the specified edit structure.

hTE

A handle to the edit structure containing the text.

function result

The byte offset of the character at the specified point. In the case of a 2-byte character, the function returns the byte offset of the first byte.

DISCUSSION

The TEGetOffset function works for both monostyled and multistyled edit structures.

AVAILABILITY

Not recommended in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)