Commit Graph

8771 Commits

Author SHA1 Message Date
Tim van der Meij
52caad6266 Merge pull request #6855 from Snuffleupagus/issue-6854-1
Issue 6854 - Update the link locations to point to the Internet Archive for tests: 20130226130259, JST2007-5, P020121130574743273239, SFAA_Japanese, TaroUTR50SortedList112
2016-01-12 00:52:34 +01:00
Jonas Jenwald
57097c54de Issue 6854 - Update the link locations to point to the Internet Archive for tests: 20130226130259, JST2007-5, P020121130574743273239, SFAA_Japanese, TaroUTR50SortedList112 2016-01-11 23:47:24 +01:00
Jonas Jenwald
c197e47742 Update the link location for 'issue3666.pdf' to point to the Internet Archive
Note that despite the new file having a different hash than the the current one, it does render *identically* and most importantly it uses *the same* JBIG2 functionality.

For reference, please see issue 3666 and PR 3738.
2016-01-11 21:27:00 +01:00
Brendan Dahl
3057b69e45 Merge pull request #6839 from Snuffleupagus/issue-6782
Check that CIDFontType0 fonts does not actually contain OpenType font files (issue 6782)
2016-01-11 08:56:48 -08:00
Tim van der Meij
30b8f41003 Merge pull request #6820 from Snuffleupagus/showText-shadingPattern
Apply Patterns, if necessary, when rendering text
2016-01-08 14:02:56 +01:00
Brendan Dahl
4a215f0892 Merge pull request #6825 from yurydelendik/pdfjsumd
Adds UMD header to pdf.js and pdf.worker.js files.
2016-01-07 15:07:58 -08:00
Tim van der Meij
944d1e6dc5 Merge pull request #6843 from timvandermeij/pr-6796-fixup
shading-pattern: Decreased `Shadings.SMALL_NUMBER`
2016-01-06 16:23:20 +01:00
Daan Sprenkels
90ec2c9294 shading-pattern: Decreased Shadings.SMALL_NUMBER
and added a test case for #6298
2016-01-06 15:26:40 +01:00
Tim van der Meij
3f19b3fee3 Merge pull request #6842 from Snuffleupagus/intelisa-updated-link
Update the link location for 'intelisa.pdf' to point to the Internet Archive
2016-01-06 15:12:06 +01:00
Jonas Jenwald
325abf5f8c Update the link location for 'intelisa.pdf' to point to the Internet Archive
Given the the file changes every now and then, this patch should ensure that we test the *intended* version.
2016-01-06 12:56:31 +01:00
Jonas Jenwald
896e390285 Check that CIDFontType0 fonts does not actually contain OpenType font files (issue 6782)
*This patch follows a similar idea as PR 5756.*

The patch is based on the nice debugging done by Brendan in the referenced issue 6782.
A better way to handle this, and similar issues, would probably be to completely ignore what the PDF file claims about font type/subtype, and just check the actual data. But until that kind of rewrite happens, this patch should help.

Fixes 6782.
2016-01-06 02:19:02 +01:00
Tim van der Meij
4399d01169 Merge pull request #6834 from Snuffleupagus/issue-6832
Strip `null` (\x00) characters from the URLs in LinkAnnotations (issue 6832)
2016-01-05 23:59:25 +01:00
Yury Delendik
96d8b8f8a0 Merge pull request #6837 from Snuffleupagus/issue-3694-fix-manifest
Fix a typo in the "file" entry for issue3694_reduced in test_manifest.json
2016-01-05 14:56:08 -06:00
Jonas Jenwald
0083f63dda Fix a typo in the "file" entry for issue3694_reduced in test_manifest.json
When generating new references locally on Windows, after PR 6724, I get the following output:
```
WARNING: Unable to open file for reading "Error: ENOENT, open 'c:\Users\Jonas\Git\pdfjs\test\pdfs\issue_3694_reduced.pdf'".
Unable to verify the checksum for the files that are used for testing.
Please re-download the files, or adjust the MD5 checksum in the manifest for the files listed above.

```

