Skip to content

Releases: mozilla/pdf.js

v2.2.228

10 Jul 20:15
d7afb74
Compare
Choose a tag to compare

#10557 Bump versions in pdfjs.config
#10556 [api-minor] Expose the existence of a Collection dictionary via the getMetadata API method (issue 10555)
#10554 Simplify the updatetextlayermatches event handling in TextLayerBuilder
#10548 Generate the default_preferences.json file from AppOptions
#10558 Re-factor the PDFDataRangeTransport unit-tests and enable them in Node.js/Travis
#10560 Update translations and packages
#10579 Re-factor the PDFSidebar constructor to simplify its call-site (PR 10123 follow-up)
#10578 Try to temporarily hack around the __non_webpack_require__ bug, and update Webpack to the latest stable version (issue 10177)
#10577 Move worker-thread only functions from src/shared/util.js and into a new src/core/core_utils.js file
#10582 Use Promise.prototype.finally in the PDFRenderingQueue.renderView method
#10589 Run the custom_spec unit-tests in Node.js/Travis (PR 10537 follow-up)
#10585 Load built-in CMap files using the Fetch API when possible
#10573 Avoid truncating/breaking some Type3 glyphs in compileType3Glyph (bug 1245391, issue 10568)
#10599 Update Webpack to the latest stable version (4.29.6)
#10597 Ensure that the temporary canvas created in CanvasGraphics.isFontSubpixelAAEnabled will be cleared
#10595 Zero the width/height of the temporary canvas used during JpegDecode (issue 10594)
#10591 Add unique glyph names for CFF fonts.
#10601 Zero the width/height of the temporary canvas used during TextLayer rendering
#10604 Put the string name of the glyph in the charset array.
#10606 Update translations and packages
#10590 Fix missing moveTos in SVG paths
#10608 Reduce usage of Date.now() in src/core/worker.js
#10610 Add type validation to the default_preferences generation (PR 10548 follow-up)
#10605 Convert let to const if possible in, and improve unit test coverage for, src/display/display_utils.js
#10615 Handle corrupt ASCII85Decode inline images with whitespace "inside" of the EOD marker (issue 10614)
#10621 Don't scale SVG stroke width by text matrix
#10634 Move NativeImageDecoder into a separate file, and convert it to a class
#10633 Convert MurmurHash3_64 to an ES6 class
#10628 Try to improve text-selection for Type3 fonts that utilize a non-default /FontMatrix (bug 1513120)
#10636 Small clean-up of the PDFDocumentProxy.destroy method and related code
#10647 Actually transfer eligible ImageMask data, rather than always copying it
#10644 Ensure that blob: URLs will be revoked when pages are cleaned-up/destroyed (JPEG memory usage)
#10646 Implement linear-gradient, radial-gradient and dummy-pattern in SVGGraphics.
#10635 Convert src/core/parser.js to ES6 syntax and write more unit tests for the lexer and the parser
#10657 Update test case description
#10652 Prepare the MOZCENTRAL viewer for receiving zoom events from the browser UI (bug 786674, bug 1177385)
#10668 Remove the Firefox-specific 'read with streaming' unit-test
#10681 fix: electron enviroment detection
#10685 Take the FirstChar/LastChar properties into account when computing the hash in PartialEvaluator.preEvaluateFont (issue 10665)
#10683 Use CMap in Type0 fonts when CFF is not a CID font
#10692 Add Mozilla Code of Conduct
#10698 Update translations/packages and include the code of conduct for pdfjs-dist too
#10706 Add missing hasChildNodes polyfill to domstubs.js (PR 10022 follow-up)
#10675 [Firefox regression] Fix disableRange=true bug in PDFDataTransportStream
#10713 Remove src/core/annotation.js from the gulp jsdoc build target
#10678 Remove moz-chunked-arraybuffer support, and related code, from src/display/network.js
#10709 [api-minor] Add basic support for PageLayout in the API and the viewer
#10714 [Firefox] Ensure that loading progress is reported, and the loadingBar updated, when disableRange=true is set
#10674 Convert src/display/svg.js to ES6 syntax and implement setRenderingIntent and setFlatness for the SVG backend
#10715 Add test for fetch_stream
#10725 Attempt to clarify the l10n section of CONTRIBUTING.md
#10723 [api-minor] Implement caret annotations
#10728 Annotations - _preparePopup method replaced with MarkupAnnotation
#10696 Update ChunkedStream.makeSubStream to actually check if (some) data exists when the length parameter is undefined
#10694 Avoid dispatching range requests to fetch PDF data that's already loaded with streaming (PR 10675 follow-up)
#10733 Update translations and packages
#10735 [api-minor] Implement free text annotations
#10742 [Firefox] Avoid displaying the indeterminate loadingBar when disableStream=true is set (PR 10714 follow-up)
#10746 Add links to PDF.js homepage and API reference in README.md
#10727 Support (rare) Type3 fonts which contains image resources (issue 10717)
#10754 Add a getDocId method to the idFactory, in Page instances, to avoid passing around PDFManager instances unnecessarily (PR 7941 follow-up)
#10738 [api-minor] Add support for ViewerPreferences in the API (issue 10736)
#10765 Add passive: false to the wheel event listener, to work-around broken default behaviour in Chrome 73 and above (issue 10761)
#10784 Ensure that the OperatorList constructor actually initializes a NullOptimizer when intended (PR 9089 follow-up)
#10756 Attempt to handle corrupt PDF documents that contains path operators inside of text object (issue 10542)
#10789 Change PartialEvaluator.handleColorN to throw when no valid pattern is found
#10771 [api-minor] Implement creation/modification date for annotations
#10795 Update the canvas npm package to fix Travis CI builds (issue 10790)
#10805 Enable the consistent-return ESLint rule
#10794 Fix glyph at index zero in CIDFontType2 that has a CIDToGIDMap stream
#10826 Remove unused ref property from the parameters object used when creating annotations in AnnotationFactory._create
#10827 Convert the (remaining) network streams to ES6 classes
#10854 make print resolution configurable via AppOptions
#10833 [api-minor] Implement contents and creation date for the correct annotation types
#10859 Update translations and packages
#10862 Add caching to reduce the number of Ref objects
#10863 Ensure that the Cmd/Name/Ref caches are cleared when running other cleanup code
#10869 Restore referrer preserving functionality in Chrome 72+
#10867 Don't clip if path is undefined in SVG back-end
#10872 Re-use, rather than re-creating, some Arrays when resetting them in src/display/api.js
#10873 Ensure that the Cmd/Name/Ref caches are cleared when terminating the worker (PR 10863 follow-up)
#10877 Ignore Annotations with too large border widths, to prevent the annotationLayer from rendering it over the surrounding document (bug 1552113)
#10879 [api-minor] Attempt to reduce memory usage during printing, by always running cleanup once rendering has finished
#10890 Add support for outline items, in the default viewer, which default to collapsed when the outline is built
#10897 Remove a superfluous linkService.isPageVisible check from PDFFindController (PR 10217 follow-up)
#10898 Allow experimenting with the printResolution AppOption when printing with the built-in Firefox version
#10905 Pin the version of eslint-plugin-mozilla to prevent failures on Travis (issue 10901)
#10903 Move PDFWorkerStream and related code to its own file
#10926 Change the signature of the Parser constructor to take a parameter object
#10925 Enable the eslint-plugin-no-unsanitized ESLint plugin to disallow unsafe usage of e.g. innerHTML
#10902 Implement tiling patterns for the SVG back-end
#10936 Update translations and packages
#10938 Reduce the number of isCmd calls slightly in the XRef class
#10937 Restore the header size limit of 80 KB
#10947 Make the find helper function, in src/core/document.js, more efficient by using peekBytes rather reading the stream one byte at a time
#10949 Delay initialization of searching, in the viewer, until the first page has rendered

v2.1.266

16 Feb 18:03
81f5835
Compare
Choose a tag to compare

Changes since v2.0.943:

