View Single Post
Old 08-21-2011, 04:59 AM   #6
arspr
None
arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.arspr ought to be getting tired of karma fortunes by now.
 
Posts: 493
Karma: 599350
Join Date: Mar 2011
Location: Madrid, Spain
Device: Sony PRS-650 >>> Kobo Aura HD (self-destructed) >>> Kobo Aura H2O
Quote:
Originally Posted by kovidgoyal View Post
Why? As a user you will never see those codes, expect in a highly specific situation, like comparing to another column via a template. You are of course free to create whatever custom columns you like, but language in calibre has a well defined meaning, specified by ISO 639. The languages column will never accept arbitrary strings.
I need this kind of feature in order to keep my current data management. I not only store the book language but also the language it was written in, its original language. So I need two language columns. In addition I also perform a comparison between them which tells me if each book has been translated or not.

Till now, Calibre didn't have a specific language type of column, so I just used two custom Tag-like columns.

Now that Calibre offers a real and "official" language column, I do want to use this feature but:
  • I still need another extra language field.
  • If this second column is not available as a Language-type one, I'll have to use a general Tag-like column for it. But then, my current comparison between languages stops working, so:
    • Either I just don't use this new Language feature at all...
    • Or I have to store "spa", "eng", etc. in this custom second language column instead of their "true" names, which is completely awkward .
    • Or you provide some function within the template coding language in order to make a strcmp (My second language column (remember it's Tag-Like) vs. FunctionToConvertInternalCodesToDisplayedStrings(New Official Languages Column) )
    • Or there's another way to make this comparison that I don't know about. But this one was the solution that advanced users gave me (see this old thread about it)
arspr is online now   Reply With Quote