Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
Previously in many instances the code was allowed to continue
after running jni_rethrow() or jni_throw(). When doing so it
used variables whose values may have changed inside fz_try().
Those variables must in that case be declared using fz_var().
Another way of avoiding this from happening (and thus having
to use fz_var()) is to return from the function immediately
after jni_rethrow()/jni_throw(). All remaining occurrances
where this is not possible still needs fz_var().
The code is now changed so that it either uses fz_var() or
returns early to avoid using variables that have not been
declared using fz_var().
|
|
|
|
|
|
Would be fine were it not for the finite number of local
refs we are allowed.
|
|
Previously an exception was thrown for documents without an outline.
Now document both with and without an outline are handled correctly.
|
|
Apparently, if MuPDF is invoked on a content stream that
comes from a URI, then is.available() can report 0 bytes
(as there is no data buffered). Use a modified formulation
that reads as much data as possible from the stream into
a BufferedOutputStream and then makes a byte array from that.
Would be nicer if the core could actually read from the
stream directly, perhaps, but that can wait for the new JNI
based version.
Thanks to Marc K for identifying the problem and supplying
the patch.
|
|
|
|
|
|
|
|
This is for easy of use, in addition to accepting Buffer.
|
|
|
|
These are meant to make it easy to interact with mupdf's Buffer
object in a normal Java fashion.
|
|
|
|
|
|
|
|
zooming and scrolling.
|
|
|
|
|
|
|
|
|
|
|
|
fz_bound_page needs the correct 2nd argument
pdf_widget_get_type should be pdf_widget_type
|
|
|
|
|
|
Also fix bug in sample java viewer where zoom caused an Exception.
|
|
Some objects get their interfaces expanded or the entire object
is added both corresponding to what was already present in the
mujs interface. Some interfaces, e.g. Buffer.writeLines() has
been adapted to suit Java.
|
|
* Make sure that arguments are checked for NULL before being
passed to ->Get JNI-functions (as these may crash on NULL).
* Remove unused argument to from_Device().
* Consistently use jint and jfloat in JNIEXPORTed functions.
* Check ctx for NULL in all relevant functions.
* Throw Java exception when constructors fail.
* to_*_safe() means that the function doesn't fz_throw().
* to_*_own() means that the function takes ownership of the object.
* Make sure that jprefixing of argument identifies does not
clash with jprefixing of types, specifically jstring.
* Rename (j)colorspace -> (j)cs, (j)shade -> (j)shd,
(j)device -> (j)dev.
* Always check that the context is available in bindings.
* Always check that required arguments are non-NULL or have
decent default values (e.g. for fz_matrix and fz_rect).
|
|
|
|
Reflect API change in example viewer.
|
|
Reflect the change in API in the ios code.
|
|
|
|
|
|
Since the removal of the begin_page device function, structured
text extraction has been unable to correctly establish the
mediabox for extracted pages.
Update the fz_new_stext_page call to take this mediabox
information. This is an API change, but hopefully most people
are calling fz_new_stext_page_from_page or
fz_new_stext_page_from_display_list which are updated here to
cope.
Update all the apps/tools to behave properly.
|
|
We pass pointers from the JNI layer into the java to be stored
as java longs. When doing this it is VITAL that we cast them
correctly as otherwise the JNI layer on android has problems -
presumably because of alignment in the procedure calling
standard.
I'd missed this in one place. Fixed here.
<log></log>
|
|
also: zoom in/out buttons
|
|
imageFromPageWithDevice
|
|
I was forgetting to 'keep' the annot.
Inspection of the code shows just 1 other place where I've
made that mistake, and it's currently disabled (but updated
here anyway).
|
|
These build the mupdf desktop java viewer.
|
|
Use Windows threads rather than pthreads when building on
windows.
|
|
|
|
generated.sh was broken (wrong font path).
load_pnm.c had been omitted from VS projects.
|
|
|
|
Closing a device or writer may throw exceptions, but much of the
foreign language bindings (JNI and JS) depend on drop to never throw
an exception (exceptions in finalizers are bad).
|
|
|
|
|
|
- uses AndroidDrawDevice for rendering
- very simple sample app
- mupdf-specific functionality in a module called "mupdf"
- N-up page display
- page rendering in a background task
Signed-off-by: fredrossperry <fredrossperry@gmail.com>
|
|
also, change SUPPORT_GPROOF to FZ_ENABLE_GPRF
|