mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
mod: add html support in crereader
This commit is contained in:
@@ -16,6 +16,9 @@ end
|
||||
function CREReader:open(filename)
|
||||
local ok
|
||||
local file_type = string.lower(string.match(filename, ".+%.([^.]+)"))
|
||||
if file_type == "html" then
|
||||
file_type = "htm"
|
||||
end
|
||||
local style_sheet = "./data/"..file_type..".css"
|
||||
ok, self.doc = pcall(cre.openDocument, filename, style_sheet,
|
||||
width, height)
|
||||
|
||||
Reference in New Issue
Block a user