#10187 Bump versions in pdfjs.config
#10188 Hide the beta version button on the website if there is only a stable version
#10162 Normalize BBox of form XObjects in SVG back-end
#10185 Reduce the number of redundant text normalization operations in PDFFindController
#10182 Small clean-up of the search related methods in TextLayerBuilder
#10184 Ensure that matches are not scrolled into after the findbar has been closed (PR 10100 follow-up)
#10196 [Regression] Ensure that "Highlight All" is propagated to all pages for 'findagain' events where the findbar was previously closed (PR 10100 follow-up)
#10190 Add a helper method for _getVisiblePages, in BaseViewer, for the case where only a single page is displayed in the viewer
#10201 Reduce the number of redundant updatetextlayermatches events dispatched when calculating matches in PDFFindController
#10203 Change canvasInRendering to a WeakSet instead of a WeakMap
#10096 Remove the attachDOMEventsToEventBus functionality, since EventBus instances are able to re-dispatch events to the DOM (PR 10019, bug 1492849 follow-up)
#10202 Attempt to clean-up/restore pending rendering operations on RenderTask.cancel (issue 10200)
#10217 For repeated 'findagain' operations, attempt to reset the search position if the user has e.g. scrolled in the document (issue 4141)
#10219 Convert src/core/ps_parser.js to use ES6 classes
#10228 Don't detect nw.js as node.js
#10233 [api-minor] Convert PDFObjects, in src/display/api.js, to an ES6 class
#10238 Move the interface definitions out of src/core/worker.js and into their own file
#10245 Update BaseViewer.scrollPageIntoView to always validate the pageNumber parameter
#10223 When the search query changes, regardless of the search command, always re-calculate matches (bug 1030622)
#10220 Only scroll search results into view as a result of an actual find operation, and not when the user scrolls/zooms/rotates the document (bug 1237076, issue 6746)
#10231 Stop scrolling the document when "Highlight All" is toggled in the findbar (issue 5561)
#10244 Fix webpack example
#10255 Avoid unnecessary PDFFindController.scrollMatchIntoView calls in TextLayerBuilder._renderMatches when highlightAll is set (PR 10201 follow-up)
#10256 Attempt to tweak the error messages, in BaseViewer, for invalid pageNumbers/pageLabels (bug 1505824)
#10264 Update translations and packages
#10197 Use span instead of div in the text layer
#10246 Convert the remaining code in src/display/api.js to use ES6 classes
#10274 Fallback to an exhaustive search, in corrupt PDF files, for NameTrees/NumberTrees that are not correctly ordered (issue 10272)
#10294 Add ESLint plugin import to be warned against invalid paths
#10292 Replace uglify-es with Terser
#10293 Upgrade to Babel 7
#10275 Fix NameOrNumberTree.get to actually perform a binary search to find the requested key
#10299 Update packages and translations
#10300 Include forgotten changes after Wintersmith update
#10318 In GENERIC builds, dispatch a "webviewerloaded" event (from the webViewerLoad function) before initializing the viewer
#10322 Remove unuseful variable
#10323 Test the code as-is, in Node.js/Travis, rather than its Babel translated version
#10340 Tweak the PDFHistory._tryPushCurrentPosition method to work better with the different Scroll/Spread viewer modes
#10330 Handle line width of zero in SVG
#10304 Add protection against directory traversal attacks
#10295 Update eslint-plugin-mozilla to ^1.0.1
#10337 Turn on ESLint in examples
#10351 Attempt to ignore mouse wheel zooming during tab switches (bug 1503412)
#10350 Ignore the fieldValue for Signature annotations, since they're currently unsupported (issue 10374)
#10354 Disable source-map generation when running tests
#10356 Use high DPI icons on semi-high DPI screens.
#10358 Add keyboard shortcut to toggle sidebar (F4, same as Adobe Reader).
#10266 Upgrade to Gulp 4
#10363 Fix small visual quirk in thumbnail viewer
#10346 [api-minor] Add support, in getMetadata, for custom information dictionary entries (issue 5970, issue 10344)
#10369 [api-minor] Change the getViewport method, on PDFPageProxy, to take a parameter object rather than a bunch of (randomly) ordered parameters
#10375 Update translations and packages
#10334 [api-minor] Add support for OpenAction destinations (issue 10332)
#10378 Update remaining examples, and docs, to utilize current API functionality (issue 10377)
#10376 Convert src/core/chunked_stream.js to ES6 syntax
#10392 Check that the first page can be successfully loaded, to try and ascertain the validity of the XRef table (issue 7496, issue 10326)
#10394 Optimize the Ref class in src/core/primitives.js
#10393 Convert src/core/document.js to ES6 syntax
#10396 Optimizations to avoid intermediate string creation
#10397 Ensure that AnnotationBorderStyle.setWidth is able to handle the input being a Name, to correctly deal with corrupt PDF documents (issue 10385)
#10398 Prevent errors in various methods in SimpleDOMNode when the childNodes property is not defined (issue 10395)
#10277 Repair CFF fonts if stem hints are in wrong order
#10404 Remove the for ... of loop from the PDFDocument.fingerprint getter (issue 10401)
#10399 migrate to canvas 2.x api
#10411 Adjust how AnnotationBorderStyle.setWidth handles the input being a Name (issue 10385)
#10408 Prevent errors, because of incorrect scope, in the XMLParserBase._resolveEntities method (issue 10407)
#10412 Prevent errors, in SimpleXMLParser.onEndElement, when the stack has already been completely parsed (issue 10410)
#10417 Fix reading number of HTMX metrics.
#10420 Update translations/packages and improve documentation
#10421 Switch to HTTPS for the license link on the website
#10422 Convert more files in src/core to ES6 syntax
#10424 Accept non-matching document fingerprints, in PDFHistory, when the viewer is reloaded (issue 6847)
#10423 Add support for updating the document hash, off by default, when the browser history is updated (issue 5753)
#10441 Handle more cases of corrupt PDF files with missing 'endobj' operators, where the "obj" string is immediately followed by the dictionary (PR 9288 follow-up)
#10436 Avoid truncating inline images, where the data and the "EI" marker is glued together (issue 10388)
#10425 Write more unit tests for the find controller
#10444 Remove left-over console log from the find controller unit tests
#10447 Handle malformed URIs as bad requests in the development webserver
#10443 Prevent TypeError: views[index] is undefined being throw in getVisibleElements when the viewer, or all pages, are hidden
#10462 Tweak the DOMTokenList.toggle polyfill (issue 10460)
#10461 Avoid setting incorrect document URLs, in IE 11, when the browser history is updated (PR 10423 follow-up)
#10457 When parsing Metadata, attempt to remove "junk" before the first tag (PR 10398 follow-up)
#10466 Move/refactor the code in the BaseViewer.update method to reduce duplication in the extending classes
#10467 Convert some usage of indexOf to startsWith/includes where applicable
#10471 Implement a unit test for metadata parsing to ensure that it's not vulnerable to the billion laughs attack
#10470 Try to, completely, avoid loading the ReadableStream polyfill in MOZCENTRAL builds
#10473 Add an Array.from polyfill, using core-js, and remove some compatibility hacks from the src/display/content_disposition.js file
#10474 Update translations and packages
#10480 [Regression] Fix the FontInspector in the PDFBug debugging tools
#10483 Update the mobile-viewer example to use the new PDFHistory.initialize format (PR 10423 follow-up)
#10484 Stop bundling the ReadableStream polyfill in MOZCENTRAL builds (PR 10470 follow-up)
#10492 Ensure that XRef.indexObjects can handle object numbers with zero-padding (issue 10491)
#10482 Implement Decode entry in Indexed images
#10494 Reduce unnecessary duplication of the isDefaultDecode methods on ColorSpace instances
#10489 Move more code/methods into BaseViewer, and simplify the PDFSinglePageViewer._scrollIntoView method slightly
#10501 In getVisibleElements, check firstVisibleElementInd rather than numViews before backtracking (PR 10443 follow-up)
#10499 Attempt to clean-up/restore pending rendering operations when errors occurs while a RenderTask runs (PR 10202 follow-up)
#10504 Enable the no-useless-catch ESLint rule
#10508 Do the final text scaling correctly in flushTextContentItem (issue 8276)
#10515 Add a settled property, tracking the fulfilled/rejected stated of the Promise, to createPromiseCapability
#10517 [api-minor] Remove the document.currentScript polyfill
#10502 Modify a number of the viewer preferences, whose current default value is 0, such that they behave as expected with the view history
#10525 Convert more code to use classList.toggle with the force parameter
#10527 Add a polyfill for classList.{add, remove} with more than one parameter
#10532 Bump base version and version prefix in pdfjs.config
#10533 Bump the version number in pdfjs.config
#10534 Try to hack-around the broken pdfjs-dist links, such that they will point to the main library releases (issue 10391)
#10530 Fix copying on supplementary plane characters
#10545 Undo the pdfjs.config version bumps
#10537 Improve unit test coverage
#10540 [Chrome extension] Add missing "type" entry for the viewOnLoad preference in the preferences_schema.json file (PR 10502 follow-up)
#10539 [api-minor] Fallback to the built-in font renderer when font loading fails

v2.0.943

27 Oct 14:46
dc98bf7
Compare
Choose a tag to compare

Changes since v1.10.100:

#9730 Ignore the rest of the image when encountering an EOI (End of Image) marker while parsing Scan data (issue 9679)
#9740 Use Dict.getArray, instead of Dict.get, when getting the 'Size' in constructSampled in src/core/function.js
#9771 Remove the gulp extension build target
#9773 Fix multibyte decoding in content_disposition.js
#9769 Reduce the amount of errors logged, primarily in Node.js/Travis, when running the unit-tests
#9774 Use fs.unlinkSync instead of fs.unlink when removing files in the font tests
#9741 Build improvements
#9779 Remove dead code in the gh-pages-prepare task in the Gulpfile
#9777 Various PageViewport and MessageHandler cleanup
#9781 Miscellaneous API clean-up
#9792 Import translations
#9660 Support running the tests headlessly.
#9794 Implement drag-and-drop support in the viewer for local files
#9793 Remove Util.appendToArray and Util.prependToArray
#9689 Fixed critical unhandled promise that prevented error catching using API
#9796 Disable (drag-and-drop) file opening if Presentation Mode is active (PR 9794 follow-up)
#9801 Replace deprecated new Buffer(string, 'base64') constructor with Buffer.from(string, 'base64')
#9815 Remove the disableFullscreen hack for embedded IE 11 (issue 9585)
#9816 Fix regression causing the pages to be offset horizontally in Presentation Mode (PR 8993 follow-up)
#9595 Disable ftp support in Chrome 59+, add file chooser at file
#9819 Fix regression affecting the horizontal viewerContainer offset for small window widths (PR 9816 follow-up)
#9809 Allow FontFaceObject.getPathGenerator to ignore non-embedded fonts during rendering
#9802 Update ColorSpace and PDFImage to use Uint8ClampedArrays and remove manual clamping/rounding
#9821 Set the correct document title when opening a new file in the GENERIC default viewer
#9795 Replace Util.extendObj by Object.assign
#9827 Fix various corrupt PDF files (issue 9252, issue 9418)
#9830 Removed safari compatibility check (issue #9824)
#9835 Clean-up the PDFDocumentProxy.loadingParams method in the API, and the locale viewer option
#9832 Fix a number of regressions/inefficiencies introduced by adding Scroll/Spread modes to the viewer (PR 9208 follow-up)
#9839 Add unit-tests for PDFPageProxy.stats (PR 9245 follow-up)
#9729 Add a gulp image_decoders command to package the image decoders (i.e. jpg.js, jpx.js, jbig2.js) separately, and publish them in pdfjs-dist
#9841 Various (small) cleanup related to setting the initial document position on load
#9849 Replace the cloneObj helper function, in the viewer, with native Object.assign (PR 9795 follow-up)
#9838 Error, rather than warn, once a number of invalid path operators are encountered in EvaluatorPreprocessor.read (bug 1443140)
#9852 Proper Error Handling for Build Numbers of Downloaded Sources (Non-Git repositories).
#9853 Fix re-rendering, using the same canvas, when rendering was previously cancelled (PR 8519 follow-up)
#9859 Update translations and packages
#9860 Update the localization README to indicate that the translations are imported from the Nightly channel
#9858 Additional Scroll/Spread mode clean-up (PR 9832 follow-up)
#9861 Refactor PDFFindController to use the 'pagesinit' event, dispatched on the eventBus, to resolve the _firstPagePromise
#9866 Prevent the development viewer, started with gulp server, from breaking completely in Private Browsing mode
#9879 Correct the instructions in the README file for examples/mobile-viewer
#9880 Remove the jp-JP-mac locale
#9877 Hide the Scroll/Spread mode buttons if the viewer is a PDFSinglePageViewer instance (PR 9858 follow-up)
#9868 Stop exposing the URL polyfill in the global scope
#9837 Replace NotImplementedException with unreachable
#9881 Replace the remaining occurences of instanceof Array with Array.isArray()
#9887 Convert more code in the /src folder to use ES6 classes, such that Util.inherit can be removed
#9886 Prevent errors in sanitizeTTProgram, during parsing of CALL functions, when encountering invalid functions stack deltas (bug 1473809)
#9898 Change waitOnEventOrTimeout, in web/ui_utils.js, to return a regular Promise and remove the createPromiseCapability import
#9900 Prevent Metadata/XML parsing from breaking PDFDocumentProxy.getMetadata when no XML root document is found (issue 8884)
#9904 Modified Examples to work without systemjs
#9913 Provide custom messages for the no-restricted-globals ESLint rule, and refactor the .eslintrc files (PR 9868 follow-up)
#9917 Add a BasePreferences.getAll method and use it to fetch all Preferences at once in PDFViewerApplication._readPreferences; ensure that the externalLinkTarget option is correctly set when the viewer is embedded
#9924 fix(browser): zlib is not available in browser
#9933 README.md: suggest usage of https instead of git protocol
#9935 [Regression] Convert Catalog.builtInCMapCache into a Map, instead of an Object, to ensure that it's correctly reset (PR 8064 follow-up)
#9936 Validate the Preferences when fetching them from storage
#9925 Attempt to estimate the minimum required buffer length when initializing StreamsSequenceStream instances
#9931 Refactor getPage (in the worker), and attempt to use the Linearization dictionary to lookup the first Page
#9920 [api-minor] Add an IsLinearized property to the PDFDocument.documentInfo getter, to allow accessing the linearization status through the API (via PDFDocumentProxy.getMetadata)
#9897 Prefer the Width/Height of the image data, rather than the image dictionary, for JPEG 2000 images (issue 9650)
#9938 Ensure that Type0, i.e. composite, OpenType fonts with CFF tables are not treated as CFF fonts if their glyph mapping is non-default (issue 9915)
#9946 Removed Extraneous Matrix Check in CalRGB Conversion
#9948 Add (basic) unit-tests for the non-global URL constructor (PR 9868 follow-up)
#9954 Stop warning for non-Name /Filter entries in the PDFImage constructor (PR 9897 follow-up)
#9874 [api-minor] Include export value for checkboxes
#9956 Allow loaded progress of 0 in unit tests.
#9960 Fail when MD5 of test files fails on bots.
#9959 Utility script to add a reference test.
#9961 Parse the font file to determine the correct type/subtype, rather than relying on the (often incorrect) data in the font dictionary
#9958 Always fallback to system font on font failure.
#9965 Update translations and packages
#9964 Attempt to throw MissingPDFException when applicable in node_stream.js (issue 9791)
#9968 Tweak the MMType1 font detection in getFontFileType to improve font telemetry (PR 9961 follow-up)
#9822 [api-minor] Refactor the annotation code to be asynchronous
#9975 Re-factor destinations/getDestination to reduce unnecessary duplication, and reject non-string inputs
#9980 Ensure that Uint8ClampedArray is used for image data transfered by getTransfers (PR 9802 follow-up)
#9988 Remove the unused PDFDocument.mainXRefEntriesOffset method
#9989 Update translations and packages
#9987 [api-minor] Remove the obsolete createBlob helper function
#9991 Remove the deprecated ways, in BaseViewer, of setting the Scroll/Spread modes (PR 9858 follow-up)
#9977 Add support for async/await using Babel
#10000 Remove the unused defaultColor property on ColorSpace instances
#10008 Update translations/packages and fix duplicated function name in the Esprima fixtures
#9990 Convert the Catalog class, in src/core/obj.js, to ES6 syntax
#10007 Convert the code in src/core/colorspace.js to use ES6 classes
#10015 Adding chunkname to async loaded code
#10020 Ensure that the built PdfJsDefaultPreferences.jsm file won't be affected/touched during tree-wide ESLint rule changes in mozilla-central (PR 9571 follow-up)
#10022 Implement text rendering modes in SVG backend
#10010 Attempt to find truncated endstream commands, in the fallback code-path, in Parser.makeStream (issue 10004)
#10019 Add general support for re-dispatching events, on EventBus instances, to the DOM
#9986 Attempt to combine separate beginText/endText sequences in getTextContent (issue 9984)
#10032 Replace broken link for pr8808.pdf.link
#10031 Add a new parameter to JpegImage.getData to indicate the source of the image data (issue 9513)
#10033 [api-minor] Implement a permissions API
#10041 Revert "Attempt to combine separate beginText/endText sequences in getTextContent (issue 9984)"
#10049 Fix font-string variable name typo
#9340 Map all glyphs to the private use area and duplicate the first glyph.
#9995 Refactor code in the web/ folder to use async/await
#10053 Simplify the "spaced-comment" ESLint rule
#10034 Remove getSinglePixelWidth workaround
#10054 Update translations/packages and use HTTPS for links in README.md
#10052 Display the index of the currently active search result in the matches counter of the findbar (issue 6993, bug 1062025)
#10055 Translate the new find match count strings to Dutch
#10028 Add initial support for "Whole words" searching in the viewer
#10056 [Regression] Ensure that PDFFindBar.updateResultsCount doesn't throw when the viewer is closed, by providing proper default values
#10060 Ensure that PDFFindController._requestMatchesCount won't return broken data when searching starts (PR 10052 follow-up)
#10061 Implement unit tests for the isSameOrigin and createValidAbsoluteUrl utility functions and use the const keyword for constants in src/shared/util.js
#10063 Slightly improve the isSourcePDF parameter handling in JpegImage (PR 10031 follow-up)
#10070 Attempt to support plural forms in the matches counter of the findbar (issue 10067)
#10066 Refactor the find controller
#10071 Enable forwarding, in FirefoxCom, of the matchesCount to the browser findbar (bug 1062025)
#10078 Improve plural support for t...

