1621 Commits

Author SHA1 Message Date
Gunnsteinn Hall
d1c808d136
Merge pull request #274 from gunnsth/release/v3.5.0
Prepare unipdf release v3.5.0
v3.5.0
2020-03-09 08:55:32 +00:00
Gunnsteinn Hall
4bdda0af2b
Merge branch 'master' into release/v3.5.0 2020-03-08 23:59:33 +00:00
Gunnsteinn Hall
0a0e53d8c7 Update version to 3.5.0 2020-03-08 23:54:58 +00:00
Gunnsteinn Hall
c22b7efbe1 Prepare release of v3.4.2 2020-03-08 23:51:01 +00:00
Adrian-George Bostan
1d46fb4cc6
Parse ttf encoding subtable 31 after subtable 10 (#273) 2020-03-07 13:08:30 +00:00
Gunnsteinn Hall
937669cfed
Add basic glyph metrics support for Type 0 CID fonts (#272)
* Add basic glyph metrics support for Type 0 CID fonts
* Initialize font widths map if no W array is present
2020-03-05 18:47:16 +00:00
Adrian-George Bostan
d961079c5d
Add basic image rendering support (#266)
* Add render package
* Add text state
* Add more text operators
* Remove unnecessary files
* Add text font
* Add custom text render method
* Improve text rendering method
* Rename text state methods
* Refactor and document context interface
* Refact text begin/end operators
* Fix graphics state transformations
* Keep original font when doing font substitution
* Take page cropbox into account
* Revert to substitution font if original font measurement is 0
* Add font substitution package
* Implement addition transform.Point methods
* Use transform.Point in the image context package
* Remove unneeded functionality from the render image package
* Fix golint notices in the image rendering package
* Fix go vet notices in the render package
* Fix golint notices in the top-level render package
* Improve render context package documentation
* Document context text state struct.
* Document context text font struct.
* Minor logging improvements
* Add license disclaimer to the render package files
* Avoid using package aliases where possible
* Change style of section comments
* Adapt render package import style to follow the developer guide
* Improve documentation for the internal matrix implementation
* Update render package dependency versions
* Apply crop box post render
* Account for offseted media boxes
* Improve metrics of rendered characters
* Fix text matrix translation
* Change priority of fonts used for measuring rendered characters
* Skip invalid m and l operators on image rendering
* Small fix for v operator
* Fix rendered characters spacing issues
* Refactor naming of internal render packages
2020-03-02 21:22:54 +00:00
Peter Williams
e056c0e4d4
Fixed PdfColorspaceSpecialIndexed.ImageToRGB() (#259)
* Fixed PdfColorspaceSpecialIndexed.ImageToRGB() Fixes https://github.com/unidoc/unipdf/issues/258
* Fixed indexed colorspace bounds checking.
* Being super cautious to prevent a divide by zero error. I don't think the base cs can have <1 cpts.
* Updated image hash in extract_images_test.go to match new indexed colorspace code.
* add testfile from unipdf#258
2020-02-26 13:26:20 +00:00
Adrian-George Bostan
9de5fe644e
Add PdfFont text encoding methods (#257)
* Add PdfFont method for encoding runes to charcode bytes
* Add getter method for CMap nbits
* Take CMap nbits into account when encoding text
* Adapt font test cases to include text encoding testing
2020-02-17 22:54:20 +00:00
Gunnsteinn Hall
ea9988fb4d
Merge pull request #256 from unidoc/development
Apply fixes to master
v3.4.1
2020-02-12 00:48:15 +00:00
Gunnsteinn Hall
84f80af92a
Merge pull request #255 from unidoc/master
master into development
2020-02-12 00:39:52 +00:00
Gunnsteinn Hall
fd4f4b0a02
Make sure to stop seeking when reach beginning of file (#254)
* Fix infinite loop bug when looking for EOF
* Add testcases for EOF parsing
2020-02-11 20:09:34 +00:00
Alfred Hall
97286a4e7b
Merge pull request #253 from gunnsth/add-greeting-workflow
Greeting workflow
2020-02-10 23:06:58 +00:00
Gunnsteinn Hall
b33a11b1f2 Greeting workflow 2020-02-10 22:47:23 +00:00
Gunnsteinn Hall
fdee057a6e
Merge pull request #252 from adrg/inline-image-stream-end
Add whitespace tolerance when searching for inline image EI operand
2020-02-10 20:36:01 +00:00
Adrian-George Bostan
e9d2f1de3c Add whitespace tolerance when searching for inline image EI operand 2020-02-10 20:08:47 +02:00
Gunnsteinn Hall
a47c2eafa4
Merge pull request #250 from gunnsth/release/v3.4.0
Merge release v3.4.0 into development
2020-02-10 17:51:32 +00:00
Gunnsteinn Hall
11e21cdcff
Merge pull request #249 from gunnsth/release/v3.4.0
Prepare unipdf release v3.4.0
v3.4.0
2020-02-10 14:56:35 +00:00
Gunnsteinn Hall
42c9cd2e02 Update version to 3.4.0 prepare for release 2020-02-10 08:54:32 +00:00
Adrian-George Bostan
e2b3c6e6ba
Add predefined CMaps for Type 0 composite fonts (#246)
* Add packed predefined cmaps
* Add cmap cid range parsing
* Load base cmap for predefined cmaps
* Refactor pdfFont to Unicode methods
* Preserve CharcodeBytesToUnicode behavior
* Add support for CID-keyed Type 0 fonts
* Add method documentation for the cmap package
* Refactor and document charcode to Unicode conversion code
* Add more cmap parsing test cases
* Add more method documentation in the cmap package.
* Remove unused code from the bcmaps package
* Improve cmap test case
* Assume identity when encoder is missing on regenerating field appearance
* Add missing encoder log message
* Add inverse CMap mappings
* Add CMap encoder
* Address golint notices and small fix in the cmap package
* Keep smaller charcodes when generating cmap inverse mappings
* Update extractor test case
* Keep latest supplement charcodes/CIDs when computing inverse mappings
* Fix comment typo
2020-02-07 19:56:30 +00:00
Gunnsteinn Hall
6a2e4b7a1d
Merge pull request #247 from gunnsth/dev-inlineimage-ignore-optional
Ignore optional inline image field parameters
2020-02-04 23:20:22 +00:00
Gunnsteinn Hall
d97cc71266 Ignore optional inline image field parameters 2020-02-04 22:44:09 +00:00
Gunnsteinn Hall
81e3e14eb9
Merge pull request #242 from unidoc/master
Master into development
2020-01-30 22:24:56 +00:00
Gunnsteinn Hall
b5c7669868
Merge pull request #238 from adrg/eof-marker-search
Add tolerance for seeking EOF marker between read data buffers
2020-01-22 19:59:45 +00:00
Adrian-George Bostan
d521de9643 Add tolerance for seeking EOF marker between read data buffers 2020-01-22 20:56:03 +02:00
Gunnsteinn Hall
843a48ed7b
Merge pull request #233 from adrg/improve-outline-dest-parsing
Improve outline destination parsing
2020-01-21 20:44:07 +00:00
Adrian-George Bostan
3bd083475d Minor refactoring 2020-01-21 22:18:11 +02:00
Adrian-George Bostan
692ead8496 Improve outline destination parsing 2020-01-21 22:11:20 +02:00
Gunnsteinn Hall
38e5979b4c
Merge pull request #232 from adrg/eof-search-buffer
Extend buffer used for searching EOF marker
2020-01-20 17:34:21 +00:00
Adrian-George Bostan
fea1a6a421 Extend buffer used for searching EOF marker 2020-01-20 17:27:52 +02:00
Gunnsteinn Hall
be2b7f40e9
Merge pull request #231 from sprucehealth/fix-get-media-box
Follow object indirections in PdfPage.GetMediaBox
2020-01-18 17:36:08 +00:00
Samuel Stauffer
d3a160ba41 Follow object indirections in PdfPage.GetMediaBox 2020-01-17 14:35:46 -08:00
Gunnsteinn Hall
f2cd7bd24e
Merge pull request #229 from adrg/outlines-extraction
Improve outline extraction
2020-01-17 08:53:04 +00:00
Adrian-George Bostan
7c5d52cca5 Add outline test case 2020-01-16 20:52:59 +02:00
Adrian-George Bostan
029d4c34d8 Rename NewOutlineFromReaderOutline to GetOutlines and move it in the reader 2020-01-16 19:51:34 +02:00
Adrian-George Bostan
84dd2d145a Add ToOutlineTree method for outline conversion 2020-01-16 19:31:54 +02:00
Adrian-George Bostan
dbd9e96abc Fix method comment typo 2020-01-15 23:36:07 +02:00
Adrian-George Bostan
9a553c30ba Add NewOutlineFromReaderOutline 2020-01-15 23:02:05 +02:00
Adrian-George Bostan
8afe2c21ed Export Outline and OutlineItem entries 2020-01-15 20:04:06 +02:00
Adrian-George Bostan
2c395a6598 Add GetContext method for exporting the outline tree node context 2020-01-15 19:42:16 +02:00
Gunnsteinn Hall
3e66280dbf
Merge pull request #228 from adrg/get-outlines-flattened-improve
Improve traversal of outline item nodes in the GetOutlinesFlattened method
2020-01-15 08:22:43 +00:00
Gunnsteinn Hall
2b92598d16
Merge pull request #216 from sprucehealth/unify-number-parsing
Unify and optimize number parsing
2020-01-14 20:14:40 +00:00
Adrian-George Bostan
ac736a2f78 Improve traversal of outline item nodes in the GetOutlinesFlattened method 2020-01-14 21:39:12 +02:00
Gunnsteinn Hall
4b1d8a98fd
Merge pull request #225 from adrg/crypt-dict-invalid-type
Attempt decryption for invalid crypt filter dictionary type
2020-01-13 22:09:36 +00:00
Gunnsteinn Hall
c7c85bff8b
Merge pull request #224 from adrg/chapter-set-numbering
Fix Chapter component  SetShowNumbering method
2020-01-13 22:08:48 +00:00
Gunnsteinn Hall
f4d4d05a43
Merge pull request #223 from adrg/outline-items-utf16
Use utf-16 encoding for serializing outline item titles
2020-01-13 22:07:05 +00:00
Adrian-George Bostan
002f0d11d7 Attempt decryption for invalid crypt filter dictionary type 2020-01-13 22:11:15 +02:00
Samuel Stauffer
fc91c6b3c4 Revert change to go.mod 2020-01-13 11:20:35 -08:00
Adrian-George Bostan
b6867132da Fix chapter component SetShowNumbering method 2020-01-13 21:00:11 +02:00
Adrian-George Bostan
33530535e3 Use utf-16 encoding for serializing outline item titles 2020-01-13 20:56:02 +02:00