This is the documentation page for Module:Unicode data

Template:High risk

UsageEdit

This module provides functions that access information on Unicode code points. The information is retrieved from data modules generated from the Unicode Character Database, or derived by rules given in the Unicode Specification. It and its submodules were copied from English Wiktionary and then modified; see there for more information.

Parameters and functionsEdit

code pointEdit

The code point is to be entered as hexadecimal value. For example, Expression error: Unrecognised punctuation character "[".:

Template:Mono
Template:Mono
Template:Mono
Template:Mono
{{#invoke:Unicode data|lookup|name|0x00A9}} → COPYRIGHT SIGN

Incorrect or unintended results:

Template:Mono: {{#invoke:Unicode data|lookup|name|169}} → LATIN SMALL LETTER U WITH TILDE Template:Nay —"U+00A9" Template:Code expected; but is read as Template:Mono (that is, Template:Mono
Template:Mono {{#invoke:Unicode data|lookup|name|U+00A9}} Template:Nay —do not use "U+" prefix
Template:Mono {{#invoke:Unicode data|lookup|name|غ}} Template:Nay —cannot enter a character as codepoint

"Template:Mono" and "Template:Mono" functionsEdit

Template:Code
Template-invokable functions that allow access to the functions starting with lookup and is.For most of the functions, add the code point in hexadecimal base as the next parameter. For is"|Latin, is|rtl, and is|valid_pagename, add character string. HTML character references in the text are decoded by the module into code points.
For example, Template:Tnull → true.
Internally, in modules, these functions are named using underscore: Template:CodeTemplate:Code
For &A9; ©: Template:Tnull → COPYRIGHT SIGN

Functions overviewEdit

Template:Align

Topic Function Parameter type
(string=by character(s); c.p. by Template:Mono value)
Example Returns Character
Unicode character name Template:Code code point
  • COPYRIGHT SIGN
  • <control-0007>
  • ©
  • &#x0007;
Scripts Template:Code code point Template:Tnull Yiii
Blocks Template:Code code point Template:Tnull Yi Syllables
Planes Template:Code code point
  • Basic Multilingual Plane
  • Supplementary Multilingual Plane
  • ©
  • 😈


General Category Template:Code code point
  • So
  • Sm
  • ©
  • +
Controls Template:Code code point
  • assigned
  • unassigned
  • ©
  • &#xFFFF;
Latin script Template:Code string
  • true
  • false
WP:Article title (WP:NCTR) Template:Code string Template:Ubli
  • true
  • false
Bidirectionality, right-to-left scripts Template:Code string Template:Ubli
  • ش
  • 4
Combining character Template:Code code point
  • true
  • false
  • ̀
  • d
Character assignation Template:Code code point
  • true
  • false
  • ;
Printable Template:Code code point
  • >true<
  • >false<
  • >false<
  • >a<
  • >&#x0007;<
  • >&#xFFFF;<
Template:Slink Template:Code code point
  • >true<
  • >true< NBSP
  • >false<
  • > <
  • > <
  • >d<
Hangul Template:Code [application unknown]
  • &#x;
  • &#x;
Alias names Template:Code [application unknown]
  • &#x;
  • &#x;
Combining class Template:Code [application unknown]
  • &#x;
  • &#x;
Age Template:Code [application unknown]
get_best_script Template:Code [application unknown]

Data modulesEdit

The data used by functions in this module is found in submodules. Some are generated by AWK scripts shown at User:Kephir/Unicode on English Wiktionary, others by Lua scripts on the /make subpages of the submodules.

The name data modules (Module:Unicode data/names/xxx) were compiled from UnicodeData.txt. Each one contains, at maximum, code points U+xxx000 to U+xxxFFF. Lua error in mw.title.lua at line 209: too many expensive function calls.

CopyrightEdit

The Unicode database is released by Unicode Inc. under the following terms:

Copyright © 1991-2018 Unicode, Inc. All rights reserved. Distributed under the Terms of Use in https://www.unicode.org/copyright.html.

Permission is hereby granted, free of charge, to any person obtaining a copy of the Unicode data files and any associated documentation (the "Data Files") or Unicode software and any associated documentation (the "Software") to deal in the Data Files or Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, and/or sell copies of the Data Files or Software, and to permit persons to whom the Data Files or Software are furnished to do so, provided that either (a) this copyright and permission notice appear with all copies of the Data Files or Software, or (b) this copyright and permission notice appear in associated Documentation.

THE DATA FILES AND SOFTWARE ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THE DATA FILES OR SOFTWARE.

Except as contained in this notice, the name of a copyright holder shall not be used in advertising or otherwise to promote the sale, use or other dealings in these Data Files or Software without prior written authorization of the copyright holder.

Known issuesEdit

{{#invoke:Unicode data|lookup|category|0xFFFF}} → [Nil]

See alsoEdit

  • Named entities: for example, Expression error: Unrecognised punctuation character "[".: {{#invoke:LoadData|Numcr2namecr|0x22C1}} → &bigvee;, &Vee;, &xvee;