Read more

v1.10.100

06 Jun 00:09
Compare
Choose a tag to compare

#9659 Remove createFromIR from PDFFunctionFactory; forgive invalid Dict values.
#9573 New XML parser
#9759 Fix webpack exclude path on windows.

v1.10.88

27 Oct 15:36
Compare
Choose a tag to compare

Changes:

#8778 Use Uint8ClampedArray, when returning data, and remove manual clamping in src/core/jpg.js (issue 4901)
#8780 Version 1.9.426
#8783 Use Uint8ClampedArray when returning image data in src/core/jbig2.js and src/core/jpg.js
#8785 SVG: Don't render missing glyphs
#8788 Attempt to delay disabling of the attachment view until FileAttachment annotations of the initial page has been parsed
#8792 Fix caching of small inline images in Parser.makeInlineImage (issue 8790)
#8794 Remove the migration code for old localStorage data in ViewHistory
#8557 pdf2svg.js: provides ReadableSVGStream class to serialize a SVG as a stream
#8781 __non_webpack_require__ -> require in SystemJS
#8491 JBIG2 halftone regions and pattern dictionaries
#8807 Remove handling of fallback arguments from PDFViewer.scrollPageIntoView
#8812 Moves global scope out of shared/util.
#8813 Use Array.isArray in the LoopbackPort.
#8810 Cache PdfJs's enabled setting for delayed init
#8800 Try to recover if we reach the end of the stream when searching for the EI marker of an inline image (issue 8798)
#8712 Adds node.js logic for networking tasks for PDF.js
#8822 Disable node libs in pdfjs-dist package.json
#8824 Prevent an infinite loop in XRef.readXRef by keeping track of already parsed tables (bug 1393476)
#8819 Remove any mention of compatibility.js from the "Getting Started" docs (issue 8818)
#8817 Set this.isCancelled in close method of streamSink.
#8820 Remove the ability to pass a scale parameter in the (optional) args object parameter of PDFViewerApplication.open(file, args)
#8821 Replace the test-case for issue 8798 with a reduced one (PR 8800 follow-up)
#8826 Enable the for-direction ESLint rule
#8825 Account for broken outlines/annotations, where the destination dictionary contains an invalid /Dest entry
#8796 Implement text rise for the SVG back-end
#8829 Attempt to improve the EI detection heuristics, for inline images, in streams containing NUL bytes (issue 8823)
#8831 Update the gulp minified command to use uglify-es
#8835 Ensure that PDFViewerApplication.error outputs proper messages in FIREFOX/MOZCENTRAL builds
#8768 Adds fetch stream logic for networking part of PDF.js
#8845 Fixes autofetch and firefox nightly fetch streams
#8828 Improve the annotation code by converting to ES6 syntax and removing duplicate code
#8848 Correctly set the credentials of a fetch request, when the withCredentials parameter was passed to getDocument
#8855 Add test for withCredentials option
#8847 Correct the default value for isRenderable in the AnnotationElement constructor, to fix breaking errors when rendering unsupported annotations
#8857 Avoid some redundant type checks in XRef.fetchUncompressed
#8859 Revert PDFPageView.pdfPage reset.
#8862 Replace the isInt helper function with the native Number.isInteger function
#8864 Replace the isArray helper function with the native Array.isArray function
#8775 Re-write PDFHistory from scratch
#8874 Fix the helloworld example by setting the PDFNetworkStream class (PR 8712 follow-up)
#8866 Correctly validate the response status for non-HTTP fetch requests (PR 8768 follow-up)
#8877 Provide checked styles for button widget annotations
#8885 Address a couple of edge-cases in the new PDFHistory implementation (PR 8775 follow-up)
#8889 Replace value === (value | 0) checks with Number.isInteger(value)
#8868 Store the rotation in the ViewHistory/PDFHistory (issue 5927)
#8865 Hide unsupported LinkAnnotations (issue 3897)
#8691 Implement support for square and circle annotations
#8892 Replace var with let in web/genericcom and web/genericl10n
#8891 ES6-ify the code in web/firefoxcom.js
#8893 Combine the common styles and overrides for the annotation layer reference tests
#8808 Fix color of image masks inside uncolored patterns
#8904 Provide a stub for setAttribute in order to use the SVG back-end with Node.js
#8900 Use the SimpleLinkService when running "annotations" reference tests
#8910 Fix #8888: Change behaviour of fetch to make it compatible with XHR.
#8913 For /Filter entries containing Names, ignore the /DecodeParms entry if it contains an Array (issue 8895)
#8909 Check isEvalSupported, and test that eval is actually supported, before attempting to use the PostScriptCompiler (issue 5573)
#8917 Implement support for stamp annotations
#8919 Ignore 'change' events that didn't originate in the viewer (issue 8915)
#8921 support tiff predictor for 16bit
#8901 CCITTFaxStream problem when EndOfBlock is false
#8938 Use font's default width even when 0. (bug 1392647)
#8912 [api-minor] Replace DOMParser with SimpleXMLParser
#8928 Fix #8907: Decode URL to get correct path in node_stream.
#8949 Remove the instanceof AlternateCS check in ColorSpace.parse since it's dead code
#8932 JBIG2 symbol offsets
#8950 Implement support for polyline and polygon annotations
#8724 Implement a PDFSinglePageViewer class (issue 8188)
#8955 Overwrite maxSizeOfInstructions in maxp with computed value.
#8959 Ensure that the same exact version of PDF.js is used in both the API and the Worker
#8962 Check that this.baseUrl is defined before attempting to fetch any data in DOMCMapReaderFactory/NodeCMapReaderFactory
#8968 Split the existing PDFFunction in two classes, a private PDFFunction and a public PDFFunctionFactory, and utilize the latter in PDFDocument to allow various code to access the methods of PDFFunction
#8976 Simplify the disabling of Node polyfills, in gulpfile.js, since we're now using Webpack 3.x
#8971 Closes all promises/streams when handler is destroyed.
#8979 Transform Web Archive URLs to avoid downloading an HTML page instead of the PDF file
#8977 Update all packages to the most recent version
#8981 Update translations
#8983 Remove unused helper code
#8980 Add CDN links
#8990 Added component example for single page viewer
#8994 Fix a regression that (effectively) makes PDFHistory.forward a no-op
#9002 Revert "Closes all promises/streams when handler is destroyed."
#9001 Prevent the annotationLayer from, in some cases, becoming duplicated on the first page when the document loads
#8922 Allow getOperatorList/getTextContent to skip errors when parsing broken XObjects (issue 8702, issue 8704)
#9008 Mispelled isEvalSupported property at FontFaceObject() creation.
#9009 Only warn about unsupported JavaScript, in the viewer, when non-empty actions exist (issue 5767)
#9013 Fix a PDFHistory regression with document hashes of the nameddest=... form
#9027 Replace our WeakMap polyfill with the one from core-js
#9029 Enable the --report-unused-disable-directives ESLint command line option
#9031 Remove all warning/fallback code for obsolete method signatures in web/ files
#9040 Remove the enableHandToolOnLoad preference migration code in web/pdf_cursor_tools.js
JavaScript exists
#9044 Use charstring as plain text when lengthIV is -1.
#9032 Simplify the check, and remove the warning, for the nativeImageDecoderSupport API parameter
#9052 Attempt to clarify the meaning of "extension" in the ISSUE_TEMPLATE
#9054 Replace our Promise polyfill with the one from core-js
#9055 Replace Number polyfills with the ones from core-js
#9058 Replace a few occurences of var with let in already ES6 converted web/ files
#9057 Use let/const instead of var in the printing code
#9061 Adds ECCN response statement
#8986 Version 1.10
#9045 Sanitize name index in compile phase of CFF.
#9046 Extract the actual decoding in CCITTFaxStream into a new CCITTFaxDecoder "class", which the new CCITTFaxStream depends on
#9072 Use stringToBytes in more places

v1.9.426

14 Aug 23:40
Compare
Choose a tag to compare

Changes:

