SHIP:Data Types:Codepoint

From Serious Documentation
Jump to: navigation, search

See Also

Codepoint

Data Type Description
Codepoint Unicode codepoints are 16-bit numbers, usually expressed in hexidecimal, that represent a unique character (e.g. 0x2122 for the ™ symbol). In SHIP there is no explicit Codepoint type, and Integers are commonly used to store/manipulate codepoints as unsigned values.

Examples

Examples of codepoints:

  • 0x1 - codepoint 0x0001
  • #12F4 - codepoint 0x12F4
  • 12F4 - invalid, since 12F4 is not a valid decimal number and is not prefixed by # or 0x indicating it would be a hex value
  • 0x12 - codepoint 0x0012
  • 0x12345 - invalid... greater than 65535
  • 0x1234 - codepoint 0x1234
  • 1234 - codepoint decimal 1234, hex 0x04D2

References