FontBase:getCharIndexAtOffset

From GiderosMobile
Revision as of 11:04, 23 August 2018 by Hgy29 (talk | contribs) (Created page with "__NOTOC__ '''Available since:''' Gideros 2018.3.1<br/> === Description === <br /> Returns the the offset within the given text string to which correponds the given X offset in...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Available since: Gideros 2018.3.1

Description


Returns the the offset within the given text string to which correponds the given X offset in the drawn text.

(number), = FontBase:getCharIndexAtOffset(textoffsetletterSpacingsize,)

'text: (string) '
'offset: (number) '
'letterSpacing: (number, default = 0) '
'size: (number, optional) '
Returns (number) The offset within the text string. The decimal part indicate the relative distance throughout the character itself.