#8281 v1.8.188
#8131 ES6 modules: remove UMD header validation
#8240 [api-minor] Always allow e.g. rendering to continue even if there are errors, and add a stopAtErrors parameter to getDocument to opt-out of this behaviour (issue 6342, issue 3795, bug 1130815)
#8203 Convert the files in the /web folder to ES6 modules
#8286 Changing package.json version to 1.0.0
#8283 Moves Uint32ArrayView and hasCanvasTypedArrays into compatibility.js.
#8285 Change amd to cjs path in ES6 modules
#8287 Allow to convert (some of) ES6 code to ES5.
#8289 Firefox extension: remove unused preference cleanup from bootstrap.js
#8288 Moves 'web' target to the gulpfile.
#8291 Ensure that PDFThumbnailView.draw is able to handle RenderingCancelledException correctly (PR 8157 follow-up)
#8293 Convert the password prompt to ES6 syntax
#8295 Use createPromiseCapability in /web files and avoid unnecessary PDFPageView.setPdfPage calls
#8294 Convert the files in the /src/display folder to ES6 modules
#8296 Convert the document properties to ES6 syntax
#8297 Convert the find bar to ES6 syntax
#8299 Import getGlobalEventBus correctly from web/dom_events.js in various /web files, to un-break e.g. the viewer components (PR 8203 follow-up)
#8300 Refactor the DownloadManager initialization in GENERIC/CHROME builds again (PR 8203 follow-up)
#8311 [Firefox addon] Upstream changes from: Bug 1356569 - Remove optional trailing parameters (issue 8310)
#8312 Moves dist and minifiedpost tragets from make.js.
#8315 Remove the signchromium target from make.js
#8313 [Firefox addon] Upstream changes from: Bug 1346616 - Migrate callsites that are retrieving requested locale from pref, to use LocaleService::GetRequestedLocales
#8321 Change getPDFFileNameFromURL to ignore data: URLs for performance reasons (issue 8263)
#8322 [Firefox addon] Remove the window.FirefoxCom hack from web/viewer.js, since it was made redunant by the setExternalLocalizerServices refactoring (PR 7202 follow-up)
#8323 Change the importl10n script to use the Beta channel, since Aurora is being removed
#8302 Convert the attachments/outline view to ES6 syntax
#8306 Convert the sidebar to ES6 syntax
#8303 Convert the Preferences to an ES6 class
#8328 Makefile: remove unused mozcentralcheck target
#8339 Convert the ViewHistory to an ES6 class, and re-factor it to make it properly asynchronous
#8331 Enable running the ui_utils unit-tests on Travis
#8324 Convert the annotation layer builder, presentation mode and rendering queue to ES6 syntax
#8332 Enable the object-shorthand ESLint rule in src/shared and src/display
#8345 Bots: disable the default browser test and enable E10s
#8346 Restore the URL.createObjectURL check to the createObjectURL utility function (issue 8344)
#8348 Add the commit hash to the README.mozilla file (issue 8347)
#8309 Allow use versions for pdf.js script (i.e. - pdf.js?2412313)
#8352 Removes builder.build().
#8335 Subtract the X/Y offsets when decoding refinement regions of JBIG2 images (issue 7145, 7308, 7401, 7850, 8270)
#8351 Enable the object-shorthand ESLint rule in web
#8342 Enable the object-shorthand ESLint rule in src/core
#8298 Convert the files in the /test/unit folder to ES6 modules
#8354 [Firefox addon] Replace a bind(this) statement with an arrow function in PdfStreamConverter.jsm (issue 8343)
#8353 Enable the object-shorthand ESLint rule
#8355 Replace unnecessary bind(this) and var self = this statements with arrow functions in src/core/evaluator.js
#8349 Migrate make.js to gulpfile.js
#8357 Replace unnecessary bind(this) and var self = this statements with arrow functions in remaining src/core/ files
#8361 Export LoopbackPort
#8363 Adds initializeFromPort to the WorkerMessageHandler.
#8364 Adds babel caching for system.js.
#8359 Ignore line-breaks between operator and digit in Lexer.getNumber
#8369 Add no-default-browser-check to chrome runner.
#8370 Replace unnecessary bind(this) and var self = this statements with arrow functions in remaining src/ files
#8358 Change the signatures of the PartialEvaluator "constructor" and its getOperatorList/getTextContent methods to take parameter objects
#8377 Replace unnecessary bind(this) statements with arrow functions in web/ files
#8378 Convert the files in the /src/shared folder to ES6 modules
#8340 Fix char spacing bug in SVG mode
#8368 Enables source maps for webpack generated files.
#8385 Fix typo in LoopbackPort export
#8381 Re-factor PDFDocumentProperties such that it's properly reset when a new PDF file is opened (issue 8371)
#8387 amends Babel cache (#8364) implementation to also work on Safari
#8390 Upstream changes from: Bug 1319111 - Expose result principal URL ("final channel URL") on LoadInfo, convert current consumers of LOAD_REPLACE
#8393 Replace unnecessary var self = this statements with arrow functions in web/app.js
#8391 Convert the hand tool, interfaces and secondary toolbar to ES6 syntax
#8350 [api-minor] Fix svg image render
#8397 Simplify extractText, and replace unnecessary var self = this statements with arrow functions, in web/pdf_find_controller.js
#8399 Wait until PDFDocumentLoadingTask.destroy is resolved before calling done in the API unit-tests
#8400 Wait for previous pdfDocument(s) to be destroyed before running the next reference test
#8398 Convert the DOMCMapReaderFactory and DOMCanvasFactory to ES6 classes
#8258 Enable running a subset of the API unit-tests on Travis
#8406 Gracefully ignore transaction failure in plugin-babel-cached
#8411 Replace unnecessary var self = this statements with arrow functions in web/pdf_page_view.js and web/pdf_thumbnail_view.js
#8417 Use eslint-plugin-mozilla and the webextensions environment to avoid defining globals in each file.
#8413 [api-minor] Adds additional parameter so background color of canvas can be set
#8388 Cache JPEG images, just as we do for other image formats, in evaluator.js (issue 8380)
#8420 Revert "Upstream changes from: Bug 1319111 - Expose result principal URL ("final channel URL") on LoadInfo, convert current consumers of LOAD_REPLACE"
#8421 Change the importl10n script to use the Nightly channel
#8366 Removes shelljs
#8431 Replace a couple of leftover make.js references with gulpfile.js in docs/comments
#7635 Unify handling of various cursor tools, e.g. the current Hand Tool and a possible future Zoom Tool, in a new PDFCursorTools module
#8432 Remove the special handling for nameddests that look like standard pageNumbers
#8433 Remove the reference to compatibility.js from the README, since it's included by default in GENERIC builds
#8436 Don't map glyphs to the HANGUL FILLER (0x3164) Unicode location (issue 8424)
#8437 Resets canvas 2d context to the default state.
#8442 Add different code-paths to {CMap, ToUnicodeMap}.charCodeOf depending on length, since Array.prototype.indexOf can be extremely inefficient for very large arrays (issue 8372)
#8416 Refactor and ES6-ify PDFLinkService.navigateTo
#8452 Update webpack.js to support browsers that do not have the Web Workers API
#8450 Convert the overlay manager to ES6 syntax
#8284 Convert the files in the /src/core folder to ES6 modules
#8455 Convert the page view to ES6 syntax
#8458 Refactor the getTempCanvas function in pdf_thumbnail_view.js to a factory, in preparation for ES6 conversion of the thumbnail related code
#8462 Removes last UMDs from the modules.
#8463 Allow specifying the PDFJS_NEXT build flag via an environment variable when running the various gulp commands
#8396 Adds streams-lib polyfill and exports ReadableStream from shared/util.
#8394 Wraps mozL10n to async calls; splits firefox and generic l10n libs.
#8466 Add a stub createL10n to DefaultExternalServices in app.js
#8470 Fix inconsistent spacing and trailing commas in objects in extensions/ files, so we can enable the comma-dangle and object-curly-spacing ESLint rules later on
#8469 Fix inconsistent spacing and trailing commas in objects in web/ files, so we can enable the comma-dangle and object-curly-spacing ESLint rules later on
#8477 Fix inconsistent spacing and trailing commas in objects in test/ files, so we can enable the comma-dangle and object-curly-spacing ESLint rules later on
#8475 Fix inconsistent spacing and trailing commas in objects in remaining src/ files, so we can enable the comma-dangle and object-curly-spacing ESLint rules later on
#8474 Fix inconsistent spacing and trailing commas in objects in src/core/ files, so we can enable the comma-dangle and object-curly-spacing ESLint rules later on
#8478 Fix the remaining cases of inconsistent spacing and trailing commas in objects, and enable the comma-dangle and object-curly-spacing ESLint rules
#8482 Convert the thumbnail view/viewer to ES6 syntax
#8483 Convert the find controller to ES6 syntax
#8467 Bug 1353029 - Pass PdfJs.enabled into child on change.
#8499 Prevent console errors when clicking to change page while in Presentation Mode (issue 8498)
#8430 Adds sendWithStream method in MessageHandler.
#8441 Ensure that TilingPatterns have valid (non-zero) /BBox arrays (issue 8330)
#8508 Fixes duplicate creation of PDFWorker for the same port.
#8510 Prevent the Zoom dropdown from intermittently displaying an incorrect custom scale in Firefox (PR 8394 follow-up)
#8517 Additional check in globalScope detections
#8401 Adds gulp dist-install command; using pdfjs-dist package in examples.
#8519 Preventing from using the same canvas for multiple render()
#8522 Fixes WeakMap polyfill (and improves PDFWorker port check).
#8531 Remove PDFPageView.updatePosition since it's not actually necessary
#8515 Adds special case for origin of blob to the compatibility URL.
#8525 Allow for unbinding of events in we...

