C#中如何在字符串中设置上标
一、HTML中: var o2 = "O?"; // or "Ox2082"
var unit2 = "unit2"; // or "unitxB2"
请参考以下网址中的表格:https://en.wikipedia.org/wiki/Unicode_subscripts_and_superscripts The most common superscript digits (1,2,and 3) were in?ISO-8859-1?and were therefore carried over into those positions in the Latin-1 range of Unicode. The rest were placed in a dedicated section of Unicode at?U+2070 to U+209F. The two tables below show these characters. Each superscript or subscript character is preceded by a normal?x?to show the subscripting/superscripting. The table on the left contains the actual Unicode characters; the one on the right contains the equivalents using?HTML?markup for the subscript or superscript. Gray cells are reserved for future use,white cells are other characters from Latin-1. 你也可以直接复制里面的字符在程序中修改。
?
? ? Other superscript and subscript charactersUnicode also includes subscript and superscript characters that are intended for semantic usage,in the following blocks:
Consolidated,the Unicode standard defines complete sub- and super-scripts for numbers and common mathematical symbols ( ? 1 2 3 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ),a full superscript Latin lowercase alphabet except q ( ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ),a limited uppercase Latin alphabet ( ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ),a few subscripted lowercase letters ( ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ),and some Greek letters ( ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ). Note that since these characters come from different ranges,they may not be of the same size and position,depending on the typeface. (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |