Commit Graph

8326 Commits

Author SHA1 Message Date
Jonas Jenwald
b05652ca97 [api-minor] Let getAnnotations fetch all annotations by default, unless an intent is specified
Currently `getAnnotations` will *only* fetch annotations that are either `viewable` or `printable`. This is "hidden" inside the `core.js` file, meaning that API consumers might be confused as to why they are not recieving *all* the annotations present for a page.

I thus think that the API should, by default, return *all* available annotations unless specifically told otherwise. In e.g. the default viewer, we obviously only want to display annotations that are `viewable`, hence this patch adds an `intent` parameter to `getAnnotations` that makes it possible to decide if only `viewable` or `printable` annotations should be fetched.
2015-11-22 15:51:37 +01:00
Tim van der Meij
aa75c4fe4e Merge pull request #6676 from Archaeopteryx/documentColorsQuoteEscaping
document_colors_disabled shouldn't escape quotes (compare-locales warning)
2015-11-22 15:13:13 +01:00
Yury Delendik
0029000c9f Merge pull request #6671 from Snuffleupagus/make-stripCommentHeaders-less-gready
Make `stripCommentHeaders` less greedy, to ensure that it doesn't eat 'use strict' directive at the top of files (PR 6627 follow-up)
2015-11-22 07:24:20 -06:00
Jonas Jenwald
c310a3790e Make stripCommentHeaders less greedy, to ensure that it doesn't eat 'use strict' directive at the top of files (PR 6627 follow-up)
While browsing through the latest PDF.js update on mozilla-central, see https://hg.mozilla.org/integration/fx-team/rev/aef06cd725fc, I noticed that the `'use strict';` directives were missing at the top of a number of files.
This is fallout from the changes made in `make.js` in PR 6627, since `stripCommentHeaders` previously relied on the existence of the mode-lines.

I'm assuming that we do want *all* of the code (e.g. the viewer too) to execute in strict mode, hence this patch tweaks `stripCommentHeaders` to make it less greedy.
2015-11-22 14:17:37 +01:00
Jonas Jenwald
9de056f242 Update l10n files 2015-11-22 12:06:06 +01:00
Jonas Jenwald
97cb7ff2e6 Merge pull request #6672 from timvandermeij/annotation-flags
Refactor annotation flags code
2015-11-22 10:52:18 +01:00
Sebastian Hengst
27577a714f Issue #6569 - document_colors_disabled shouldn't escape quotes (compare-locales warning) 2015-11-22 10:14:25 +01:00
Tim van der Meij
0991c06395 Refactor annotation flags code
This patch makes it possible to set and get all possible flags that the PDF specification defines. Even though we do not support all possible annotation types and not all possible annotation flags yet, this general framework makes it easy to access all flags for each annotation such that annotation type implementations can use this information.

We add constants for all possible annotation flags such that we do not need to hardcode the flags in the code anymore. The `isViewable()` and `isPrintable()` methods are now easier to read. Additionally, unit tests have been added to ensure correct behavior.