Compared to the name of the file (`issue3694_reduced.pdf`), you see that the manifest entry has a superfluous underscore in the "file" entry.
2016-01-05 21:23:00 +01:00
Yury Delendik
62ade3e373 Merge pull request #6724 from brendandahl/callsubr
Add validation for callsubr and callgsubr for type 2 charstrings.
2016-01-05 13:46:14 -06:00
Brendan Dahl
eb7c36beb6 Add validation for callsubr and callgsubr for type 2 charstrings. 2016-01-05 09:54:25 -08:00
Jonas Jenwald
97c10e9c08 Strip null (\x00) characters from the URLs in LinkAnnotations (issue 6832)
Apparently some PDF files can have annotations with `URI` entries ending with `null` characters, thus breaking the links.
To handle this edge-case of bad PDFs, this patch moves the already existing utility function from `ui_utils.js` into `util.js`, in order to fix those URLs.

Fixes 6832.
2016-01-04 21:55:20 +01:00
Jonas Jenwald
4e9ea35eee Merge pull request #6827 from timvandermeij/highlight-annotation
Implement support for Highlight annotations
2016-01-02 14:23:52 +01:00
Tim van der Meij
6ef7120a04 Implement support for Highlight annotations 2016-01-01 15:31:46 +01:00
Tim van der Meij
8ed369211a Merge pull request #6823 from timvandermeij/squiggly-annotation
Implement support for Squiggly annotations
2015-12-30 20:34:13 +01:00
Yury Delendik
f340dd5cd5 Adds pdfjs/main_loader module to better mirror pdfjs-dist/build/pdf. 2015-12-30 13:28:57 -06:00
Tim van der Meij
34918a6666 Implement support for Squiggly annotations 2015-12-30 19:37:04 +01:00
Jonas Jenwald
d956177482 Merge pull request #6819 from timvandermeij/strikeout-annotation
Implement support for StrikeOut annotations
2015-12-30 14:44:50 +01:00
Yury Delendik
cbbb9bb82d Adds UMD header to pdf.js and pdf.worker.js files. 2015-12-29 18:15:14 -06:00
Tim van der Meij
e8db825512 Merge pull request #6771 from yurydelendik/requirejs
Removes hardcoded module loading order
2015-12-30 00:37:32 +01:00
Yury Delendik
b8e7efaaa1 Merge pull request #6821 from yurydelendik/bug951051
Bug 951051 - Better crypto key length recovery.
2015-12-29 15:35:15 -06:00
Yury Delendik
c991480687 Better crypto key length recovery. 2015-12-29 15:10:38 -06:00
Jonas Jenwald
1d1f175826 Apply Patterns, if necessary, when rendering text
Currently we're not applying Patterns for text, but only for graphics.

This patch is unfortunately not a complete solution, but rather a step on the way, since there are still some PDF files where the Patterns look more like a solid colour, rather than the intended gradient.
I've been unable to fix these issues completely, and I've not managed to determine if the remaining issues are caused either by the pattern code, the canvas code, or perhaps both.

However, given that even this simple patch improves the current situation quite a bit, I figured that it couldn't hurt to submit it as-is.

 - Fixes 5804.
 - Fixes 6130.
 - Improves 3988 a lot, since the text is now visible. However, it looks like the text is *one* solid colour, instead of the correct gradient.
 - Improves 5432, since the text is no longer gray. (This file also suffers from the same problem as the previous one.)
