summaryrefslogtreecommitdiff
path: root/source
AgeCommit message (Collapse)Author
2016-08-24Add pdf_array_find to look up the index of an object in an array.Tor Andersson
2016-08-24Bug 696983 - Fix bidirectional XPS spacing.Tor Andersson
Bidirectional setting was not accounted for when advance width was set in the XPS Indices Attribute.
2016-08-24When NULL is added to PDF dicts/arrays, insert null objects.Sebastian Rasmussen
2016-08-24Be stricter in what can be added into arrays/dicts.Sebastian Rasmussen
2016-08-24Do not resolve PDF dict keys before using them.Sebastian Rasmussen
Only direct PDF name objects should be used as arguments, indirect PDF name objects cannot be used.
2016-08-24Always check that PDF dict keys are names in same way.Sebastian Rasmussen
2016-08-24Add macros for checking PDF object type.Sebastian Rasmussen
This avoids resolving object references which is important for dictionary keys.
2016-08-24Turn warnings in dict/array functions into exceptions.Sebastian Rasmussen
2016-08-17zip: Used unpacked entry size, not listed entry size.Sebastian Rasmussen
The size listed in the central directory can be used to allocate an output buffer and inflate can be told to not write more than this number of bytes. The listed size cannot be assumed to be the size of the output data however as the zip file may be corrupted. Instead the size of the output data must be given by inflate and must be less than or equal to the listed size. The same reasoning goes for uncompressed entries and simply reading the uncompressed data from the archive file (which may terminate early). Fixes indeterminism broken_png_image.xps.
2016-08-16Android viewer: get experimental proofing to build again.fred ross-perry
- use FZ_ENABLE_GPRF everywhere - chasing changed fz APIs in gprf-doc.c
2016-08-16JS: Push null if image lacks an image mask.Sebastian Rasmussen
2016-08-07Fix fz_vsnprintf() so it prints %zu.Sebastian Rasmussen
Previously we might and up with prints such as: error: malloc of array (%zu x %zu bytes) failed because %zu was never interpreted on 32-bit platforms where sizeof(size_t) < 8. After this fix we now get: error: malloc of array (14445 x 118800 bytes) failed
2016-08-02JS: Add Path.curveTo*(), similar to JNI.Sebastian Rasmussen
2016-08-02JS: Add several Image.get*() methods similar to JNI.Sebastian Rasmussen
2016-08-02JS: Add Pixmap.getX() and .getY() similar to JNI.Sebastian Rasmussen
2016-08-02Re-add line endings for mutool show grep.Sebastian Rasmussen
Commit c22e6a6dc2bf6acbac955bd5fbdd896329dfd725 accidentally removed the line endings for: mutool show file.pdf grep
2016-08-02Remove function not being called.Sebastian Rasmussen
2016-08-02Parse more fz_document_writer() options.Sebastian Rasmussen
2016-08-01Move to bitfields in fz_font rather than chars/ints etc.Robin Watts
2016-08-01Bug 696984: Badly rendered characters.Robin Watts
The type3 font(s) in the file have an invalid (0 sized) bbox, hence the clipping of the chars goes wrong. We now spot the invalid bbox, and suppress the clipping.
2016-07-31Make mutool clean only iterate over valid link annotations.Sebastian Rasmussen
2016-07-31Make sure that number of colors in mesh params is valid.Sebastian Rasmussen
Fixes bug 696954.
2016-07-22Bug 696941: Fix use after free.Robin Watts
The file is HORRIBLY corrupt, and triggers Sophos to think it's PDF malware (which it isn't). It does however trigger a use after free, worked around here.
2016-07-22Move hash calculation outside locked region.Robin Watts
Try to reduce contention on the glyphcache lock.
2016-07-22Speed tweaks to muraster.Robin Watts
Divide up the work amongst the threads to solve the odd situation of larger buffers producing slower runtimes. Avoid creating (and hence clearing) larger bitmaps than required at the end of the run.
2016-07-22Fix pixmap and reference leak in pdfextract.Sebastian Rasmussen
2016-07-20Fix memory leaks during annotation synthesis.Robin Watts
2016-07-20Add char encoding to produced SVG files.Robin Watts
Stops a warning with the validator.
2016-07-20Fix memory leak in fz_new_buffer_from_image_as_png.Robin Watts
2016-07-20Fix missing alpha only plotter.Robin Watts
Spotted with: mutool draw -A0 -r600 -o out.ppm J11_acrobat.pdf
2016-07-20Fix timing (-st) reporting for muraster and default to no BGPRINTRay Johnston
Since -P only turns on BGPRINT (parsing and rendering in different threads), the default bgprint.active needs to be false. The filename and pagenum were only being printed for bgprint.active mode, and the timing.total wasn't being updated for bgprint.active mode. Also missing \n on bgprint.active showtime output.
2016-07-18Bug 696927: Move debug printfs to fz_warn.Robin Watts
I did debate about removing these, but it looks like they are flagging up places where processing is incomplete, so I've left them in, and they will just appear on stderr now.
2016-07-18Attempt to fix PWG output.Robin Watts
Broken by alpha changes.
2016-07-15Add -P flag to muraster.Robin Watts
2016-07-15Add interface indicating if a document is reflowable.Sebastian Rasmussen
2016-07-14Fix typo in fz_new_stext_page_from_page.Tor Andersson
2016-07-14Fix whitespace and indentation.Tor Andersson
2016-07-13Bug 696699: Fix Text extraction mediabox information.Robin Watts
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.
2016-07-13Bug 696892: PDF annotation appearance stream synthesis SEGVRobin Watts
The code would SEGV if we were trying to synthesise an appearance stream for an annotation, and the docs pdf resources table had not been initialised. We now intialise the pdf resource tables when we initialise a pdf device. This is the earliest point we know we are going to need them, and covers all cases.
2016-07-13Use fz_malloc_struct rather than fz_calloc.Robin Watts
This helps with Memento debugging, and looks neater.
2016-07-13Fix memory leaks in SVG device.Robin Watts
2016-07-13Bug 696846: Fix badly formed SVG output.Robin Watts
This has been broken since fz_text was changed to be multiple fz_text_spans.
2016-07-13Fix knockout/mask interaction.Robin Watts
When we are rendering a knockout group, we set the knockout flag. Do NOT carry this forward into the renderings of any softmasks. This fixes Bug 696870 and 696872.
2016-07-13Fix MSVC build of murunRobin Watts
2016-07-12js: Add doc.loadOutline and page.getLinks functions.Tor Andersson
These just convert fz_outline and fz_link into plain JS arrays and objects with no associated native userdata.
2016-07-12js: Check if some arguments exist before converting to boolean/number.Tor Andersson
2016-07-12Fix typo in fz_new_image_from_pixmap.Tor Andersson
2016-07-12Fix bugs in pdf_add_image.Tor Andersson
2016-07-12js: Fix memory leak in new Image().Tor Andersson
2016-07-12xps: Only recognize <dir>/_rels/.rels type paths, not any .rels file.Tor Andersson