Commit Graph

7611 Commits

Author SHA1 Message Date
Emanuel Arguinarena
3d01c345a1 Add marker segment (PLT, PLM) and refactor TLM 2015-01-11 22:54:50 +01:00
Jonas Jenwald
ad41a2d574 Add support for TrueType (0, 0) cmap tables (issue 5501 and 5574) 2015-01-11 14:54:12 +01:00
Jonas Jenwald
eac168f3cc Refactor searching for end of inline (EI) JPEG image streams
This patch changes searching for EI image streams to rely on the EOI (end-of-image) marker for DCTDecode filters (i.e. JPEG images).
2015-01-10 23:55:55 +01:00
Jonas Jenwald
6dfc73a5da Modify |getUint16| to correctly handle missing data in Stream, DecodeStream and ChunkedStream 2015-01-10 23:55:54 +01:00
Jonas Jenwald
35e668079d Merge pull request #5627 from yurydelendik/tel
Whitelists 'tel' schema.
2015-01-10 18:21:36 +01:00
Jonas Jenwald
8d0c442004 Merge pull request #5632 from yurydelendik/b2g-start
Fixes B2G file open sequence.
2015-01-09 18:00:39 +01:00
Yury Delendik
d52289d8fd Fixes B2G file open sequence. 2015-01-09 07:46:34 -06:00
Brendan Dahl
6ceb652abb Merge pull request #5554 from yurydelendik/apiref
Refactors getDocument and adds PDFDataRangeTransport.
2015-01-08 14:24:38 -08:00
Yury Delendik
982accf1d7 Whitelists 'tel' schema. 2015-01-08 09:10:42 -06:00
Jonas Jenwald
5332c02a02 Fix lint error: "test/webserver.js: line 177, col 106, Line is too long." 2015-01-08 12:22:34 +01:00
Yury Delendik
4ec132a2ba Adds encoding for test server index page. 2015-01-07 21:35:48 -06:00
Yury Delendik
3a540ca120 Merge pull request #5622 from Snuffleupagus/move-pagerendered-event
Move the |pagerendered| event to pdf_page_view.js
2015-01-07 14:16:51 -06:00
Yury Delendik
34bed638bb Merge pull request #5600 from timvandermeij/str-undefined
Implement guards for stringToBytes and bytesToString
2015-01-06 16:27:17 -06:00
Jonas Jenwald
95dd9ee185 Move the |pagerendered| event to pdf_page_view.js
Also deprecates the |pagerender| event, except for GENERIC builds.
2015-01-06 21:44:22 +01:00
Yury Delendik
039c7b4085 Merge pull request #5606 from Snuffleupagus/textlayerrendered
Add a |textlayerrendered| event
2015-01-06 14:42:06 -06:00
Jonas Jenwald
3f061cef86 Add a |textlayerrendered| event 2015-01-06 17:57:32 +01:00
Yury Delendik
34203e5367 Merge pull request #5618 from yurydelendik/v1.0.1040
Version 1.0.1040
2015-01-06 08:23:07 -06:00
Yury Delendik
e7e41b7719 Version 1.0.1040 2015-01-06 08:21:39 -06:00
Yury Delendik
e0f6071178 Merge pull request #5603 from Rob--W/xhr-range-206-bugfix
Use Content-Range instead of Content-Length #5512
2015-01-06 07:40:38 -06:00
Rob Wu
c02b2cb37c Use Content-Range instead of Content-Length #5512
Use Content-Range header instead of Content-Length when the
response has status code 206, to work around issue #5512,
which is caused by a bug in Chrome (since version 39):
https://code.google.com/p/chromium/issues/detail?id=442318
2015-01-06 14:26:41 +01:00
Yury Delendik
3a61edfcae Refactors getDocument and adds PDFDataRangeTransport. 2015-01-05 21:45:01 -06:00
Jonas Jenwald
42a00394b0 Remove unused anchor links placed before every page
In old versions of the viewer, anchor links were used to be able to scroll a page into view. Since we for quite some time have had a `scrollIntoView` function which handles this, the anchor links are no longer necessary and I believe that they can be removed. Doing so will reduce the total number of DOM elements in the viewer.