Read more

v1.8.188

13 Apr 15:45
Compare
Choose a tag to compare

Changes (from 1.8.170):

#8249 Release 1.8.170
#8244 Actually skip pages included in the skipPages array when running tests, rather than creating empty 1x1 canvases (issue 8241)
#8257 Enable the prefer-promise-reject-errors ESLint rule
#8266 Normalize blend mode names.
#8273 Correctly detect if requestAnimationFrame is supported in compatibility.js (issue 8272)
#8275 Rename PdfJsTelemetry-addon.jsm to PdfJsTelemetry-stub.jsm
#8228 Implement support for line annotations
#8262 Fix worker resolution on using minified version

v1.8.170

06 Apr 18:43
Compare
Choose a tag to compare

Changes:

#8001 Release of 1.7.225
#7991 [Firefox addon] Enforce double quotes, using ESLint, to avoid linting errors in mozilla-central (issue 7957)
#7995 [Firefox addon] Enable the consistent-return ESLint rule (issue 7957)
#8003 Move EOF/isEOF from core/parser.js to core/primitives.js
#8006 Remove usage of mozFillRule
#7959 Display a notification on the sidebarToggle button for PDF documents with outline/attachments
#8016 Remove the unused isStream property on various Streams
#7972 Enable the no-unused-vars ESLint rule
#8023 Moves preprocessor stuff to the gulpfile.
#8025 Adjust the brace-style ESLint rule to disallow single lines (and also enable no-iterator)
#8027 [Firefox addon] Remove the unused MOZ_CENTRAL constant
#8002 [api-minor] Fix #7798: Refactor scratch canvas usage.
#8030 Interactive forms: rewrite AcroForms example
#8028 Prevent browser console errors during testing
#8035 [api-minor] Add a getDocument parameter that allows disabling of the NativeImageDecoder (e.g. for use with Node.js)
#8036 [api-minor] Fixes behaviour of DOMCanvasFactory to return {canvas, context}.
#8038 Moves sed processing into the preprocessing tasks and merging tasks.
#8039 Moving interactive examples to jsfiddle.net
#8040 Update localization files
#8041 Interactive forms: set the buttonValue for radio buttons that do not have a fieldValue
#8043 Allow automatic print rotation via the enablePrintAutoRotate preference
#8046 Replacing custom bundling with webpack 2
#8053 [Chromium addon] Prevent errors that break the addon, caused by the DEFAULT_URL constant being replaced by a defaultUrl viewer configuration parameter (PR 8046 follow-up)
#8054 Write the l10n files to the correct destination for gulp mozcentral builds (PR 8023 follow-up)
#8058 Fixes pdf.combined.js for webpack
#8056 Use ChildNode.remove instead of ChildNode.ParentNode.removeChild in a couple of places (bug 1334831, issue 8008)
#8060 Font ascent descent calculation fix
#8062 Improve the README by removing outdated information
#8063 Consume the current character when encountering illegal characters in Lexer.getObject, in order to prevent infinite loops during reading of streams (issue 8061)
#8067 Include the pdfjschildbootstrap.js file in the output for gulp mozcentral builds (PR 8023 follow-up)
#8070 New node.js check to protect from webpack.
#8065 Annotations: refactor setting the normal appearance stream
#8071 Always choose a (3, 1) cmap table for TrueType fonts that have an encoding specified, regardless of the Symbolic font flag (bug 1337429)
#8064 [api-minor] Refactor fetching of built-in CMaps to utilize a factory on the display side instead, to allow users of the API to provide a custom CMap loading factory (e.g. for use with Node.js)
#8080 Enable running the cmap unit-tests on Travis by utilizing a NodeCMapReaderFactory
#8024 Open PDF attachments in the viewer instead of an unconditional download
#8081 iOS Chrome: Fix broken download button
#8091 Gulp: migrate baseline target from make.js
#8105 Always check all Kids nodes, in Catalog.getPageDict, to avoid getting stuck in an empty node further down in the Pages tree (issue 8088)
#8102 Move compatibility code to the shared/compatibility.js.
#8107 Init PDFWorker via MesssagePort.
#8109 Add gulp task to generate refs.
#8106 Ensure that Dicts found in Object Streams are assigned an objId in XRef.fetch
#8110 Interactive forms: make choice widget options inheritable (issue 8094)
#8072 Annotations: move operator list addition logic to src/core/document.js
#8050 Replaces RequireJS to SystemJS.
#8115 [CONTRIBUTING.md] Remove any mention of the mailing list, and the weekly meetings
#8116 Get rid of a couple eslint-disable statements in web/download_manager.js by instead relying on the preprocessor dead-code removal added in PR 7942
#8087 Allows to pull pdf.js from pdf_viewer using require().
#8112 Support the newWindow flag in white-listed app.launchURL JavaScript actions (PR 7794 follow-up)
#8126 Ensure that we don't ignore 0 values in Page.getInheritedPageProp (issue 8125)
#8128 Network: use the current location to prevent errors when using CSP headers
#8120 Publishes processed sources into pdfjs-dist/lib
#8129 Return undefined instead of Dict.empty from Page.getInheritedPageProp for non-existent properties to prevent possible future bugs
#8130 Don't include web/compatibility.js in the output for gulp lib (PR 8120 follow-up)
#8138 Get rid of element.removeChild(element.firstChild) usage (bug 1345253)
#8132 Viewer: enable find functionality for small devices
#8144 Widget annotations: do not crash if Parent is not a dictionary during field name construction (issue 8143)
#8151 Remove unnecessary .toolbarButton.group CSS class
#8135 Handle cff fonts with erroneous stackSize (issue 8097)
#8156 Add (and adjust) a couple of findbar title attributes, in viewer.html, that doesn't agree with the l10n/en-US/viewer.properties file
#8154 Change to conditions that pdfjsLib
#8168 Normalize the BBox entry in Tiling Pattern dictionaries (issue 8117)
#8174 Adjust the yoda ESLint rule to apply to inequalities as well
#8172 Upstream the changes from bug 1345294 - nsIPrefBranch should have methods to get/set unicode strings
#8170 Try to recover when encountering JPEG markers with too short marker lengths (issue 8169)
#8164 Don't read past the EOI marker for JPEG images with non-default restart interval (issue 7828)
#8183 Ensure that PDFDocument.documentInfo doesn't fail during document load, when the entire XRef table hasn't been fetched yet (issue 8180)
#8184 Rethrow MissingDataException when needed
#8194 Use a proper MessageHandler for PartialEvaluator.getTextContent to avoid errors for fonts relying on built-in CMap files (PR 8064 follow-up)
#8196 Remove unnecessary xref parameters from various method signatures in PartialEvaluator, since this.xref is already available in the relevant scope
#8198 Example for converting PDF to PNG using the Node canvas library
#8195 Enable babel on sources
#8190 Try harder to find the next valid JPEG marker when decoding Scan data (issue 8182, issue 8189)
#8202 Add a couple of basic ES6 rules to the ESLint config
#8207 Use a simple RefSetCache to significantly improve the performance of Catalog.getPageDict for certain long documents (PR 8105 follow-up)
#8205 Improve the error handling when loading of built-in CMap files fail (PR 8064 follow-up)
#8210 Refactor removing of the zoomLayer into a helper method, and use that in PDFPageView.reset to ensure that the entire zoomLayer is actually removed (issue 8209)
#8232 Lazily load NetUtil.jsm in PdfStreamConverter.jsm.
#8218 Split pdfjschildbootstrap.js to avoid sync IPC
#8157 [api-minor] Reject the RenderTask with an actual Error, instead of just a string, when rendering is cancelled
#8222 ios: Patch cancelAnimationFrame whenever fakeRequestAnimationFrame is used
#8235 Disable the NativeImageDecoder in the node/pdf2svg.js example (issue 7901)
#8239 Stub out Firefox addon Telemetry wrapper
#8243 Don’t skip glyph 0 in cmap.
#8248 Version 1.8

v1.7.225

26 Jan 20:54
Compare
Choose a tag to compare

Changes:

