Samuel Chantaraud
7a4543e348
Prevent the annotationLayer to be recreated when the page is redrawn
...
This allows interactive annotations to keep their states after a resize
2014-04-16 08:13:54 -04:00
Rob Wu
2e97c0d085
Remove some unused variables from src/
...
Only obviously useless, local variables have been removed.
2014-04-15 17:10:23 +02:00
Yury Delendik
21f5dc22f3
Merge pull request #4616 from yurydelendik/jsdoc
...
Creates make.js code to build jsdoc.
2014-04-14 14:44:30 -05:00
Yury Delendik
2ca2c387fc
Creates make.js code to build jsdoc.
2014-04-13 15:54:24 -05:00
Joshua T Kalis
5828b2c687
Refactor - remove redundant function and all references
...
The function `assertWllFormed` was doing nothing different than `assert` which is
available in the same namespace. Removing it will lighten the filesize - albeit
very slightly - and reduce complexity.
2014-04-13 16:18:07 -04:00
Tim van der Meij
10f80bda23
Fixes lint warning W004 in src/shared
2014-04-11 00:02:32 +02:00
Tim van der Meij
a71a87a821
Fixes lint warning W018: confusing use of exclamation mark
2014-04-11 00:02:31 +02:00
Yury Delendik
791c9a7b13
Relaxes murmurhash array requirement.
2014-04-10 07:55:08 -05:00
Brendan Dahl
608c6cea5a
Merge pull request #4374 from yurydelendik/dictgetall
...
Doesn't traverse cyclic references in Dict.getAll; reduces empty-Dict GC
2014-04-08 10:43:42 -07:00
Yury Delendik
34f0f0962f
Merge pull request #4539 from Snuffleupagus/issue-4537
...
Workaround for missing 'Rect' entry in annotation dictionaries (issue 4537)
2014-04-02 08:05:52 -05:00
Jonas Jenwald
772df5e0cb
Workaround for missing 'Rect' entry in annotation dictionaries (issue 4537)
2014-03-31 12:07:54 +02:00
fkaelberer
c978c026fa
clean up string conversion functions
2014-03-27 13:01:43 +01:00
Yury Delendik
1d0286f6a1
Update util.js
...
Fixes comments for preprocessor
2014-03-26 13:19:10 -05:00
Yury Delendik
31f081ae17
Doesn't traverse cyclic references in Dict.getAll; reduces empty-Dict garbage
2014-03-26 09:07:38 -05:00
p01
4e6ebf2de0
Optimized putBinaryImageData for GRAYSCALE_1BPP
...
The following changes make putBinaryImageData 2.2x faster.
* Use a Uint32Array to draw whole pixels instead component by component
* Unroll the inner most loop
* Added lazy PDFJS.hasCanvasTypedArrays, PDFJS.isLittleEndian and compatibility
Uint32ArrayView for browsers using the old CanvasPixelArray
2014-03-26 14:05:59 +01:00
Christian Krebs
fc9edfcf76
Introduce paintSolidColorImageMask command to handle 1x1 solid image masks
...
See https://github.com/mozilla/pdf.js/issues/4436 for details
2014-03-19 13:27:59 +01:00
Yury Delendik
257898b359
Caching inlined mask images
2014-03-13 11:01:34 -05:00
Yury Delendik
f48f57e30a
Caches last parsed resource image, recornizes image repeats
2014-03-13 11:00:10 -05:00
Tim van der Meij
99b0231343
Fixes typo in function.js
2014-03-08 22:40:19 +01:00
Jonas Jenwald
4840c2ccdc
Add braces to single line statements in src/shared/annotation.js
2014-03-08 20:50:38 +01:00
Jonas Jenwald
15a63e48bd
Add braces to single line statements in src/shared/colorspace.js
2014-03-08 20:50:37 +01:00
Jonas Jenwald
00f6d07a21
Add braces to single line statements in src/shared/fonts_util.js
2014-03-08 20:50:37 +01:00
Jonas Jenwald
e8a68f12df
Add braces to single line statements in src/shared/function.js
2014-03-08 20:50:36 +01:00
Jonas Jenwald
635466fcd2
Add braces to single line statements in src/shared/util.js
2014-03-08 20:50:36 +01:00
Samuel Chantaraud
076b3433b4
Improved annotations' display/behavior.
...
Added an "InteractiveAnnotation" class to homogenize the annotations' structure (highlighting) and user interactions (for now, used for text and link annotations).
Text annotations:
The appearance (AP) has priority over the icon (Name).
The popup extends horizontally (up to a limit) as well as vertically.
Reduced the title's font size.
The annotation's color (C) is used to color the popup's background.
On top of the mouseover show/hide behavior, a click on the icon will lock the annotation open (for mobile purposes). It can be closed with another click on either the icon or the popup.
An annotation printing is conditioned by its "print" bit
Unsupported annotations are not displayed at all.
2014-03-07 10:48:42 -04:00
Yury Delendik
ff5ccdeb07
Merge pull request #4383 from nnethercote/more-rgb24
...
Use RGB_24BPP form for all images lacking alpha data.
2014-03-05 07:03:16 -06:00
Nicholas Nethercote
a2fe30ff38
Use RGB_24BPP form for all images lacking alpha data.
2014-03-03 20:58:35 -08:00
Yury Delendik
10af056f8f
Reset annotation stream; reset page annotation promise
2014-03-03 16:46:05 -06:00
Yury Delendik
ba95e0b07b
Merge pull request #4353 from nnethercote/more-Array-joins
...
Use Array.join() to build up strings in more places.
2014-03-02 23:26:22 -06:00
Nicholas Nethercote
ab7568c0ff
Use Array.join() to build up strings in more places.
2014-03-02 17:54:16 -08:00
Yury Delendik
9a918572dd
Merge pull request #4336 from nnethercote/rgb24
...
Special-case 24-bit RGB image-handling
2014-03-02 19:53:42 -06:00
Mitar
2c82e720b8
Updated to current latest stable version of jshint.
2014-03-01 13:31:25 -08:00
Luís Nabais
220a8e4f0e
Fix the combineUrl function
...
* Allow a url to omit the protocol and use the same protocol as the
* current page
2014-02-28 17:25:46 +00:00
Mathieu 'p01' Henri
e786649d2a
Skip the Math.sqrt for clamped values in convertToRgb
...
No need to compute the square root of clamped values.
Only the values in the range ]0,1[ need to be processed.
2014-02-27 17:44:40 +01:00
Nicholas Nethercote
c4fab2f234
Share ColorSpace.getRgb() between all sub-classes.
2014-02-26 05:51:29 -08:00
Nicholas Nethercote
42cbb5b440
Introduce ImageKind constants.
2014-02-25 15:18:04 -08:00
Jonas Jenwald
054f1e7e57
Handle undefined url in LinkAnnotation
2014-02-15 13:49:24 +01:00
Yury Delendik
e9327050c3
Basic function.js split
2014-01-27 20:29:47 -06:00
Yury Delendik
bf432a37bb
Refactors shared/pattern.js into core/ and display/
2014-01-25 12:18:22 -06:00
Yury Delendik
5a6862decc
Merge pull request #4164 from Snuffleupagus/bug-957034-followup
...
Only check for line dash pattern when annotation has a visible border (bug 957034 followup)
2014-01-22 08:27:47 -08:00
Rob Wu
b35ced8c9e
RFC 3986-compliant isValidUrl (protocol parsing)
...
To avoid misinterpreting URLs like "/File:wikipedia.png" as a
non-relative URLs.
2014-01-22 15:10:06 +01:00
Rob Wu
3c0b8073be
Try to recover from bad URI value
...
See https://github.com/mozilla/pdf.js/issues/4159
BAD (http://cms.di.unipi.it/files/bbec7791fac20e98127c77531e4031912392156c/testo.pdf )
<< /S /URI /URI /v#2findex.php#2fFile:Logo.png >>
GOOD (http://www.ioi2012.org/wp-content/uploads/2011/12/practice.pdf ):
<< /S /URI /URI (http://127.0.0.1/v/index.php/File:Logo.png >>
The URL should be wrapped in parentheses, but sometimes it isn't.
Consequently, the value is interpreted as a Name (because of the leading "/"),
and the resulting object is `{name: "v/index.php/File:Logo.png" }`. Obviously,
this is not a string, so `url.indexOf` throws an error here.
2014-01-22 15:09:29 +01:00
Jonas Jenwald
46ba8d10b0
Only check for line dash pattern when annotation has a visible border (bug 957034 followup)
2014-01-22 14:04:55 +01:00
Nicholas Nethercote
0685214a77
Don't create the RGB buffer for images that don't need resizing.
2014-01-19 14:21:36 -08:00
Nicholas Nethercote
c044652320
Remove unneeded srcOffset arguments from createRgbBuffer.
2014-01-16 20:15:37 -08:00
Brendan Dahl
c57fdcceed
Merge pull request #4125 from yurydelendik/issue4111
...
Fixes and refactors log functionality
2014-01-16 10:54:09 -08:00
Yury Delendik
754e000907
Fixes and refactors log functionality
2014-01-15 15:28:31 -06:00
Yury Delendik
a8c11ad1e5
Introduces disableObjectCreateURL
2014-01-10 16:30:41 -06:00
Jonas Jenwald
7c616502c2
Fix annotation border issue (bug 957034)
2014-01-09 13:44:21 +01:00
Yury Delendik
4d01ff4079
Merge pull request #4062 from kkujala/calgray
...
calgray: fix getRgbBuffer problem
2014-01-07 10:54:09 -08:00