For most documents this patch will probably not make much of a difference performance wise, but for very long (1000+ pages) documents this could help performance especially on lower powered hardware.
2015-01-05 20:42:56 +01:00
Brendan Dahl
e93cf5ca97 Merge pull request #5552 from yurydelendik/pdfpageview
Creates/refactors PDFPageView class
2015-01-05 11:26:36 -08:00
Tim van der Meij
997096f40d Merge pull request #5612 from Archaeopteryx/master
Add missing comma to German add-on description
2015-01-03 20:39:24 +01:00
Archaeopteryx
deeca31f82 Add missing comma to German add-on description 2015-01-03 20:22:16 +01:00
Tim van der Meij
6e99c29cf8 Implement guards for stringToBytes and bytesToString 2015-01-02 23:35:51 +01:00
Yury Delendik
4c57ef68c3 Imports l10n 2015-01-02 09:10:11 -06:00
fkaelberer
32c32c18e3 Better thumbnail image scaling 2015-01-02 15:40:30 +01:00
Yury Delendik
e36cdcf3d2 Merge pull request #5382 from Snuffleupagus/zoom-arrow-nightly
Fix the placement of arrows in the zoom box
2015-01-02 08:23:01 -06:00
Yury Delendik
55098bcdf6 Merge pull request #5602 from Snuffleupagus/issue-5599
Ensure that |get fingerprint| doesn't fail if the ID is not an array (issue 5599)
2014-12-30 10:05:42 -06:00
Jonas Jenwald
1fea44ce14 Ensure that |get fingerprint| doesn't fail if the ID is not an array (issue 5599)
According to the [PDF specification](http://www.adobe.com/content/dam/Adobe/en/devnet/acrobat/pdfs/PDF32000_2008.pdf#page=51) the `ID` should be an array. To prevent errors if the PDF file violates that part of the spec, check that the `ID` is actually an array.

Fixes 5599.
2014-12-30 16:16:43 +01:00
fkaelberer
1d31018c7d Make thumbnail CSS size independent of data-loaded tag 2014-12-30 15:07:20 +01:00
fkaelberer
2bb981a835 Ensure constant 7px thumbnail border width 2014-12-30 15:07:20 +01:00
Jonas Jenwald
6e66e30d92 Merge pull request #5597 from timvandermeij/ccitt-regression
CCITTFaxStream: fix regression when EncodedByteAlign is true and EndOfLine is false
2014-12-30 11:48:47 +01:00
Jonas Jenwald
86edb8687d Fix the placement of arrows in the zoom box
Now that [bug 649849](https://bugzilla.mozilla.org/show_bug.cgi?id=649849) has been fixed, adding support for `-moz-appearance: none`, the arrow is now too close to the text in the zoom box. This is currently only an issue in Nightly, but assuming the patch doesn't get backed out, this will soon affect all versions of Firefox.

The only simple solution I could find seems to be removing `*-appearance: none` rules from the CSS. I haven't been able to find any easier solutions that still looks the same with/without bug 649849.
2014-12-30 11:37:21 +01:00
Tim van der Meij
b835ef425e CCITTFaxStream: fix regression when EncodedByteAlign is true and EndOfLine is false 2014-12-30 00:07:35 +01:00
Tim van der Meij
f1689cf78d Merge pull request #5594 from Snuffleupagus/issue-4379-test
Add a reduced test case for issue 4379
2014-12-29 22:19:07 +01:00
Jonas Jenwald
75767abb09 Add a reduced test case for issue 4379
This should have been part of PR 5136.

Based on comments https://github.com/mozilla/pdf.js/issues/4379#issuecomment-51221787 and https://github.com/mozilla/pdf.js/issues/4379#issuecomment-51475463, it should be OK to include the PDF file in the repo.
2014-12-29 16:28:23 +01:00
Jonas Jenwald
50fe7c8d0a Merge pull request #5571 from timvandermeij/annotation-rewrite-2
Remove unused hasOperatorList code
2014-12-27 12:14:08 +01:00
Jonas Jenwald
bcfdd5bcb8 Merge pull request #5578 from Snuffleupagus/travis-jsm-lint
Update linting on Travis to cover *.jsm files (PR 5406 followup)
2014-12-23 13:09:53 +01:00
Jonas Jenwald
8a7499b190 Update linting on Travis to cover *.jsm files (PR 5406 followup)
Trivial followup to PR 5406.
2014-12-23 13:07:35 +01:00
Jonas Jenwald
406b57fae4 Merge pull request #5569 from timvandermeij/annotation-rewrite-1
Remove unused annotation highlight div
2014-12-23 11:17:20 +01:00
Yury Delendik
72bb48b92e Merge pull request #5566 from MaMazav/Bug_fix_Empty_packet_advance_iterator
Fixed empty packet parsing bug
2014-12-22 08:15:41 -06:00
Yury Delendik
96647877ec Merge pull request #4615 from Snuffleupagus/canvas-enforce-min-line-width
Enforce minimum line widths
2014-12-21 22:12:45 -06:00
Tim van der Meij
91aa3925ee Remove unused hasOperatorList code 2014-12-21 19:33:14 +01:00
Tim van der Meij
c67ad28673 Remove unused annotation highlight div
This is now done using CSS. For annotation-heavy documents this change makes the DOM much lighter.
2014-12-21 17:38:22 +01:00
Tim van der Meij
6e994b15e2 Merge pull request #5214 from CodingFabian/optimize-annotation-layer
Improves rendering performance of annotation layers.
2014-12-21 16:50:36 +01:00
Yury Delendik
513a3d8c91 Replaces text selection example 2014-12-20 23:41:34 -06:00
Yury Delendik
2565e627a3 Refactors draw method in PDFPageView; makes optional some PDFPageViewOptions options 2014-12-20 23:41:34 -06:00
Fabian Lange
979635138a Improves rendering performance of annotation layers.
This change does the following:
 * Address TODO to remove getEmptyContainer helper.
 * Not set container bg-color. The old code is incorrect, causing it to
   not have any effect. It sets color to an array (item.color) rather
   css string. Also in most cases it would set it to black background
   which is incorrect.
 * only add border instructions when there is actually a border
 * reduce memory consumption by not creating new 3 element arrays for
   annotation colors. In fact according to spec, this would be incorrect,
   as the default should be "transparent" for an empty array. Adobe
   Reader interprets a missing color array as black however.

Note that only Link annotations were actually setting a border style and
color. While Text annotations might have calculated a border they did
not color it. This behaviour is now controlled by the boolean flag.
2014-12-20 22:49:58 +01:00