#7692 Release of 1.6.210
#7670 Only skip parsing a stream in Parser_makeFilter when we know for sure that it is empty (PR 6372 follow-up)
#7671 Interactive forms: render choice widget annotations
#7677 Bug 1302069 - Printing canvases at PDF document size.
#7694 Disables Font Loading API for Firefox.
#7697 Refactoring of printing code and mozPrintCallback polyfill
#7514 Ensure that we cancel any pending rendering operations when the viewer is closed (issue 7274)
#7714 Fix getTextContent evaluation to only apply TJ horizontal offsets using numeric items/args
#7722 Update to latest grab-to-pan version
#7726 Remove a remaining old-style preprocessor from src/core/fonts.js (PR 7322 follow-up)
#7668 Prevent an infinite loop in XRef_fetchUncompressed for encrypted PDF files with indirect objects in the /Encrypt dictionary (issue 7665)
#7727 Let Parser_makeFilter pass in the DecodeParms data to various image Streams, instead of re-fetching it in various [...]Stream.prototype.ensureBuffer methods
#7728 Gulp: port the all, extension and jsdoc targets
#7730 Fix a couple of JSDoc @typedefs to use @property (instead of @param) to fix some missing documentation when running gulp jsdoc
#7715 SVG: optimize and refactor group creation code
#7732 Removes SVG this.cgrp usages.
#7717 Explain double-click behaviour on tool tip
#7689 [api-minor] Add support for relative URLs, in both annotations and the outline, by adding a docBaseUrl parameter to PDFJS.getDocument (bug 766086)
#7749 Avoid accidentally rejecting a named destination that looks like a decimal number or a boolean (PR 7341 follow-up)
#7756 Travis CI: use most recent version of NPM
#7750 Add more validation to PDFLinkService_navigateTo
#7757 Remove/deprecate specifying a pageNumber directly after the hash symbol (#), to improve compatibility since other PDF viewers don't support this form (issue 7746)
#7766 Printing refactor split from 7721
#7771 Localization updates
#7773 [l10n] Add Swedish translations for a couple of new/changed localization IDs
#7774 Improve lint coverage and correct code style violations
#7745 [api-minor] Add basic support for Launch actions (issue 1778, issue 3897, issue 6616)
#7775 Widget annotation: implement field name according to the specification
#7778 Additional check to ensure pdfViewer object is defined before handleMouseWheel event accesses its property isInPresentationMode
#7782 Use stringToPDFString to sanitizing bad "Prefix" entries in Page Label dictionaries, and add more validation
#7698 Ignore reserved commands when parsing operands in CFFParser_parseDict, instead of just rejecting the entire font (bug 1308536)
#7786 Add HTTPS support for Demo
#7781 Viewer: improve responsiveness and clean up CSS
#7792 Make the customScaleOption disabled to prevent it being keyboard accessible (bug 1315608)
#7794 [api-minor] Add support for a couple of white-listed JavaScript actions that contains valid URLs (issue 3897, bug 843699)
#7800 Replace the Safari detection in checkRangeRequests in compatibility.js with a regular expression
#7801 Enable removing of all comments (except for Copyright notices) when preprocessing code, and reduce the indentation level
#7803 Fix #7701: additional check for http/https protocols to fix unsafe he…
#7819 For commands with with too few arguments, clear out args if it's an Array instead of replacing it with null in EvaluatorPreprocessor_read (issue 7804)
#7789 Refactor toolbar.
#7738 Adds SVG rendering capabilities to the main viewer.
#7826 Prevent "unreachable code after return statement" warnings from PDFPageView_paintOnSvg in the addons
#7830 Return a mock object in paintOnSvg when SVG rendering is not supported, to prevent TypeErrors in the addons
#7793 Rename the ViewHistory localStorage (and sessionStorage) key from database to pdfjs.history, and migrate existing data on read (issue 7760)
#7839 Correctly detect more cases of non-embedded Arial Black fonts (issue 7835)
#7832 Expose the optional UserUnit entry as a page property
#7841 Compatibility: disable range requests for iOS and refactor user agent detection
#7845 Make: include minified library files for the distribution target
#7846 Bidi: import Unicode types from the specification
#7849 Viewer: remove unused CSS rule
#7853 Fix the JSDoc comment for Catalog.parseDestDictionary
#7700 Improve rendering of non-embedded NuptialScript font
#7628 Fallback to the StandardEncoding for Nonsymbolic fonts without /Encoding entry (issue 7580)
#7858 Make the keyboard shortcuts Ctrl + Up/Down behave as Home/End (issue 7852)
#7856 Ensure that PartialEvaluator_extractWidths is able to handle indirect objects in all kinds of "width" data (issue 7855)
#7862 Don't fail if mozL10n is not present.
#7857 add basic unit-tests for murmurhash3.js
#7868 Adjust one of the Page Label unit-tests to use a PDF file where the "St" entry is both present and non-default (i.e. greater than one)
#7863 Colorspace: refactoring to prevent unnecessary creation of intermediate arrays
#7881 Remove a misplaced false from a condition in fixMetadata, in metadata.js, since it currently short circuits the entire condition
#7884 Ensure that we resolve indirect objects in Filter and DecodeParms arrays in parser.js
#7873 Document: handle indirect objects in MediaBox and CropBox entries
#7705 Move symbolic font glyphs to private use area if they don't have unicode mappings (issue 2594, bug 789074, bug 865644)
#7890 Fix a number of code style issues found by various ESLint rules, to make it easier to switch from JSHint to ESLint
#7886 Move the Preferences initialization/fetching code to the top of PDFViewerApplication.initialize, to enable using them when initializing e.g. the viewer components
#7897 Switch to using ESLint, instead of JSHint, for linting
#7900 Ensure that we handle indirect objects in all types of Opt entries in ChoiceWidget annotation dictionaries
#7898 Interactive forms: render button widget annotations (checkboxes and radio buttons)
#7879 Make use of textAdvanceScale consistent during combineTextItems. Fix for #7878.
#7829 Let finishPaintTask in pdf_page_view.js return a promise instead, to avoid having to throw in the paintTask.promise rejection handler, and don't reject the PDFPageView_draw promise when rendering is cancelled
#7920 Improve the handling of Encoding dictionary, with Differences array, in PartialEvaluator_preEvaluateFont
#7926 [api-minor] Ensure that the getDocument Promise is rejected if the loadingTask is destroyed, or an Error is thrown, inside of the onPassword callback (issue 7806)
#7934 Unit test files as modules
#7935 Enable the no-else-return ESLint rule
#7939 Enables some unit tests on travis.
#7941 Replace direct lookup of uniquePrefix/idCounters, in Page instances, with an idFactory containing an createObjId method instead
#7942 Fixes preprocessor testing and adds deadcode removal.
#7943 Various fixes for the external/builder/test*.js files
#7944 Removes Promise usage from preferences.js
#7869 Fixes issue #6071 - TIFF with 1 bit-depth
#7945 Moves locale and cmaps tasks to gulpfile.
#7948 Fix inverted calculation of RTL text percentage in bidi
#7951 Rename annotation_layer_spec.js to annotation_spec.js to better describe what is actually tested, and simplify the FileAttachmentAnnotation unit-test to avoid having to use the entire API in the test
#7904 Further adjust the heuristics used to detect OpenType font files with CFF data, to ensure that all Type0 fonts are handled the same way regardless of font Subtype (issue 7901)
#7913 [Firefox addon] Change the minimum supported version to Firefox 45, i.e. the current ESR version, and remove no longer necessary fallback code
#7954 [Bug 1329182] remove trailing newURI null parameters
#7956 [Bug 1330147] removeObserver calls should not supply a third parameter
#7960 Adjust the space-unary-ops ESLint rule to comply with mozilla-central lint rules
#7965 [Bug 1331081] omit addEventListener/removeEventListener's third parameter when it's false
#7974 Enable the no-lone-blocks ESLint rule
#7980 Fix #7978: Fixes ESLint yoda rule for the URL polyfill.
#7979 Enable the no-unsafe-finally/no-octal/no-useless-call ESLint rules
#7973 Enable the spaced-comment ESLint rule
#7985 Fixes IE9 document.readyState and input.type=number issues.
#7977 Ensure that we use the correct paintedViewport in PDFPageView.cssTransform, to avoid visual glitches on quick rotations (PR 7738 follow-up)
#7982 [Firefox addon] Convert the code to be ES6 friendly, in order to better agree with mozilla-central coding conventions (issue 7957)
#7988 Enable the no-empty-pattern/no-floating-decimal/no-self-compare/no-delete-var/no-new-object ESLint rules
#7971 remove viewer page div id
#7990 [Firefox addon] Stop bundling src/core/network.js into the FIREFOX/MOZCENTRAL builds (PR 7322 follow-up)
#7987 [api-minor] Adds noopener and nofollow to rel attribute of hyperlinks.
#8000 Version 1.7

v1.6.210

04 Oct 17:20
Compare
Choose a tag to compare

Changes:

