View Single Post
Old 03-03-2021, 12:55 PM   #16
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 2,297
Karma: 12126329
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by KevinH View Post
Regional language differences just mean you use a languagecode that includes regions.

Code:
"es-CO" << tr("Spanish") + QString(" - ") + tr("Columbia") <<
Caught a minor typo:

Columbia -> Colombia

The South American country is with 2 'o'.

https://en.wikipedia.org/wiki/Colombia

I reported that to LanguageTool a few days ago as well. A very common typo.

(I just made a pull request on Sigil's Github.)

Quote:
Originally Posted by ebray187 View Post
Perhaps it is not so common in English, but for example between Argentine Spanish and Spain Spanish there are many spelling differences.
A great explanation of how to use HTML language codes is in W3C's "Language tags in HTML and XML" + see the whole list of languages/regions.

HTML Lang + EPUB dc:language

For the most part, you'll only have a main language:
  • en = English
  • es = Spanish
  • de = German
  • [...]

Everything else beyond that is "extra". For example:
  • es = Spanish
  • es-AR = Spanish (Argentina)
  • en = English
  • en-US = English (United States)
  • en-GB = English (British)
  • en-GB-oxendict = English (British + Oxford English Dictionary)

Dictionaries

Dictionary files also follow those naming conventions (like KevinH said). So:
  • es_AR = a Spanish (Argentina) dictionary
  • en_GB = a British dictionary
  • en_GB-oxendict = a British (Oxford) dictionary

And like KevinH said, pretty much any dictionary file since forever would follow those conventions.

Quote:
Originally Posted by ebray187 View Post
I fully understand what you are saying and it certainly makes a lot of sense.
Side Note: Also, in the future, lots of other benefits can come from proper lang markup.

I wrote about a few possibilities back in 2018: "Two questions".

Multi-Language Spellchecking was just one piece (and I'm ecstatic it's been added to Calibre+Sigil after me beating the drums since 2016!!!).

Last edited by Tex2002ans; 03-03-2021 at 01:07 PM.
Tex2002ans is offline   Reply With Quote