Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
217 views
in Technique[技术] by (71.8m points)

android - What does b stand for, and what is the syntax behind b+sr+Latn?

By default, Android has always displayed Serbian in Cyrillic, but since 7.0, users can choose between Cyrillic and Latin script. Apps (mostly from Google) ususally puts the Cyrillic strings in sr and the Latin strings in b+sr+Latn. However, b+sr+Latn is very different from the usual convention of using dashes (e.g. sr-rRS-port).

What does b stand for? What is the syntax, and what more can I specify with this?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

It's a BCP 47 language tag. It's starts with b and followed by a language, script, region and variant.
BCP 47 documentation

b+sr+Latn would be Serbian with the Latin script.
b+sr+Latn+RS would be Serbian in Serbia, with the Latin script.

The same can be applied to Azerbaijani:
b+az+Latn – Latin script
b+az+Cyrl – Cyrillic script
b+az+Arab – Arabic script

But you can virtually do any combination possible:
b+ja+Hrkt – Japanese with only Hiragana and Katakana
b+ru+Latn – Russian with the Latin script
b+hu+Hung – Hungarian with the Hungarian Runic script
b+en+Cyrl+US – American English with the Cyrillic script
b+hy+Piqd+DE – German Armenian with the Klingon script
(but support will be very limited)

See also:
ISO 639-3 language list
ISO 15924 script list
ISO 3166-1 alpha-2 country list


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...