#7236 Release of 1.5.188
#7237 Prevent accidentally overriding the error function in the commonobj messageHandler in api.js (issue 7232)
#7130 Add element to text layer even if width === 0
#7241 Makes importl10n and server async gulp functions.
#7202 Refactors dependencies of PDFViewerApplication on external services
#7240 Moves bundle target/task to gulpfile.js
#7251 Makes defines parameter non-optional in createBundle.
#7255 Mention web application usage in README.md
#7256 Port the publish target to Gulp
#7262 Fixes weird loop in the bidi.js.
#7254 Introducing EventBus for the viewer UI.
#7268 Better components examples.
#7266 Removes circular dependency of secondary toolbar on app.js.
#7272 Adds post UI control change events.
#7273 Prevent "Prefixed Fullscreen API is deprecated." warnings in the MOZCENTRAL version (issue 7270)
#7279 Fixes unneed conversion to array in CFF encodeInteger.
#7260 Moves all testing into gulpfile.
#7281 Fixes some static analysis warnings and recommendations
#7242 [Bug 1194700] Ensure that the customScaleOption is hidden in e10s
#7285 Split the font_spec.js unit-tests into cff_parser_spec.js and type1_parser_spec.js
#7298 Update link to CONTRIBUTING.md
#7301 Update grab_to_pan.js
#7302 Ignore 'endobj' commands inside of ObjStm streams (issue 5241, bug 898610, bug 1037816)
#7299 Prevent intermittent "Node was not found" errors when removing the zoomLayer in PDFPageView_draw
#7305 Remove streamsPrivate usage
#7244 Don't use shadow DOM for rendering /
#7306 Enables debugger only when needed.
#7289 Disable pagechange event if page is not changing.
#7295 Use Dict_getArray in more places in src/core/ to avoid issues when Arrays contain indirect objects
#7313 Convert the secondary toolbar to a class
#7317 Moves DEFAULT_PREFENCES into JSON format.
#7315 Solving issue #7307, 'use strict' context in compatibility.js
#7332 Fixes AMD name in web/the pdf_viewer.js.
#7337 Attempt to combine text runs positioned with setTextMatrix
#7340 Add basic unit-tests for unicode.js
#7316 Remove unused variables
#7300 Prevent adding invalid values in CFFDict_setByKey (bug 1068432)
#7344 Remove support for frames in old Chromium versions
#7353 Resolve a regression in the Chromium extension's preferences handling
#7346 Support syncing of settings in Chrome extension
#7352 Let non-viewable Popup Annotations inherit the parent's Annotation Flags if the parent is viewable
#7362 Github -> GitHub
#7374 Fix errors in setGState in PartialEvaluator_getTextContent that prevents text-selection from working properly
#7370 Add opt-out telemetry to the Chrome extension
#7388 Fix typo in telemetry.js, follow-up to #7370
#7361 Attempt to recover valid format 3 FDSelect data from broken CFF fonts (bug 1146106)
#7389 Move the isSpace utility function from core/parser.js to shared/util.js
#7341 [api-minor] Improve handling of links that are using explicit destination arrays
#7404 Force inline block display style for .
#7400 [Firefox addon] Change the minimum supported version to Firefox 38 and remove a bunch old no longer necessary fallback code
#7428 Unbreak the importl10n command by updating the links to point to hg.mozilla.org instead of mxr
#7430 Move Chromium URL rewrite to top of viewer.js
#7409 Upstream the changes from Bug 1242730 - Convert callsites to use channel.async0pen2() within browser/extensions/pdfjs (issue 7386)
#7437 [Firefox addon] Feature detect originAttributes to make it Seamonkey 2.40 compatible
#7427 Skip mapping of glyphs to Unicode "Ideographic space" (issue 7416)
#7438 Update README.md to only guarantee Firefox addon compatibility with the current ESR version
#7390 Add upper-case I as a possible space replacement fallback in Font.spaceWidth to improve text-selection (issue 7180)
#7463 Add back moz-specific fullscreen support code for MOZCENTRAL builds (bug 1268749, PR 7273 follow-up)
#7467 Add a getAttachments unit-test for a PDF file that actually contains attachments
#7441 Fallback to attempt to recover standard glyph names when amending the charCodeToGlyphId with entries from the differences array in type1FontGlyphMapping (issue 7439)
#7473 Update mxr.mozilla.org links to point to dxr.mozilla.org instead
#7453 Expose the text widget's maximum length.
#7455 Ensure that the necessary src/* dependencies are loaded before the viewer, when it's run with gulp server (issue 7448)
#7458 Consolidate updating of various Toolbar state (e.g. page and scale) in one method in PDFViewerApplication
#7479 Change the warn to info in recoverGlyphName to reduce the console spam
#7466 Remove handling of fallback arguments from PDFViewerApplication.open
#7480 Remove the obsolete MozBlobBuilder fallback from the createBlob utility function
#7481 [Firefox addon] Remove compatibility.js
#7478 optimize png images using zopflipng
#7489 trivial spelling fixes
#7485 Ensure that we don't reset the current page view if the user inputs an invalid page number (PR 7289 follow-up)
#7493 Catch errors and continue parsing in parseCMap (issue 7492)
#7490 Don't map glyphs to the Lepcha Unicode block (issue 7426)
#7447 Ignore .notdef in thedifferencesarray when building a fallback toUnicode map in PartialEvaluator_buildToUnicode (issue 5256)
#7347 Slightly refactor thefontRefhandling in PartialEvaluator_loadFont (issue 7403 and issue 7402)
#7505 Use the latest stable Node.js version on Travis CI and enable caching
#7506 Prevent errors when parsing Annotations with missing (or invalid) /Subtype entries (issue 7446)
#7475 [api-minor] Add a parameter to PDFPageProxy_getTextContent that controls whether PartialEvaluator_getTextContent will attempt to combine same line text items
#7502 Remove the previousPageNumber parameter from the pagechanging/pagechange events, and stop dispatching the events if the input is out of bounds
#7510 Remove previousPageNumber from the B2G viewer
#7511 Convert the B2G viewer from an extension to an example
#7519 Stop building the AMO extension
#7520 Add more unit-tests for primitives.js
#7526 Add validation of the rotation argument passed to set pagesRotation in PDFViewer
#7529 Log an error when the value passed to set currentPageNumber is out of bounds (PR 7502 followup)
#7532 Remove an obsolete comment for onAfterDraw in pdf_viewer.js
#7534 Add a parameter to the isName function that enables checking not just that something is a Name, but also that the actual name properties matches
#7548 Avoid window.print in a microtask
#7521 Bug 1291709 - PdfjsChromeUtils.jsm leaks browser.xul windows.
#7555 Add unit-tests for asynchronous methods in primitives.js
#7330 Try to prevent CanvasGraphics_getSinglePixelWidth from intermittently returning incorrect values in Firefox (issue 7188)
#7563 Upstream l10n changes from Bug 1259859.
#7573 [mobile-viewer] Add an async close method to the example, and change open to also be async (issue 7571)
#7540 Add a unit-test to check that ProblematicCharRanges contains valid entries
#7574 Remove unused globals from fonts unit test file
#7570 Create a fallback annotation id for entries in Annots dictionaries that are not indirect objects (issue 7569)
#7440 Prevent destinations with bad left/top values from scrolling the wrong page into view (bug 874482)
#7575 Update translations
#7387 Attempt to ignore multiple identical Tf (setFont) commands in PartialEvaluator_getTextContent (issue 5808)
#7579 Ensure that the zoom buttons are disabled correctly if the scale is smaller/larger than MIN_SCALE/MAX_SCALE in PDFViewerApplication._updateUIToolbar
#7583 Change the GoToPage Named Action to select the contents of the pageNumber input, rather than just focusing the element
#7539 [api-minor] Expanding divs to improve selection
#7585 Minor code style improvements after #7539
#7586 Move the Preferences initialization/fetching code to the top of PDFViewerApplication.initialize, and add a enhanceTextSelection preference to the viewer
#7592 Revert the commits from pull request #7586 for causing addon issues
#7407 Assign the quantizationTables after parsing the entire JPEG image, to prevent issues when the DQT (Define Quantization Tables) marker is encountered after SOF{n} (Start of Frame) markers (issue 7406)
#7591 Change src/core/jpg.js to use the error utility function instead of throwing
#7588 Use a WeakMap in src/display/text_layer.js
#7595 In display/api.js ensure that we always reject with an Error in JpegDecode, and adjust a couple of other rejection sites as well
#7596 Improve the structure for widget annotations
#7602 Render interactive form (AcroForm) text widget annotations
#7619 Only update the max-height of the SecondaryToolbar when it's actually visible
#7609 Add a enhanceTextSelection preference
#7600 Check that Type1C fonts does not actually contain OpenType font files (issue 7598)
#7546 Don't duplicate the first entry in the charCodeToGlyphId map for CIDFontType2 fonts with a CIDToGIDMap that already mapped the first entry to a non-zero glyphId (issue 7544)
#7621 Add a couple more, mostly text, reference tests for non-embedded symbolic fonts without included encoding information
#7622 Text widget annotations: implement maximum length and text alignment
#7624 Adding "proper" message port for fake worker.
#7623 Change src/core/jpx.js to use the error utility function instead of using throw new Error
#7626 Fix lint warnings in URL polyfill
#7629 Text widget annotations: implement unit testing and sanitize data values
#7634 Remove the deprecated mozDash/mozDashOffset canvas 2D context methods
#7632 [EnhanceTextSelection] Make expandTextDivs more efficient by updating all styles at once instead of piecewise
#7636 Drops unneeded HTTP refresh...

Read more