SHIP:Data Types:CodepointRange

From Serious Documentation
Jump to: navigation, search

See Also

CodepointRange

Data Type Description
CodepointRange Sequence of Unicode codepoints to be included; expressed as Codepoint..Codepoint (inclusive).

For ease of use, SHIPTide contains Keywords for common groups of codepoints such as Basic ASCII, Accented Letters, Kanji, etc.

Examples

Examples of single 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

Examples of CodepointRanges:

  • 0x20..0x200 -- codepoints 0x0020 through 0x0200 inclusive
  • 0x1234..#1234 -- valid, but only one codepoint 0x1234 , and can be more simply expressed as 0x1234
  • 0x1234..0x1222 -- invalid, range cannot go backwards

You can also specify a List of CodepointRanges, for example:

  • 0x20..0x7F,0xB1 -- the ASCII printable character range plus the degrees symbol
  • 0x20..0x7F,0xB1,0x2122 -- adds the trademark symbol to the set

You can combine hex values with CodepointRange Keywords like this:

  • 0x20..0x7F,Latin-A -- which is the basic ASCII range plus extended Latin characters