Quote:
Originally Posted by pazos
Certainly, from a maintainer's perspective, makes little sense to offer inferior options on menus. Better to fix the bugs that make you consider that inferior option in the first place 
|
I agree, but there's another layer to it. KoReader is so customizable that the setting/option in conversation needs clarification, for example lua files in koreader/settings/ folder are also settings, non-UI ones, so this particular one might be implemented using this "second-class" feature (in context of your usage the "inferior" word

)
Quote:
Originally Posted by pazos
But you're free to do what you want with users patches, of course.
|
A little follow-up for my attempt to make a patch. First, thanks for such a powerful ecosystem with patching/scripting/plugin, looks like the sky's the limit with all those. A minor note: I suggest to add a little note about that patching doesn't work in FDroid flavor of the program in the
patch wiki. Actually what I described as a mixed result was no-result (sometimes showing the correct rotation for epub files) since I tried all this with FDroid version, that had completely ignored my patch. A second minor note is that the despite the fact that FDroid is limited with patching, the menu for patch management was still working allowing disabling the patches.
Anyway, the script below works for any file (epub, pdf) and probably for any view of the program. Anyone who want to force the program rotation (vs system) for KoReader 2023.08 should create the file named 1-force-soft-rot.lua in the sdcard/koreader/patches directory with the following text
Code:
local logger = require("logger")
local frBuffer = require("ffi/framebuffer_android")
frBuffer.setRotationMode = function(self, mode)
logger.info("Forcing software rotation")
frBuffer.parent.setRotationMode(self, mode)
end
frBuffer.getRotationMode = function(self)
return self.cur_rotation_mode
end