问题
I have been looking online for the UTF8 character table. And all I could find for subscripts were numbers 1 to 9 and some of latin letters.
I need to find S and B as subscripts for UTF8
Thanks for the help.
here is the link for a UTF8 character table: http://tlt.its.psu.edu/suggestions/international/bylanguage/mathchart.html
回答1:
UNICODE doesn't have representation of all latin letters in subscripts and superscripts: just a few of those. You'll have to use markup to do that.
For example, if you're using HTML, you can use the following markup:
example<sub>S</sub>
which gets converted into exampleS.
Same functionality is available in many other text rendering engines: TeX, etc. If you're displaying it in WinForms or something similar, unfortunately, you'll have to do it yourself.
Also, regarding the "UTF8". It's just an encoding of the UNICODE table. UTF8 can encode any UNICODE character, as does UTF16, UTF32 and others. Therefore, your question is really about existence of latin subscript characters in UNICODE.
回答2:
You can find what you are looking for at http://en.wikipedia.org/wiki/Unicode_subscripts_and_superscripts
回答3:
I know its a old post, following is the list of characters having unicode equivalent. For other alphabets we dont have. hope it helps
http://www.unicode.org/charts/PDF/U2070.pdf
I created a small library to convert sub/super script to its equivalent UTF character.
https://github.com/DilipRajkumar/Select-With-Sub-Super-tags/tree/master
hope it helps.
回答4:
The authoritative reference on what characters there are in Unicode is the Unicode Standard. You can find the relevant information in the PDF code charts. The most commonly needed subscript characters are in the “Superscripts and subscripts” block. To get a full list, check the Unicodedata.txt file and search for characters with <sub>
in their description. Beware that many of them are for specialized used, e.g. in phonetic notations, and may work poorly outside such usage, if the glyphs have been designed for the special use.
来源:https://stackoverflow.com/questions/6613197/utf8-symbols-for-subscript-letters