Originally Posted by jsfaint
I have a question about Librerator R2
When I open epub file in librerator, the Chinese character will become "??", then I change font to "Droid Sans Fallback", it's OK.
I try to modify "DCREREADER_DEFAULT_FONT" in defaults.lua, but it looks not work.
In librerator R1, it's good by default.
Yeah, I changed default font to "Droid Sans" in R2, it was "Droid Sans Fallback" in R1. The reason I did this is because epubs I tested opened faster when opened for the first time with "Droid Sans" than with "Droid Sans Fallback". I also thought that not many people would need to use "Droid Sans Fallback", and that if they do, it can easily be changed
Now, explanation how font selection works
If you freshly installed Librerator, the value from DCREREADER_DEFAULT_FONT will be used when you first open the book. When you close that book, the font used will be saved with configuration specific to this book (files in history folder). So, if you changed the font using Menu/Settings/Fonts, that font will be saved for that book. If not, value from DCREREADER_DEFAULT_FONT at that moment will be saved as the font used for that book. That's why if you now change the value of DCREREADER_DEFAULT_FONT it won't have the effect on this book, because the value saved with the book config will have priority. Value from DCREREADER_DEFAULT_FONT wll be used only for new, previously unopened books.
So far, so good. Here's a catch: if you use option Menu/Settings/Fonts/Set current settings as defaults, the values that are currently used will be used as default in the future, for books that you never opened before. This will have priority over the value in DCREREADER_DEFAULT_FONT.
I hope this explanation makes sense. If not, let me know and I'll try to explain it better
If it's simpler for you, you can do this:
- delete the contents of history folder
- delete the contents of cr3cache folder
- delete settings.reader.lua file from librerator folder
- edit defaults.lua to look like this:
DCREREADER_DEFAULT_FONT = "Droid Sans Fallback"
DCREREADER_PAGE_HEADER_FONT = "Droid Sans Fallback"
Now it should be just like R1.
Another way to do this is to open any book, set font using Menu/Settings/Fonts, and then Menu/Settings/Fonts/Set current settings as default. This will work only on the books you never opened before, so you'd have to manually change font on every book you opened before you did this. (or, you can delete contents of history folder)
I hope this helps.
Sorry for my poor English, I'm not native.
Don't worry about your English, it's perfectly fine. I'm not a native either. :P