Safe Haskell | None |
---|---|
Language | Haskell2010 |
Unicode
Synopsis
- module Haskus.Format.Text.Unicode.CodePoint
- newtype Plane = Plane Word
- codePointPlane :: CodePoint -> Plane
- planeBMP :: Plane
- planeSMP :: Plane
- planeSIP :: Plane
- planeSSP :: Plane
- planePrivates :: [Plane]
- data UTF8 = UTF8
- data UTF16_BOM = UTF16_BOM
- data UTF16_BE = UTF16_BE
- data UTF16_LE = UTF16_LE
- data UTF32_BOM = UTF32_BOM
- data UTF32_BE = UTF32_BE
- data UTF32_LE = UTF32_LE
Documentation
Planes
codePointPlane :: CodePoint -> Plane Source #
Get the plan the code-point belongs to
>>>
codePointPlane (CodePoint 0x21234)
Plane 2
Basic Multilingual Plane (BMP)
The Basic Multilingual Plane (BMP, or Plane 0) contains the common-use characters for all the modern scripts of the world as well as many historical and rare characters. By far the majority of all Unicode characters for almost all textual data can be found in the BMP.
Supplementary Multilingual Plane (SMP)
Supplementary Multilingual Plane. The Supplementary Multilingual Plane (SMP, or Plane 1) is dedicated to the encoding of characters for scripts or symbols which either could not be fit into the BMP or see very infrequent usage. This includes many historic scripts, a number of lesser-used contemporary scripts, special-purpose invented scripts, notational systems or large pictographic symbol sets, and occasionally historic extensions of scripts whose core sets are encoded on the BMP.
Examples include Gothic (historic), Shavian (special-purpose invented), Musical Symbols (notational system), Domino Tiles (pictographic), and Ancient Greek Numbers (historic extension for Greek). A number of scripts, whether of historic and contemporary use, do not yet have their characters encoded in the Unicode Standard. The majority of scripts currently identified for encoding will eventually be allocated in the SMP. As a result, some areas of the SMP will experience common, frequent usage.
Supplementary Ideographic Plane (SIP)
The Supplementary Ideographic Plane (SIP, or Plane 2) is intended as an additional allocation area for those CJK characters that could not be fit in the blocks set aside for more common CJK characters in the BMP. While there are a small number of common-use CJK characters in the SIP (for example, for Cantonese usage), the vast majority of Plane 2 characters are extremely rare or of historical interest only.
Supplementary Special-purpose Plane (SSP)
The Supplementary Special-purpose Plane (SSP, or Plane 14) is the spillover allocation area for format control characters that do not fit into the small allocation areas for format control characters in the BMP.
planePrivates :: [Plane] Source #
Private Use Planes
The two Private Use Planes (Planes 15 and 16) are allocated, in their entirety, for private use. Those two planes contain a total of 131,068 characters to supple- ment the 6,400 private-use characters located in the BMP.