summaryrefslogtreecommitdiff
path: root/platform/java
AgeCommit message (Collapse)Author
2018-09-07jni: Check exposed constants for consistency with C constants.Sebastian Rasmussen
2018-09-07jni: Remove unused flags and improve the names of some others.Sebastian Rasmussen
2018-09-07jni: Depend on fz_buffer() for default buffer size.Sebastian Rasmussen
2018-09-07jni: Make Device interface abstract.Sebastian Rasmussen
This requires subclasses of Device to implement its full interface. It also makes the compiler complain if there is a difference between the interface in Device and its subclasses. The drawback is that all Devices are required to implement all methods, but that is an easy hurdle to overcome. This change found the discrepancies between the Device, NativeDevice and TraceDevice interfaces fixed in the previous commits.
2018-09-07jni: Update TraceDevice to adhere to Device interface.Sebastian Rasmussen
Several previous updates to the Device interface required updates to TraceDevice but were forgotten.
2018-09-07jni: Improve whitespace situation in TraceDevice.Sebastian Rasmussen
2018-09-07jni: Update NativeDevice to adhere to Device interface.Sebastian Rasmussen
2018-09-07jni: Make Device interface in Java and JNI correspond to each other.Sebastian Rasmussen
2018-09-07jni: Fix typo in ColorParams.Sebastian Rasmussen
2018-09-06jni: Remove redundant public access modifier.Sebastian Rasmussen
Abstract methods in interfaces offer no implementation and are implicitly declared public, making a public access modifier redundant.
2018-09-06jni: Add interface for snapping selection to structured text.Sebastian Rasmussen
2018-09-06jni: Add StructuredTextWalker interface.Sebastian Rasmussen
2018-08-10Fix Android java build.Tor Andersson
2018-08-10FIXUP pdf_update_page: use JNI_FALSETor Andersson
2018-08-10Rejig pdf_update_page and pdf_update_annot.Tor Andersson
The intent is for a user to iterate over the annotations on a page calling pdf_update_annot for each one. If this function returns true, then the annotation has changed since the last time it was called, and the user needs to re-render. pdf_update_page is a simple loop over the annotations on a page, for use if you only care about page level granularity. Users should no longer look at or change the pdf_annot.has_new_ap field.
2018-08-01Update jbig2dec.Sebastian Rasmussen
2018-07-05Pass rects by value: device and document interface.Tor Andersson
2018-07-05Pass matrices by value: device and document interface.Tor Andersson
2018-07-05Pass rect and matrix by value in geometry functions.Tor Andersson
Several things irk me about passing values as const pointers: * They can be NULL, which is not a valid value. * They require explicit temporary variables for storage. * They don't compose easily in a legible manner, requiring weird pointer passing semantics where the variable being assigned is hidden as an argument in the innermost function call. * We can't change the value through the pointer, requiring yet more local variables to hold copies of the input value. In the device interface where we pass a matrix to a function, we often find ourselves making a local copy of the matrix so we can concatenate other transforms to it. This copying is a lot of unnecessary busywork that I hope to eventually avoid by laying the groundwork with this commit. This is a rather large API change, so I apologize for the inconvenience, but I hope the end result and gain in legibility will be worth the pain.
2018-07-04Rename pdf_get_annot_contents to pdf_annot_contents.Tor Andersson
Since the function no longer returns ownership of the string, use the common naming convention.
2018-07-04java: Fix bugs introduced when caching text strings in pdf_obj.Tor Andersson
2018-06-22Use fz_quad type in structured text and selection/highlighting.Tor Andersson
2018-06-22Keep copy of decoded utf8 text string in pdf_obj.Tor Andersson
Removes the need to alloc/free text strings in the API, allowing for simple functions like pdf_dict_get_text_string.
2018-06-11Fix Windows JNI builds.Robin Watts
2018-05-18Fix android build.Tor Andersson
2018-05-16Purge unused functions.Tor Andersson
2018-05-09Fix java build.Tor Andersson
2018-04-26Clean up and simplify makefiles.Tor Andersson
* Use autogenerated header file dependencies. * Use mkdir to create target output directory directly.
2018-04-25Update Noto fonts.Tor Andersson
Import Source Han Serif 1.001. Use serif fonts in preference for sans.
2018-04-25Default CJK language to traditional chinese.Tor Andersson
2018-04-25Use objcopy to compile font resources.Tor Andersson
2018-04-25Remove document argument from pdf_new_primitive functions.Tor Andersson
Also remove useless pdf_new_null and pdf_new_bool functions. Use the PDF_NULL, PDF_TRUE, and PDF_FALSE macros instead.
2018-04-24Remove need for namedump by using macros and preprocessor.Tor Andersson
Add a PDF_NAME(Foo) macro that evaluates to a pdf_obj for /Foo. Use the C preprocessor to create the enum values and string table from one include file instead of using a separate code generator tool.
2018-04-12Update Android.mk for recent build changes.Tor Andersson
2018-04-05jni: Expose interfaces for setting gamma and inverting pixmaps.Sebastian Rasmussen
2018-04-03Android: Scavenge on Bitmap.lockPixels() failure.Robin Watts
If Bitmap.lockPixels fails with an allocation error, scavenge in the store.
2018-04-03Android: Avoid crashes if we fail to lock a Bitmap.Robin Watts
If a call to Bitmap_lockPixels() fails, then previously we would have continued on blindly and tried to use it anyway. Now, spot failures and return so we get a java exception.
2018-03-22Add phony target to java makefile so it properly rebuilds the native lib.Tor Andersson
Always recurse for the native library, so that it will be rebuilt if the sources change.
2018-03-22Load most annotations, even if they are missing appearances.Tor Andersson
Filter out Link and Popup annotations. Links are not comments, popup annotations are auxiliary information for other annotations, so neither of these types should be present in our list of annotations, but all other annotations should be there, whether they have appearance streams or not. Ensure has_new_ap is zero when first loaded, and changed if either the active AP object is changed or the current AP content stream is updated.
2018-03-16Add simple fonts with 8-bit greek and cyrillic encodings.Tor Andersson
Use KOI8-U for Cyrillic, and ISO 8859-7 for Greek. Use with 'mutool create' using an extra argument to the %%Font directive: %%Font TmRmC Times-Roman Cyrillic BT /TmRmC 16 Tf 10 10 Td <fa c4 d2 c1 d7 d3 d4 d7 d5 ca d4 c5 21> Tj ET The alternatives are "Latin", "Greek", and "Cyrillic".
2018-03-16Add simple CJK font creation.Tor Andersson
Create a non-embedded CJK font using UTF-16 encoding. This can be used in mutool create like so: %%CJKFont Ming GB1 BT /Ming 10 Tf 100 100 Td <4F60 597D> Tj ET
2018-03-16Fix java build.Tor Andersson
2018-03-16jni: Fix expression conflating booleans and bitfields.Sebastian Rasmussen
2018-03-12jni: Fix reference counting when creating PDF annotations.Sebastian Rasmussen
2018-03-12jni: Temporary fix to make sure annot AP field is updated.Tor Andersson
2018-02-27Use fz_point for pdf_set_annot_ink_list and vertices too.Tor Andersson
2018-02-27Improve line ending style accessors.Tor Andersson
2018-02-27Add annotation Vertices creation functions.Tor Andersson
2018-02-27jni: Add the ability to supply extra C flags to Android libmupdf builds.Fred Ross-Perry
Use the MUPDF_EXTRA_CFLAGS, CPPFLAGS, LDLIBS, and LDFLAGS variables.
2018-02-13Add JNI and JS bindings to layer device calls.Tor Andersson