mirror of
https://github.com/koreader/koreader.git
synced 2025-12-18 12:02:09 +01:00
bump crengine, show progress meter on load/re-rendering (#5406)
Includes: - Adds tinyNodeCollection::getStatistics() - epubfmt.cpp: cleanup indentation and small optimisation - Add more progress callback events - Optimisation: avoid re-init for EPUBs with embedded fonts - Fix: don't draw border when border-color: transparent - CSS: ignore 'inherit' inside font-family Show a small progress meter at top left of screen when crengine is loading, re-rendering, and saving cache file (after a 2 second delay to not be bothered on small books). Also add a wrapper for the last remaining bit of code that was accessing _document directly (:getPageOffsetX()).
This commit is contained in:
@@ -435,6 +435,10 @@ function CreDocument:getPageFromXPointer(xp)
|
||||
return self._document:getPageFromXPointer(xp)
|
||||
end
|
||||
|
||||
function CreDocument:getPageOffsetX(page)
|
||||
return self._document:getPageOffsetX(page)
|
||||
end
|
||||
|
||||
function CreDocument:getScreenPositionFromXPointer(xp)
|
||||
-- We do not ensure xp is in the current page: we may return
|
||||
-- a negative screen_y, which could be useful in some contexts
|
||||
@@ -806,6 +810,10 @@ function CreDocument:enableInternalHistory(toggle)
|
||||
self._document:setIntProperty("crengine.highlight.bookmarks", toggle and 2 or 0)
|
||||
end
|
||||
|
||||
function CreDocument:setCallback(func)
|
||||
return self._document:setCallback(func)
|
||||
end
|
||||
|
||||
function CreDocument:isBuiltDomStale()
|
||||
return self._document:isBuiltDomStale()
|
||||
end
|
||||
@@ -822,6 +830,10 @@ function CreDocument:getCacheFilePath()
|
||||
return self._document:getCacheFilePath()
|
||||
end
|
||||
|
||||
function CreDocument:getStatistics()
|
||||
return self._document:getStatistics()
|
||||
end
|
||||
|
||||
function CreDocument:canHaveAlternativeToc()
|
||||
return true
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user