Utf8.byte: Difference between revisions
From GiderosMobile
Created page with "__NOTOC__ '''Available since:''' Gideros 2016.06<br/> === Description === Returns the internal numerical codes of the characters s[i], s[i+1], ..., s[j]. The default value for..." |
No edit summary |
||
| Line 5: | Line 5: | ||
Numerical codes are not necessarily portable across platforms. | Numerical codes are not necessarily portable across platforms. | ||
<source lang="lua"> | <source lang="lua"> | ||
(numbers) | (numbers) = utf8.byte(s,i,j) | ||
</source> | </source> | ||
'''s | '''s''': (string) ''''''<br/> | ||
'''i | '''i''': (number) default is 1 '''optional'''<br/> | ||
'''j | '''j''': (number) '''optional'''<br/> | ||
'''Returns''' (numbers) Returns the internal numerical codes of the characters<br/> | '''Returns''' (numbers) Returns the internal numerical codes of the characters<br/> | ||
Revision as of 09:17, 23 August 2018
Available since: Gideros 2016.06
Description
Returns the internal numerical codes of the characters s[i], s[i+1], ..., s[j]. The default value for i is 1; the default value for j is i. These indices are corrected following the same rules of function string.sub. Numerical codes are not necessarily portable across platforms.
(numbers) = utf8.byte(s,i,j)
's: (string) '
i: (number) default is 1 optional
j: (number) optional
Returns (numbers) Returns the internal numerical codes of the characters