-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mupdf: allow memory streams to load resources #2002
mupdf: allow memory streams to load resources #2002
Conversation
Use fz_open_document_with_stream_and_dir instead of fz_open_document_with_stream to allow MuPDF to load resources (images and CSS) when it is loading a HTML document from a memory stream.
Pass the directory that contains the dictionary's ifo file to Mupdf.openDocumentFromText to allow MuPDF to display images referenced by HTML dictionaries. Depends on: koreader/koreader-base#2002 Fixes: koreader#12628
local mupdf_doc = { | ||
doc = W.mupdf_open_document_with_stream(ctx, magic, stream), | ||
doc = W.mupdf_open_document_with_stream_and_dir(ctx, magic, stream, archive), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is fine if it's null?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it is fine with null. The previously used fz_open_document_with_stream just a single line function that uses null as the archive.
Pass the dictionary's res directory to Mupdf.openDocumentFromText to allow MuPDF to display images referenced by HTML dictionaries. Depends on: koreader/koreader-base#2002 Fixes: koreader#12628
Pass the dictionary's res directory to Mupdf.openDocumentFromText to allow MuPDF to display images referenced by HTML dictionaries. Depends on: koreader/koreader-base#2002 Fixes: koreader#12628
Includes: * sqlite: update to 3.47.2 (koreader/koreader-base#1999) * mupdf: fix finalizers (koreader/koreader-base#2001) * mupdf: allow memory streams to load resources (koreader/koreader-base#2002) for #12877 * thirdparty/lua-Spore 0.3.4 (koreader/koreader-base#2003)
Pass the dictionary's res directory to Mupdf.openDocumentFromText to allow MuPDF to display images referenced by HTML dictionaries. Depends on: koreader/koreader-base#2002 Fixes: #12628
Use fz_open_document_with_stream_and_dir instead of fz_open_document_with_stream to allow MuPDF to load resources (images and CSS) when it is loading a HTML document from a memory stream.
This change is