This is another part of #5218.
2015-11-22 01:06:37 +01:00
Jonas Jenwald
373da010ac Move the globals comments in bidi.js and metadata.js to after the Copyright comments 2015-11-21 18:43:08 +01:00
Tim van der Meij
df46b64045 Merge pull request #6669 from Snuffleupagus/PDFPageView-default-scale
Use `DEFAULT_SCALE` instead of `1.0` as the default value if the `scale` option isn't specified when initializing `PDFPageView`
2015-11-20 15:43:02 +01:00
Jonas Jenwald
93f4f7a649 Use DEFAULT_SCALE instead of 1.0 as the default value if the scale option isn't specified when initializing PDFPageView
A small piece of cleanup, in order to avoid unnecessarily hardcoding a default value.
2015-11-20 13:30:04 +01:00
Tim van der Meij
27292b2046 Merge pull request #6665 from timvandermeij/seamonkey
Update README.md to add Seamonkey compatibility
2015-11-19 23:15:12 +01:00
polarbearing
a90991b188 Update README.md to add Seamonkey compatibility 2015-11-19 23:08:28 +01:00
Brendan Dahl
fc2d7e88b6 Merge pull request #6619 from yurydelendik/mv-textlayer
[api-minor] Moving text layer rendering into src/display and better "text" testing.
2015-11-19 13:20:10 -08:00
Brendan Dahl
1250e35ad5 Merge pull request #6653 from yurydelendik/version1.3
Version 1.3
2015-11-19 11:41:48 -08:00
Yury Delendik
bd7f121c83 Better "text" testing. 2015-11-19 11:03:52 -06:00
Yury Delendik
56ccaea99b Move text layer building logic into src/display/text_layer.js 2015-11-19 10:50:27 -06:00
Yury Delendik
2f34fd46cb Move CustomStyle. 2015-11-19 10:47:17 -06:00
Yury Delendik
467c6f93b5 Merge pull request #6662 from Snuffleupagus/issue-6661
Ensure that the `hidden` attribute is always removed from the canvas when rendering is complete (issue 6661)
2015-11-19 07:50:45 -06:00
Jonas Jenwald
f341d81ae8 Ensure that the hidden attribute is always removed from the canvas when rendering is complete (issue 6661)
Fixes 6661.
2015-11-19 12:31:49 +01:00
Tim van der Meij
43de3cc1f3 Merge pull request #6656 from Snuffleupagus/issue-1055-reduced-test
Replace the unavailable linked test-case for issue 1055 with a reduced test-case
2015-11-18 22:31:38 +01:00
Jonas Jenwald
055573fc83 Replace the unavailable linked test-case for issue 1055 with a reduced test-case
Re: issue 1055 and PR 1095.
2015-11-18 13:48:44 +01:00
Yury Delendik
d7b3a09520 Version 1.3 2015-11-17 19:48:15 -06:00
Yury Delendik
194994a289 Merge pull request #6551 from yurydelendik/subaa
[api-minor] Enables subpixel anti-aliasing for most of the content.
2015-11-17 19:45:32 -06:00
Yury Delendik
2f1a626d6a Merge pull request #6640 from dsprenkels/issue-6006-radial-gradient-size
Apply transformation matrix to RadialGradient radiuses
2015-11-17 11:40:13 -06:00
Tim van der Meij
d000f039af Merge pull request #6647 from Snuffleupagus/issue-845-reduced-test
Replace the unavailable linked test-case for issue 845 with a reduced test-case
2015-11-17 00:26:09 +01:00
Brendan Dahl
3dd4764158 Merge pull request #6646 from yurydelendik/version1.2.109
Version 1.2.109
2015-11-16 15:24:51 -08:00
Daan Sprenkels
6ce83d3290 apply transformation matrix to RadialGradient radiuses,
not only to circle origin points
fix for #6006
2015-11-17 00:20:42 +01:00
Jonas Jenwald
bd8d3a78a3 Replace the unavailable linked test-case for issue 845 with a reduced test-case
Re: issue 845 and PR 1977.
2015-11-16 23:38:23 +01:00
Yury Delendik
99f9b523c2 Merge pull request #6627 from prometheansacrifice/use-editorconfig
Uses editorconfig to maintain consistent coding styles
2015-11-16 13:51:45 -06:00
Yury Delendik
94a64b5f3d Version 1.2.109 2015-11-16 13:20:53 -06:00
Yury Delendik
37f511cb65 Merge pull request #6645 from Snuffleupagus/issue-3405-reduced-test
Replace the unavailable linked test-case for issue 3405 with a reduced test-case
2015-11-16 11:37:41 -06:00
Yury Delendik
c506ca6ba1 Merge pull request #6642 from Snuffleupagus/pr-2606-reduced-tests
Replace the unavailable linked test-cases for PR 2606 with reduced test-cases
2015-11-16 11:29:52 -06:00
Yury Delendik
b2e3c59372 Merge pull request #6639 from Snuffleupagus/pr-197-reduced-test
Replace the unavailable linked test-case for PR 197 with a reduced test-case
2015-11-16 11:27:10 -06:00
Yury Delendik
661220e4ef Merge pull request #6638 from Snuffleupagus/issue-1655-reduced-test
Replace the unavailable linked test-case for issue 1655 with a reduced test-case
2015-11-16 11:24:35 -06:00
Yury Delendik
1d8800370a Allow subpixel anti-aliasing for most of the content. 2015-11-16 10:50:02 -06:00
Jonas Jenwald
1478241c8e Replace the unavailable linked test-case for issue 3405 with a reduced test-case
Re: issue 3405 and PR 3861.
2015-11-16 17:06:53 +01:00
Jonas Jenwald
841831f35e Replace the unavailable linked test-cases for PR 2606 with reduced test-cases
Re: PR 2606.
2015-11-16 13:15:36 +01:00
Jonas Jenwald
4b360512af Replace the unavailable linked test-case for PR 197 with a reduced test-case
Re: PR 197.

*Note:* Since this is a `load` test, `makeref` won't be necessary.
2015-11-15 20:07:54 +01:00
Jonas Jenwald
dca681e82b Replace the unavailable linked test-case for issue 1655 with a reduced test-case
Re: issue 1655 and PR 1978.
2015-11-15 15:32:11 +01:00
Tim van der Meij
f096e4ab91 Merge pull request #6637 from Snuffleupagus/issue-3207-reduced-test
Replace the unavailable linked test-case for issue 3207 with a reduced test-case
2015-11-15 14:32:31 +01:00
Jonas Jenwald
458aff66f4 Replace the unavailable linked test-case for issue 3207 with a reduced test-case
Re: issue 3207 and PR 3268.
2015-11-15 13:33:36 +01:00
Manas
a2ba1b8189 Uses editorconfig to maintain consistent coding styles
Removes the following as they unnecessary
/* -*- Mode: Java; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim: set shiftwidth=2 tabstop=2 autoindent cindent expandtab: */
2015-11-14 07:32:18 +05:30
Tim van der Meij
436b596a13 Merge pull request #6633 from Snuffleupagus/issue-3263-reduced-test
Replace the unavailable linked test-case for issue 3263 with a reduced test-case
2015-11-13 20:57:30 +01:00
Yury Delendik
875588d0cd Merge pull request #6630 from tonyjin/fix-minor-capitalization
Fix minor capitalization issue in viewer
2015-11-13 12:10:31 -06:00
Jonas Jenwald
5bd76c46ac Replace the unavailable linked test-case for issue 3263 with a reduced test-case
Re: issue 3263 and PR 3265.
2015-11-13 16:47:02 +01:00
Yury Delendik
9e335a61fd Merge pull request #6628 from Snuffleupagus/issue-6621
Ignore the /Mask entry in images unless its /ImageMask entry is explicitly set to `true` (issue 6621)
2015-11-12 16:54:00 -06:00
Jonas Jenwald
50a70429ec Ignore the /Mask entry in images unless its /ImageMask entry is explicitly set to true (issue 6621)
Fixes 6621.
2015-11-12 22:49:26 +01:00
Tony Jin
570f144fc3 Fix minor capitalization issue in viewer 2015-11-12 13:33:34 -08:00
Yury Delendik
9455095ee9 Merge pull request #6629 from Snuffleupagus/downgrade-jshint-to-fix-travis
Downgrade the JSHint version in order to fix linting failures on Travis
2015-11-12 15:24:30 -06:00