Unicode for X-double bar
I am looking for the HTML code for the X-doubl开发者_StackOverflow中文版e bar.
I know the code for a single bar:
x-bar = x̄
or x̄
(hex)
But what is it for the X-double bar?
The accepted answer is incorrect.
U+035E COMBINING DOUBLE MACRON
is meant to go over two code points. It is double only in the sense that it goes over both the code point it follows and the one it precedes, unlike normal marks that only count for the one they follow. Compare U+0360 COMBINING DOUBLE TILDE
, which does the same thing. "a\x{35e}e"
is a͞e
, while "a\x{360}e"
is a͠e
.
The code point you want is U+033F COMBINING DOUBLE OVERLINE
. "x\x{33f}"
is x̿
.
Here are all the combining macrons, using the uninames tool:
% uninames COMBINING MACRON
̄ 0304 COMBINING MACRON
= long
* distinguish from the following
x (macron - 00AF)
x (modifier letter macron - 02C9)
̱ 0331 COMBINING MACRON BELOW
x (low line - 005F)
x (modifier letter low macron - 02CD)
͞ 035E COMBINING DOUBLE MACRON
͟ 035F COMBINING DOUBLE MACRON BELOW
᷄ 1DC4 COMBINING MACRON-ACUTE
᷅ 1DC5 COMBINING GRAVE-MACRON
᷆ 1DC6 COMBINING MACRON-GRAVE
᷇ 1DC7 COMBINING ACUTE-MACRON
᷋ 1DCB COMBINING BREVE-MACRON
* Lithuanian dialectology
᷌ 1DCC COMBINING MACRON-BREVE
* Lithuanian dialectology
︤ FE24 COMBINING MACRON LEFT HALF
︥ FE25 COMBINING MACRON RIGHT HALF
︦ FE26 COMBINING CONJOINING MACRON
x (combining macron - 0304)
x (combining double macron - 035E)
and here are the combining half marks:
% uninames COMBINING HALF
̜ 031C COMBINING LEFT HALF RING BELOW
* IPA: open variety of vowel
x (modifier letter down tack - 02D5)
̹ 0339 COMBINING RIGHT HALF RING BELOW
͑ 0351 COMBINING LEFT HALF RING ABOVE
͗ 0357 COMBINING RIGHT HALF RING ABOVE
︠ FE20 COMBINING LIGATURE LEFT HALF
︡ FE21 COMBINING LIGATURE RIGHT HALF
x (combining double inverted breve - 0361)
︢ FE22 COMBINING DOUBLE TILDE LEFT HALF
︣ FE23 COMBINING DOUBLE TILDE RIGHT HALF
x (combining double tilde - 0360)
︤ FE24 COMBINING MACRON LEFT HALF
︥ FE25 COMBINING MACRON RIGHT HALF
And these are, well, what they say they are:
% uninames COMBINING DOUBLE LINE
̎ 030E COMBINING DOUBLE VERTICAL LINE ABOVE
* Marshallese
x (quotation mark - 0022)
̳ 0333 COMBINING DOUBLE LOW LINE
= double underline, double underscore
* connects on left and right
x (combining equals sign below - 0347)
x (double low line - 2017)
̿ 033F COMBINING DOUBLE OVERLINE
͈ 0348 COMBINING DOUBLE VERTICAL LINE BELOW
* IPA: strong articulation
$ uninames '\bAE\b' macron
Ǣ 01E2 LATIN CAPITAL LETTER AE WITH MACRON
: 00C6 0304
ǣ 01E3 LATIN SMALL LETTER AE WITH MACRON
* Old Norse, Old English
: 00E6 0304
You can test them this out way:
$ export PERL_UNICODE=S
$ perl -E 'say "x\x{33f}"'
x̿
$ perl -E 'say "a\x{35e}e"'
a͞e
$ perl -E 'say "a\x{360}e"'
a͠e
$ perl -E 'say "a\x{fe24}e\x{fe25}"'
a︤e︥
$ perl -E 'say "\x{1e3}"'
ǣ
$ perl -E 'say "\x{e6}\x{304}"'
ǣ
$ perl -E 'say "\x{e6}\x{33f}"'
æ̿
$ perl -E 'say "X\x{304}"'
X̄
$ perl -E 'say "X\x{33f}"'
X̿
$ perl -E 'say "x\x{33f}\x{333}"'
x̳̿
U+0304 is the combining macron. There is a "combining double overline" at U+033F which might work for you, and a "combining double macron" at U+035E. Neither of these looks very clearly like a double bar in my browser. But if they work for you, the code would be something like ̿x
which renders as ̿x or ͞x
which renders as ͞x (This is HTML markup, not Unicode.) Note also that the combining character should go before the character it combines with, not after.
See also http://www.fileformat.info/info/unicode/block/combining_diacritical_marks/list.htm
For whichever character you want to put bars above, add ̄
after it.
So for example if you want x double bar (x̄̄) the HTML code is x̄̄
. If you want to make an x triple bar (x̄̄̄) then write x̄̄̄
.
Here's a code sample in HTML:
X single bar: x̄<br>
X double bar: x̄̄<br>
X triple bar: x̄̄̄<br>
This also works for any character. For example, for y triple bar (ȳ̄̄), it will be ȳ̄̄
.
精彩评论