2015-12-29 20:02:40 +01:00
Yury Delendik
2b2c521213 Hack to avoid intermidiate Chrome failures during tests.
Remove when https://code.google.com/p/chromium/issues/detail?id=572225 is fixed.
2015-12-29 09:20:53 -06:00
Yury Delendik
2f8ae38276 Use UMD headers to detect module loading order. 2015-12-29 09:20:53 -06:00
Yury Delendik
fc3282db56 Adds RequireJS to worker. 2015-12-29 09:20:52 -06:00
Yury Delendik
85e95d34ed Use RequireJS in the viewer, examples and tests. 2015-12-29 09:20:52 -06:00
Tim van der Meij
c5f4b9750e Implement support for StrikeOut annotations 2015-12-29 15:09:28 +01:00
Jonas Jenwald
b32cdf5836 Merge pull request #6813 from timvandermeij/underline-annotation
Implement support for Underline annotations
2015-12-28 23:48:31 +01:00
Jonas Jenwald
85589483d6 Merge pull request #6807 from timvandermeij/popup-annotation-hidden
Ensure that hidden popups do not use any space
2015-12-28 22:58:41 +01:00
Tim van der Meij
ae329afc03 Ensure that hidden popups do not use any space 2015-12-28 18:54:10 +01:00
Tim van der Meij
edf8ccc1d8 Merge pull request #6814 from Snuffleupagus/beginAnnotations-baseTransform
Ensure that the `baseTransform` is applied when rendering annotations
2015-12-28 18:32:50 +01:00
Jonas Jenwald
2f2ea6160b Ensure that the baseTransform is applied when rendering annotations
Fixes 3350.
Fixes 5946.
Fixes 6334.
Fixes 6722.
Probably fixes 3826 (since the PDF files are no longer available, I cannot confirm it).
2015-12-28 16:02:38 +01:00
Tim van der Meij
cd28dd34fe Implement support for Underline annotations 2015-12-28 00:33:41 +01:00
Jonas Jenwald
f17d6721e7 Merge pull request #6808 from timvandermeij/link-annotation-class
Rename and reorder link annotation CSS
2015-12-27 16:40:50 +01:00
Tim van der Meij
26379ddae2 Rename and reorder link annotation CSS 2015-12-27 15:51:58 +01:00
Tim van der Meij
ad4354c0bd Merge pull request #6805 from Snuffleupagus/issue-6804
Do not modify `data.rect` in `AnnotationElement_createContainer`, since that will corrupt the annotation position on subsequent calls
2015-12-27 14:36:45 +01:00
Jonas Jenwald
3c7088dc44 Do not modify data.rect in AnnotationElement_createContainer, since that will corrupt the annotation position on subsequent calls
Fixes 6804; this regressed in PR 6714.
2015-12-27 12:46:20 +01:00
Yury Delendik
17780dab31 Import l10n. 2015-12-26 22:37:07 -06:00
Jonas Jenwald
cba8a87f84 Merge pull request #6792 from timvandermeij/popup-annotation
Implement support for Popup annotations
2015-12-26 18:51:50 +01:00
Tim van der Meij
7d43971f54 Implement support for Popup annotations
Most code for Popup annotations is already present for Text annotations.
This patch extracts the popup creation logic from the Text annotation
code so it can be reused for Popup annotations.

Not only does this add support for Popup annotations, the Text
annotation code is also considerably easier. If a `Popup` entry is
available for a Text annotation, it will not be more than an image. The
popup will be handled by the Popup annotation. However, it is also
possible for Text annotations to not have a separate Popup annotation,
in which case the Text annotation handles the popup creation itself.
2015-12-25 13:17:21 +01:00
Tim van der Meij
05b9d3730a Merge pull request #6785 from yurydelendik/frameworks
Adds/modifies examples for node.js and webpack.
2015-12-21 22:44:58 +01:00
Yury Delendik
79c2f69c32 Adds/modifies examples for node.js and webpack. 2015-12-21 13:46:50 -06:00
Tim van der Meij
eb557d200f Merge pull request #6787 from Snuffleupagus/issue-4914-test-annotations
Change test-case `issue4914` to an `annotations` test
2015-12-21 16:17:51 +01:00
Jonas Jenwald
ae4ec2e347 Change test-case issue4914 to an annotations test
This PDF file (see issue 4914) originally regressed in PR 4318, and was subsequently fixed in PR 4915.

I added the PDF file as a (linked) test-case in PR 6481, in an effort to prevent regressions. Since we at that time didn't have the necessary framework in place, in order to correctly test annotations, this almost regressed *again* in PR https://github.com/mozilla/pdf.js/pull/6672#issuecomment-158689392.

In that PDF file, some of the annotations are both printable and hidden, and should definitely *not* be visible on normal display. Hence this patch, which adds the `annotations` flag to the manifest in order to ensure that those annotations won't be rendered when `intent === 'display'`.
2015-12-21 15:41:18 +01:00