View Single Post
Old 01-24-2020, 12:34 AM   #19
geek1011
Wizard
geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.geek1011 ought to be getting tired of karma fortunes by now.
 
Posts: 2,808
Karma: 7423683
Join Date: May 2016
Location: Ontario, Canada
Device: Kobo Mini, Aura Edition 2 v1, Clara HD
Quote:
Originally Posted by rtiangha View Post
How do you work around/fix that, if it's even possible? Last year, I was trying to create or combine some Japanese dictionaries, and while individual dictionaries would work, combining them sometimes would and sometimes wouldn't depending on the combination and I couldn't find a pattern. I think I wasted a month trying to figure it out, lol. But since there are so many Japanese characters to keep track of, a prefix problem sounds like a plausible cause. I know there are some penelope command line options that deal with prefix, but there aren't any usage examples in the help text so I don't know how to use them.
It's a problem in the code itself (I figured out how it works the same way I figure out patches (i.e. disassembly), unlike how the dictionary stuff was original done many years ago). To fix it, you need to change kobo_prefix.py (or prefix_kobo.py, I don't remember which) to consider only the first 2 chars when determining whether to use 11.html, you need to consider if a character is in the Unicode letters class rather than just ASCII, and you might need to add a .replace(" ", "a").

I'll publish my notes on my other findings around the same time I finish dictutil.
geek1011 is offline   Reply With Quote