[jira] [Commented] (PDFBOX-4068) Create ContentStream for XObject forms and tiling patterns

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4068?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16469962#comment-16469962
 ] 

ASF subversion and git services commented on PDFBOX-4068:
-

Commit 1831309 from [~jahewson] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1831309 ]

PDFBOX-4068: refactor: 'resources' is only ever set within constructors, make 
it a constructor parameter

> Create ContentStream for XObject forms and tiling patterns
> --
>
> Key: PDFBOX-4068
> URL: https://issues.apache.org/jira/browse/PDFBOX-4068
> Project: PDFBox
>  Issue Type: Task
>  Components: PDModel
>Reporter: Tilman Hausherr
>Priority: Major
>
> We have a {{PDAppearanceContentStream}} for appearances but nothing for 
> XObject forms and tiling patterns.
> What we need should extend {{PDAbstractContentStream}} and should have a 
> constructor like
> {code:java}
> public PDFormContentStream(PDFormXObject form) throws IOException
> {code}
> Alternatively, why not replace {{PDAppearanceContentStream}} ? Its parameter 
> {{PDAppearanceStream}} is extended from {{PDFormXObject}} so we could just 
> use the base class.
> We need this both for 2.0 and 3.* - we have users who have a really hard time 
> fiddling with low level operators instead of using the methods.
> In 2.0 we could replace the parameter of {{PDPageContentStream}} that is 
> currently {{PDAppearanceStream}}. This would be a non breaking change.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Resolved] (PDFBOX-4218) image with stencil mask appears interpolated

2018-05-10 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4218?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr resolved PDFBOX-4218.
-
Resolution: Fixed

> image with stencil mask appears interpolated
> 
>
> Key: PDFBOX-4218
> URL: https://issues.apache.org/jira/browse/PDFBOX-4218
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Assignee: Tilman Hausherr
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: image_via_1.3_006.pdf
>
>
> File is from
> https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/image_via/image_via_1.3_006.pdf
> The color edges of the lower image are interpolated but should not be. 
> Solution: respect the image interpolation setting in 
> {{PDImageXObject.scaleImage()}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4218) image with stencil mask appears interpolated

2018-05-10 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4218?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470033#comment-16470033
 ] 

Tilman Hausherr commented on PDFBOX-4218:
-

Regression tests show only some minor changes not visible to human eye, so it's 
really just the attached PDF that is affected.

> image with stencil mask appears interpolated
> 
>
> Key: PDFBOX-4218
> URL: https://issues.apache.org/jira/browse/PDFBOX-4218
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Assignee: Tilman Hausherr
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: image_via_1.3_006.pdf
>
>
> File is from
> https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/image_via/image_via_1.3_006.pdf
> The color edges of the lower image are interpolated but should not be. 
> Solution: respect the image interpolation setting in 
> {{PDImageXObject.scaleImage()}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4218) image with stencil mask appears interpolated

2018-05-10 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4218?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-4218:

Attachment: PDFBOX-4218-image_via_1.3_006.pdf-1.png

> image with stencil mask appears interpolated
> 
>
> Key: PDFBOX-4218
> URL: https://issues.apache.org/jira/browse/PDFBOX-4218
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Assignee: Tilman Hausherr
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: PDFBOX-4218-image_via_1.3_006.pdf-1.png, 
> image_via_1.3_006.pdf
>
>
> File is from
> https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/image_via/image_via_1.3_006.pdf
> The color edges of the lower image are interpolated but should not be. 
> Solution: respect the image interpolation setting in 
> {{PDImageXObject.scaleImage()}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4217) Folded Coons patch renders incorrectly

2018-05-10 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-4217:

Attachment: PDFBOX-4217-shade_via_1.3_006.pdf-1.png

> Folded Coons patch renders incorrectly
> --
>
> Key: PDFBOX-4217
> URL: https://issues.apache.org/jira/browse/PDFBOX-4217
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Priority: Minor
>  Labels: Coons, shading, shadingpattern
> Attachments: PDFBOX-4217-shade_via_1.3_006.pdf-1.png, 
> shade_via_1.3_006.pdf
>
>
> File is from
> [https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip]
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/shade_via/shade_via_1.3_006.pdf
> Priority set to minor because this is an unrealistic test image. Every viewer 
> (except Adobe Reader) I tried fails in some way.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Re: PDFBox 2.0.10?

2018-05-10 Thread Tilman Hausherr

Am 10.05.2018 um 12:37 schrieb Andreas Lehmkuehler:

Hi,

I'm planning to cut a 2.0.10 release next week (most likely on 
Monday), any objections? 


+1 from me, but the jbig2 plugin should be released as well, even if it 
is only one issue.


Tilman



-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Re: PDFBox 2.0.10?

2018-05-10 Thread Andreas Lehmkuehler

Am 10.05.2018 um 13:09 schrieb Tilman Hausherr:

Am 10.05.2018 um 12:37 schrieb Andreas Lehmkuehler:

Hi,

I'm planning to cut a 2.0.10 release next week (most likely on Monday), any 
objections? 


+1 from me, but the jbig2 plugin should be released as well, even if it is only 
one issue.
We should release that first, so that we can update PDFBox to use it before 
releasing 2.0.10.


I'm going to start with the plugin next Monday.


Tilman



-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org




-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



PDFBox 2.0.10?

2018-05-10 Thread Andreas Lehmkuehler

Hi,

I'm planning to cut a 2.0.10 release next week (most likely on Monday), any 
objections?


Andreas

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Build failed in Jenkins: PDFBox-sonar #456

2018-05-10 Thread Apache Jenkins Server
See 

--
[...truncated 343.46 KB...]
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.6.0:compile (default-compile) @ debugger-app 
---
[INFO] No sources to compile
[INFO] 
[INFO] 
[INFO] Building Apache PDFBox examples 3.0.0-SNAPSHOT
[INFO] 
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink-component-test-support/1.4/wink-component-test-support-1.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink-component-test-support/1.4/wink-component-test-support-1.4.pom
 (3 KB at 131.1 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink/1.4/wink-1.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink/1.4/wink-1.4.pom (42 
KB at 1820.0 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-context/3.0.5.RELEASE/spring-context-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-context/3.0.5.RELEASE/spring-context-3.0.5.RELEASE.pom
 (7 KB at 284.9 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-parent/3.0.5.RELEASE/spring-parent-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-parent/3.0.5.RELEASE/spring-parent-3.0.5.RELEASE.pom
 (9 KB at 455.3 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-aop/3.0.5.RELEASE/spring-aop-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-aop/3.0.5.RELEASE/spring-aop-3.0.5.RELEASE.pom
 (3 KB at 132.0 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-asm/3.0.5.RELEASE/spring-asm-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-asm/3.0.5.RELEASE/spring-asm-3.0.5.RELEASE.pom
 (2 KB at 110.8 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom
 (3 KB at 134.9 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-core/3.0.5.RELEASE/spring-core-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-core/3.0.5.RELEASE/spring-core-3.0.5.RELEASE.pom
 (3 KB at 142.1 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-expression/3.0.5.RELEASE/spring-expression-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-expression/3.0.5.RELEASE/spring-expression-3.0.5.RELEASE.pom
 (2 KB at 95.5 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-web/3.0.5.RELEASE/spring-web-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-web/3.0.5.RELEASE/spring-web-3.0.5.RELEASE.pom
 (5 KB at 114.7 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/xmlunit/xmlunit/1.1/xmlunit-1.1.pom
Downloaded: 
http://repo.maven.apache.org/maven2/xmlunit/xmlunit/1.1/xmlunit-1.1.pom (2 KB 
at 44.9 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/geronimo/specs/geronimo-jaxrs_1.1_spec/1.0/geronimo-jaxrs_1.1_spec-1.0.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/geronimo/specs/geronimo-jaxrs_1.1_spec/1.0/geronimo-jaxrs_1.1_spec-1.0.pom
 (4 KB at 204.9 KB/sec)
[INFO] 
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-maven-version) @ 
pdfbox-examples ---
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (process-resource-bundles) 
@ pdfbox-examples ---
[INFO] 
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) @ 
pdfbox-examples ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 8 resources
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.6.0:compile (default-compile) @ 
pdfbox-examples ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 78 source files to 

[WARNING] bootstrap class path not set in conjunction with -source 1.7
[INFO] 
:
 Some input files use unchecked or unsafe operations.
[INFO] 
:
 Recompile with -Xlint:unchecked for details.
[INFO]  

Build failed in Jenkins: PDFBox-sonar » Apache PDFBox #456

2018-05-10 Thread Apache Jenkins Server
See 


--
[INFO] 
[INFO] 
[INFO] Building Apache PDFBox 3.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-maven-version) @ 
pdfbox-reactor ---
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (process-resource-bundles) 
@ pdfbox-reactor ---
[INFO] 
[INFO] 
[INFO] Building Apache PDFBox 3.0.0-SNAPSHOT
[INFO] 
Downloading: 
http://repo.maven.apache.org/maven2/com/github/jai-imageio/jai-imageio-core/1.4.0/jai-imageio-core-1.4.0.jar
Downloading: 
http://repo.maven.apache.org/maven2/com/github/jai-imageio/jai-imageio-jpeg2000/1.3.0/jai-imageio-jpeg2000-1.3.0.jar
Downloaded: 
http://repo.maven.apache.org/maven2/com/github/jai-imageio/jai-imageio-core/1.4.0/jai-imageio-core-1.4.0.jar
 (614 KB at 8401.8 KB/sec)
Downloaded: 
http://repo.maven.apache.org/maven2/com/github/jai-imageio/jai-imageio-jpeg2000/1.3.0/jai-imageio-jpeg2000-1.3.0.jar
 (450 KB at 5487.1 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink-component-test-support/1.4/wink-component-test-support-1.4.jar
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-context/3.0.5.RELEASE/spring-context-3.0.5.RELEASE.jar
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-aop/3.0.5.RELEASE/spring-aop-3.0.5.RELEASE.jar
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.jar
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-core/3.0.5.RELEASE/spring-core-3.0.5.RELEASE.jar
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink-component-test-support/1.4/wink-component-test-support-1.4.jar
 (40 KB at 1985.3 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-expression/3.0.5.RELEASE/spring-expression-3.0.5.RELEASE.jar
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-expression/3.0.5.RELEASE/spring-expression-3.0.5.RELEASE.jar
 (166 KB at 7207.5 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-asm/3.0.5.RELEASE/spring-asm-3.0.5.RELEASE.jar
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-aop/3.0.5.RELEASE/spring-aop-3.0.5.RELEASE.jar
 (314 KB at 7294.5 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-web/3.0.5.RELEASE/spring-web-3.0.5.RELEASE.jar
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-core/3.0.5.RELEASE/spring-core-3.0.5.RELEASE.jar
 (374 KB at 7182.3 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/slf4j/jcl-over-slf4j/1.6.1/jcl-over-slf4j-1.6.1.jar
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-context/3.0.5.RELEASE/spring-context-3.0.5.RELEASE.jar
 (654 KB at 11876.1 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/xmlunit/xmlunit/1.1/xmlunit-1.1.jar
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-asm/3.0.5.RELEASE/spring-asm-3.0.5.RELEASE.jar
 (52 KB at 3455.9 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/geronimo/specs/geronimo-jaxrs_1.1_spec/1.0/geronimo-jaxrs_1.1_spec-1.0.jar
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.jar
 (543 KB at 8218.1 KB/sec)
Downloaded: 
http://repo.maven.apache.org/maven2/org/slf4j/jcl-over-slf4j/1.6.1/jcl-over-slf4j-1.6.1.jar
 (17 KB at 1126.8 KB/sec)
Downloaded: 
http://repo.maven.apache.org/maven2/xmlunit/xmlunit/1.1/xmlunit-1.1.jar (85 KB 
at 4679.3 KB/sec)
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-web/3.0.5.RELEASE/spring-web-3.0.5.RELEASE.jar
 (387 KB at 12877.2 KB/sec)
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/geronimo/specs/geronimo-jaxrs_1.1_spec/1.0/geronimo-jaxrs_1.1_spec-1.0.jar
 (54 KB at 3154.9 KB/sec)
[INFO] 
[INFO] --- sonar-maven-plugin:3.4.0.905:sonar (default-cli) @ pdfbox-reactor ---
[INFO] User cache: /home/jenkins/.sonar/cache
[INFO] SonarQube version: 5.6.3
[INFO] Default locale: "en_US", source code encoding: "UTF-8"
[INFO] Load global repositories
[INFO] Load global repositories (done) | time=1323ms
[INFO] Server id: 17cad23492ff68b
[INFO] User cache: /home/jenkins/.sonar/cache
[INFO] Load plugins index
[INFO] Load plugins index (done) | time=328ms
[INFO] Process project properties
[INFO] 

Build failed in Jenkins: PDFBox-sonar » Apache PDFBox examples #457

2018-05-10 Thread Apache Jenkins Server
See 


--
[INFO] 
[INFO] 
[INFO] Building Apache PDFBox examples 3.0.0-SNAPSHOT
[INFO] 
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-core/5.5.4/lucene-core-5.5.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-core/5.5.4/lucene-core-5.5.4.pom
 (3 KB at 90.9 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-parent/5.5.4/lucene-parent-5.5.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-parent/5.5.4/lucene-parent-5.5.4.pom
 (5 KB at 277.9 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-solr-grandparent/5.5.4/lucene-solr-grandparent-5.5.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-solr-grandparent/5.5.4/lucene-solr-grandparent-5.5.4.pom
 (388 KB at 6450.0 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-analyzers-common/5.5.4/lucene-analyzers-common-5.5.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/lucene/lucene-analyzers-common/5.5.4/lucene-analyzers-common-5.5.4.pom
 (3 KB at 171.6 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink-component-test-support/1.4/wink-component-test-support-1.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink-component-test-support/1.4/wink-component-test-support-1.4.pom
 (3 KB at 161.9 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink/1.4/wink-1.4.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/apache/wink/wink/1.4/wink-1.4.pom (42 
KB at 2093.0 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-context/3.0.5.RELEASE/spring-context-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-context/3.0.5.RELEASE/spring-context-3.0.5.RELEASE.pom
 (7 KB at 263.0 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-aop/3.0.5.RELEASE/spring-aop-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-aop/3.0.5.RELEASE/spring-aop-3.0.5.RELEASE.pom
 (3 KB at 147.6 KB/sec)
Downloading: 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom
[WARNING] Checksum validation failed, could not read expected checksum: GET 
request of: 
org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom.sha1
 from central failed for 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom
[WARNING] Checksum validation failed, could not read expected checksum: GET 
request of: 
org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom.sha1
 from central failed for 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom
Downloaded: 
http://repo.maven.apache.org/maven2/org/springframework/spring-beans/3.0.5.RELEASE/spring-beans-3.0.5.RELEASE.pom
 (3 KB at 69.7 KB/sec)
[WARNING] Failed to write resolution tracking file 
/home/jenkins/jenkins-slave/maven-repositories/0/org/springframework/spring-beans/3.0.5.RELEASE/_maven.repositories
java.io.IOException: No space left on device
at java.io.RandomAccessFile.writeBytes(Native Method)
at java.io.RandomAccessFile.write(RandomAccessFile.java:512)
at 
org.sonatype.aether.impl.internal.TrackingFileManager.update(TrackingFileManager.java:129)
at 
org.sonatype.aether.impl.internal.EnhancedLocalRepositoryManager.addRepo(EnhancedLocalRepositoryManager.java:158)
at 
org.sonatype.aether.impl.internal.EnhancedLocalRepositoryManager.addArtifact(EnhancedLocalRepositoryManager.java:137)
at 
org.sonatype.aether.impl.internal.EnhancedLocalRepositoryManager.add(EnhancedLocalRepositoryManager.java:110)
at 
org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:501)
at 
org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:216)
at 
org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifact(DefaultArtifactResolver.java:193)
at 
org.apache.maven.repository.internal.DefaultArtifactDescriptorReader.loadPom(DefaultArtifactDescriptorReader.java:281)
at 
org.apache.maven.repository.internal.DefaultArtifactDescriptorReader.readArtifactDescriptor(DefaultArtifactDescriptorReader.java:186)
at 

[jira] [Commented] (PDFBOX-4071) Improve code quality (3)

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470384#comment-16470384
 ] 

ASF subversion and git services commented on PDFBOX-4071:
-

Commit 1831339 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1831339 ]

PDFBOX-4071: fix typo

> Improve code quality (3)
> 
>
> Key: PDFBOX-4071
> URL: https://issues.apache.org/jira/browse/PDFBOX-4071
> Project: PDFBox
>  Issue Type: Task
>Affects Versions: 2.0.8
>Reporter: Tilman Hausherr
>Priority: Major
> Attachments: pdfbox-screenshot-bad.png, pdfbox-screenshot-good.png
>
>
> This is a longterm issue for the task to improve code quality, by using the 
> [SonarQube 
> report|https://analysis.apache.org/dashboard/index/org.apache.pdfbox:pdfbox-reactor],
>  hints in different IDEs, the FindBugs tool and other code quality tools.
> This is a follow-up of PDFBOX-2852, which was getting too long.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Jenkins build is back to normal : PDFBox-sonar #458

2018-05-10 Thread Apache Jenkins Server
See 


-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Jenkins build is back to normal : PDFBox-sonar » Apache PDFBox #458

2018-05-10 Thread Apache Jenkins Server
See 



-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4071) Improve code quality (3)

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470367#comment-16470367
 ] 

ASF subversion and git services commented on PDFBOX-4071:
-

Commit 1831337 from [~tilman] in branch 'pdfbox/branches/2.0'
[ https://svn.apache.org/r1831337 ]

PDFBOX-4071: refactor the code in order to not assign to this loop counter from 
within the loop body

> Improve code quality (3)
> 
>
> Key: PDFBOX-4071
> URL: https://issues.apache.org/jira/browse/PDFBOX-4071
> Project: PDFBox
>  Issue Type: Task
>Affects Versions: 2.0.8
>Reporter: Tilman Hausherr
>Priority: Major
> Attachments: pdfbox-screenshot-bad.png, pdfbox-screenshot-good.png
>
>
> This is a longterm issue for the task to improve code quality, by using the 
> [SonarQube 
> report|https://analysis.apache.org/dashboard/index/org.apache.pdfbox:pdfbox-reactor],
>  hints in different IDEs, the FindBugs tool and other code quality tools.
> This is a follow-up of PDFBOX-2852, which was getting too long.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4071) Improve code quality (3)

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470364#comment-16470364
 ] 

ASF subversion and git services commented on PDFBOX-4071:
-

Commit 1831336 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1831336 ]

PDFBOX-4071: refactor the code in order to not assign to this loop counter from 
within the loop body

> Improve code quality (3)
> 
>
> Key: PDFBOX-4071
> URL: https://issues.apache.org/jira/browse/PDFBOX-4071
> Project: PDFBox
>  Issue Type: Task
>Affects Versions: 2.0.8
>Reporter: Tilman Hausherr
>Priority: Major
> Attachments: pdfbox-screenshot-bad.png, pdfbox-screenshot-good.png
>
>
> This is a longterm issue for the task to improve code quality, by using the 
> [SonarQube 
> report|https://analysis.apache.org/dashboard/index/org.apache.pdfbox:pdfbox-reactor],
>  hints in different IDEs, the FindBugs tool and other code quality tools.
> This is a follow-up of PDFBOX-2852, which was getting too long.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Build failed in Jenkins: PDFBox-sonar #457

2018-05-10 Thread Apache Jenkins Server
See 

--
[...truncated 15.80 KB...]
[INFO] 
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-maven-version) @ 
preflight ---
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (process-resource-bundles) 
@ preflight ---
[INFO] 
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) @ 
preflight ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 0 resource
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.6.0:compile (default-compile) @ preflight ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 117 source files to 

[WARNING] bootstrap class path not set in conjunction with -source 1.7
[INFO] 
:
 

 uses unchecked or unsafe operations.
[INFO] 
:
 Recompile with -Xlint:unchecked for details.
[INFO] 
[INFO] 
[INFO] Building Apache Preflight application 3.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-maven-version) @ 
preflight-app ---
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (process-resource-bundles) 
@ preflight-app ---
[INFO] 
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) @ 
preflight-app ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory 

[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.6.0:compile (default-compile) @ 
preflight-app ---
[INFO] No sources to compile
[INFO] 
[INFO] 
[INFO] Building Apache PDFBox Debugger 3.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-maven-version) @ 
pdfbox-debugger ---
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (process-resource-bundles) 
@ pdfbox-debugger ---
[INFO] 
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) @ 
pdfbox-debugger ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 13 resources
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.6.0:compile (default-compile) @ 
pdfbox-debugger ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 82 source files to 

[WARNING] bootstrap class path not set in conjunction with -source 1.7
[WARNING] 
:[166,19]
 appendRawCommands(byte[]) in org.apache.pdfbox.pdmodel.PDPageContentStream has 
been deprecated
[INFO] 
:
 Some input files use unchecked or unsafe operations.
[INFO] 
:
 Recompile with -Xlint:unchecked for details.
[INFO] 
[INFO] 
[INFO] Building Apache PDFBox tools 3.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-enforcer-plugin:1.4.1:enforce (enforce-maven-version) @ 
pdfbox-tools ---
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (process-resource-bundles) 
@ pdfbox-tools ---
[INFO] 
[INFO] --- maven-resources-plugin:3.0.2:resources (default-resources) @ 
pdfbox-tools ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory 

[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.6.0:compile (default-compile) @ pdfbox-tools 
---
[INFO] Changes detected - recompiling the 

Jenkins build is back to normal : PDFBox-sonar » Apache PDFBox examples #458

2018-05-10 Thread Apache Jenkins Server
See 



-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4071) Improve code quality (3)

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470352#comment-16470352
 ] 

ASF subversion and git services commented on PDFBOX-4071:
-

Commit 1831334 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1831334 ]

PDFBOX-4071: replace the synchronized class "Stack" by the unsynchronized 
"Deque"

> Improve code quality (3)
> 
>
> Key: PDFBOX-4071
> URL: https://issues.apache.org/jira/browse/PDFBOX-4071
> Project: PDFBox
>  Issue Type: Task
>Affects Versions: 2.0.8
>Reporter: Tilman Hausherr
>Priority: Major
> Attachments: pdfbox-screenshot-bad.png, pdfbox-screenshot-good.png
>
>
> This is a longterm issue for the task to improve code quality, by using the 
> [SonarQube 
> report|https://analysis.apache.org/dashboard/index/org.apache.pdfbox:pdfbox-reactor],
>  hints in different IDEs, the FindBugs tool and other code quality tools.
> This is a follow-up of PDFBOX-2852, which was getting too long.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4071) Improve code quality (3)

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470385#comment-16470385
 ] 

ASF subversion and git services commented on PDFBOX-4071:
-

Commit 1831340 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1831340 ]

PDFBOX-4071: remove commented out line

> Improve code quality (3)
> 
>
> Key: PDFBOX-4071
> URL: https://issues.apache.org/jira/browse/PDFBOX-4071
> Project: PDFBox
>  Issue Type: Task
>Affects Versions: 2.0.8
>Reporter: Tilman Hausherr
>Priority: Major
> Attachments: pdfbox-screenshot-bad.png, pdfbox-screenshot-good.png
>
>
> This is a longterm issue for the task to improve code quality, by using the 
> [SonarQube 
> report|https://analysis.apache.org/dashboard/index/org.apache.pdfbox:pdfbox-reactor],
>  hints in different IDEs, the FindBugs tool and other code quality tools.
> This is a follow-up of PDFBOX-2852, which was getting too long.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4217) Folded Coons patch renders incorrectly

2018-05-10 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-4217:

Labels: Coons shading shadingpattern  (was: Coons shade shading)

> Folded Coons patch renders incorrectly
> --
>
> Key: PDFBOX-4217
> URL: https://issues.apache.org/jira/browse/PDFBOX-4217
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Priority: Minor
>  Labels: Coons, shading, shadingpattern
> Attachments: shade_via_1.3_006.pdf
>
>
> File is from
> [https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip]
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/shade_via/shade_via_1.3_006.pdf



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Created] (PDFBOX-4217) Folded Coons patch renders incorrectly

2018-05-10 Thread Tilman Hausherr (JIRA)
Tilman Hausherr created PDFBOX-4217:
---

 Summary: Folded Coons patch renders incorrectly
 Key: PDFBOX-4217
 URL: https://issues.apache.org/jira/browse/PDFBOX-4217
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 2.0.9
Reporter: Tilman Hausherr
 Attachments: shade_via_1.3_006.pdf

File is from

[https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip]

and can be found in 
lumi-read/trunk/PDF_smoketest/pdf/shade_via/shade_via_1.3_006.pdf



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4218) image with stencil mask appears interpolated

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4218?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470032#comment-16470032
 ] 

ASF subversion and git services commented on PDFBOX-4218:
-

Commit 1831314 from [~tilman] in branch 'pdfbox/branches/2.0'
[ https://svn.apache.org/r1831314 ]

PDFBOX-4218: respect the interpolation setting when scaling masked image

> image with stencil mask appears interpolated
> 
>
> Key: PDFBOX-4218
> URL: https://issues.apache.org/jira/browse/PDFBOX-4218
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Assignee: Tilman Hausherr
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: image_via_1.3_006.pdf
>
>
> File is from
> https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/image_via/image_via_1.3_006.pdf
> The color edges of the lower image are interpolated but should not be. 
> Solution: respect the image interpolation setting in 
> {{PDImageXObject.scaleImage()}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4189) Enable PDF creation with Indian languages, by reading and utilizing the GSUB table

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16469993#comment-16469993
 ] 

John Hewson commented on PDFBOX-4189:
-

As part of PDFBOX-4068, I've consolidated all text handling in 
PDAbstractContentStream. So the relevant code from PDPageContentStream can now 
be found there.

> Enable PDF creation with Indian languages, by reading and utilizing the GSUB 
> table
> --
>
> Key: PDFBOX-4189
> URL: https://issues.apache.org/jira/browse/PDFBOX-4189
> Project: PDFBox
>  Issue Type: New Feature
>  Components: FontBox, PDModel
>Reporter: Palash Ray
>Priority: Major
> Attachments: Bengali-text-after.pdf, Bengali-text-before.pdf, 
> BengaliPdfGenerationHelloWorld.java, bengali-example.pdf, 
> bengali-example2.pdf, bengali-example3.pdf, committed.patch, screenshot.png
>
>   Original Estimate: 336h
>  Remaining Estimate: 336h
>
> Implemented proper rendering of Indian languages, which need extensive Glyph 
> substitution. The GSUB table has been read and used effectively to replace 
> some compound words with their respective Glyphs. All tests are passing. I 
> have tested this for the Bengali font. Please review these changes and let me 
> know if it makes sense to incorporate these.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4218) image with stencil mask appears interpolated

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4218?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470031#comment-16470031
 ] 

ASF subversion and git services commented on PDFBOX-4218:
-

Commit 1831313 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1831313 ]

PDFBOX-4218: respect the interpolation setting when scaling masked image

> image with stencil mask appears interpolated
> 
>
> Key: PDFBOX-4218
> URL: https://issues.apache.org/jira/browse/PDFBOX-4218
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Assignee: Tilman Hausherr
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: image_via_1.3_006.pdf
>
>
> File is from
> https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/image_via/image_via_1.3_006.pdf
> The color edges of the lower image are interpolated but should not be. 
> Solution: respect the image interpolation setting in 
> {{PDImageXObject.scaleImage()}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Created] (PDFBOX-4218) image with stencil mask appears interpolated

2018-05-10 Thread Tilman Hausherr (JIRA)
Tilman Hausherr created PDFBOX-4218:
---

 Summary: image with stencil mask appears interpolated
 Key: PDFBOX-4218
 URL: https://issues.apache.org/jira/browse/PDFBOX-4218
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 2.0.9
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.10, 3.0.0 PDFBox
 Attachments: image_via_1.3_006.pdf

File is from
https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip
and can be found in 
lumi-read/trunk/PDF_smoketest/pdf/image_via/image_via_1.3_006.pdf

The color edges of the lower image are interpolated but should not be. 
Solution: respect the image interpolation setting in 
{{PDImageXObject.scaleImage()}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4217) Folded Coons patch renders incorrectly

2018-05-10 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-4217:

Description: 
File is from

[https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip]

and can be found in 
lumi-read/trunk/PDF_smoketest/pdf/shade_via/shade_via_1.3_006.pdf

Priority set to minor because this is an unrealistic test image. Every viewer 
(except Adobe Reader) I tried fails in some way.

  was:
File is from

[https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip]

and can be found in 
lumi-read/trunk/PDF_smoketest/pdf/shade_via/shade_via_1.3_006.pdf


> Folded Coons patch renders incorrectly
> --
>
> Key: PDFBOX-4217
> URL: https://issues.apache.org/jira/browse/PDFBOX-4217
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 2.0.9
>Reporter: Tilman Hausherr
>Priority: Minor
>  Labels: Coons, shading, shadingpattern
> Attachments: shade_via_1.3_006.pdf
>
>
> File is from
> [https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/lumi-read/source-archive.zip]
> and can be found in 
> lumi-read/trunk/PDF_smoketest/pdf/shade_via/shade_via_1.3_006.pdf
> Priority set to minor because this is an unrealistic test image. Every viewer 
> (except Adobe Reader) I tried fails in some way.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4068) Create ContentStream for XObject forms and tiling patterns

2018-05-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4068?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16469989#comment-16469989
 ] 

ASF subversion and git services commented on PDFBOX-4068:
-

Commit 1831310 from [~jahewson] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1831310 ]

PDFBOX-4068: don't override "common" functionality - abstract content stream 
must track subsetting

> Create ContentStream for XObject forms and tiling patterns
> --
>
> Key: PDFBOX-4068
> URL: https://issues.apache.org/jira/browse/PDFBOX-4068
> Project: PDFBox
>  Issue Type: Task
>  Components: PDModel
>Reporter: Tilman Hausherr
>Priority: Major
>
> We have a {{PDAppearanceContentStream}} for appearances but nothing for 
> XObject forms and tiling patterns.
> What we need should extend {{PDAbstractContentStream}} and should have a 
> constructor like
> {code:java}
> public PDFormContentStream(PDFormXObject form) throws IOException
> {code}
> Alternatively, why not replace {{PDAppearanceContentStream}} ? Its parameter 
> {{PDAppearanceStream}} is extended from {{PDFormXObject}} so we could just 
> use the base class.
> We need this both for 2.0 and 3.* - we have users who have a really hard time 
> fiddling with low level operators instead of using the methods.
> In 2.0 we could replace the parameter of {{PDPageContentStream}} that is 
> currently {{PDAppearanceStream}}. This would be a non breaking change.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-4068) Create ContentStream for XObject forms and tiling patterns

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4068?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470682#comment-16470682
 ] 

John Hewson edited comment on PDFBOX-4068 at 5/10/18 4:37 PM:
--

Ok, the problems I [mentioned 
above|https://issues.apache.org/jira/browse/PDFBOX-4068?focusedCommentId=16469705]
 are now fixed :)


was (Author: jahewson):
Ok, the problems I [mentioned above|#comment-16469705] are now fixed :)

> Create ContentStream for XObject forms and tiling patterns
> --
>
> Key: PDFBOX-4068
> URL: https://issues.apache.org/jira/browse/PDFBOX-4068
> Project: PDFBox
>  Issue Type: Task
>  Components: PDModel
>Reporter: Tilman Hausherr
>Priority: Major
>
> We have a {{PDAppearanceContentStream}} for appearances but nothing for 
> XObject forms and tiling patterns.
> What we need should extend {{PDAbstractContentStream}} and should have a 
> constructor like
> {code:java}
> public PDFormContentStream(PDFormXObject form) throws IOException
> {code}
> Alternatively, why not replace {{PDAppearanceContentStream}} ? Its parameter 
> {{PDAppearanceStream}} is extended from {{PDFormXObject}} so we could just 
> use the base class.
> We need this both for 2.0 and 3.* - we have users who have a really hard time 
> fiddling with low level operators instead of using the methods.
> In 2.0 we could replace the parameter of {{PDPageContentStream}} that is 
> currently {{PDAppearanceStream}}. This would be a non breaking change.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4068) Create ContentStream for XObject forms and tiling patterns

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4068?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470682#comment-16470682
 ] 

John Hewson commented on PDFBOX-4068:
-

Ok, the problems I [mentioned above|#comment-16469705] are now fixed :)

> Create ContentStream for XObject forms and tiling patterns
> --
>
> Key: PDFBOX-4068
> URL: https://issues.apache.org/jira/browse/PDFBOX-4068
> Project: PDFBox
>  Issue Type: Task
>  Components: PDModel
>Reporter: Tilman Hausherr
>Priority: Major
>
> We have a {{PDAppearanceContentStream}} for appearances but nothing for 
> XObject forms and tiling patterns.
> What we need should extend {{PDAbstractContentStream}} and should have a 
> constructor like
> {code:java}
> public PDFormContentStream(PDFormXObject form) throws IOException
> {code}
> Alternatively, why not replace {{PDAppearanceContentStream}} ? Its parameter 
> {{PDAppearanceStream}} is extended from {{PDFormXObject}} so we could just 
> use the base class.
> We need this both for 2.0 and 3.* - we have users who have a really hard time 
> fiddling with low level operators instead of using the methods.
> In 2.0 we could replace the parameter of {{PDPageContentStream}} that is 
> currently {{PDAppearanceStream}}. This would be a non breaking change.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-4068) Create ContentStream for XObject forms and tiling patterns

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4068?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470682#comment-16470682
 ] 

John Hewson edited comment on PDFBOX-4068 at 5/10/18 4:38 PM:
--

Ok, the problems I [mentioned above|#comment-16469705] are now fixed :)


was (Author: jahewson):
Ok, the problems I [mentioned 
above|https://issues.apache.org/jira/browse/PDFBOX-4068?focusedCommentId=16469705]
 are now fixed :)

> Create ContentStream for XObject forms and tiling patterns
> --
>
> Key: PDFBOX-4068
> URL: https://issues.apache.org/jira/browse/PDFBOX-4068
> Project: PDFBox
>  Issue Type: Task
>  Components: PDModel
>Reporter: Tilman Hausherr
>Priority: Major
>
> We have a {{PDAppearanceContentStream}} for appearances but nothing for 
> XObject forms and tiling patterns.
> What we need should extend {{PDAbstractContentStream}} and should have a 
> constructor like
> {code:java}
> public PDFormContentStream(PDFormXObject form) throws IOException
> {code}
> Alternatively, why not replace {{PDAppearanceContentStream}} ? Its parameter 
> {{PDAppearanceStream}} is extended from {{PDFormXObject}} so we could just 
> use the base class.
> We need this both for 2.0 and 3.* - we have users who have a really hard time 
> fiddling with low level operators instead of using the methods.
> In 2.0 we could replace the parameter of {{PDPageContentStream}} that is 
> currently {{PDAppearanceStream}}. This would be a non breaking change.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Jim Halpert (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jim Halpert updated PDFBOX-4216:

Attachment: test.pdf

> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470731#comment-16470731
 ] 

Tilman Hausherr commented on PDFBOX-4216:
-

Your new file:

{code:java}
/Tx BMC
  q
1 1 66.4 7.36 re
W
n
BT
  /Cour 10 Tf
  /DeviceGray cs
  0 sc
  41.3756 1.87 Td
  (99.55) Tj
ET
  Q
EMC
{code}

My file:
{code:java}
/Tx BMC
  q
1 1 66.4 7.36 re
W
n
BT
  /Cour 10 Tf
  /DeviceGray cs
  0 sc
  36.3951 1.87 Td
  (99.55) Tj
ET
  Q
EMC
{code}

So for some reason, the x-offset is different.


> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470731#comment-16470731
 ] 

Tilman Hausherr edited comment on PDFBOX-4216 at 5/10/18 5:02 PM:
--

Comparing widget 17 (sales tax):

Your new file:

{code:java}
/Tx BMC
  q
1 1 66.4 7.36 re
W
n
BT
  /Cour 10 Tf
  /DeviceGray cs
  0 sc
  41.3756 1.87 Td
  (99.55) Tj
ET
  Q
EMC
{code}

My file:
{code:java}
/Tx BMC
  q
1 1 66.4 7.36 re
W
n
BT
  /Cour 10 Tf
  /DeviceGray cs
  0 sc
  36.3951 1.87 Td
  (99.55) Tj
ET
  Q
EMC
{code}

So for some reason, the x-offset is different.



was (Author: tilman):
Your new file:

{code:java}
/Tx BMC
  q
1 1 66.4 7.36 re
W
n
BT
  /Cour 10 Tf
  /DeviceGray cs
  0 sc
  41.3756 1.87 Td
  (99.55) Tj
ET
  Q
EMC
{code}

My file:
{code:java}
/Tx BMC
  q
1 1 66.4 7.36 re
W
n
BT
  /Cour 10 Tf
  /DeviceGray cs
  0 sc
  36.3951 1.87 Td
  (99.55) Tj
ET
  Q
EMC
{code}

So for some reason, the x-offset is different.


> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Maruan Sahyoun (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470849#comment-16470849
 ] 

Maruan Sahyoun commented on PDFBOX-4216:


Could you run the following code, which prints the field values together with 
the calculated string width:
{code:java}
String formTemplate = "test.pdf";
PDDocument pdfDocument = PDDocument.load(new File(formTemplate));
PDAcroForm acroForm = pdfDocument.getDocumentCatalog().getAcroForm();
PDFont cour = 
acroForm.getDefaultResources().getFont(COSName.getPDFName("Cour"));
List fieldList = acroForm.getFields();
for (PDField pdField : fieldList) {
String fieldValue = pdField.getValueAsString();
System.out.println("value: " + fieldValue + " width: " + 
cour.getStringWidth(fieldValue));
}
pdfDocument.close();
{code}

On my system this prints

{noformat}
value: 64654.33 width: 4800.7812
value: 63.25 width: 3000.4883
value:  width: 0.0
value: 663.44 width: 3600.586
value: TESTPDF ABC width: 6601.074
value: 99.55 width: 3000.4883
value: 56.89 width: 3000.4883
value: TESTPDF width: 4200.6836
value: syf width: 1800.293
value: 895.66 width: 3600.586
value: 55.22 width: 3000.4883
value: 965.36 width: 3600.586
value: 88.56 width: 3000.4883
value: 798.56 width: 3600.586
value: 45465.22 width: 4800.7812
value: 455.66 width: 3600.586
value:  width: 0.0
value:  width: 0.0
value:  width: 0.0
value:  width: 0.0
value:  width: 0.0
value: 4654.56 width: 4200.6836
value: 545.13 width: 3600.586
value: 564.65 width: 3600.586
value: 89.22 width: 3000.4883
value: 56.65 width: 3000.4883
value: 789.45 width: 3600.586
value: 15.645 width: 3600.586
value: 13.456 width: 3600.586
value: 64.454 width: 3600.586
value: 63.56 width: 3000.4883
value: 89.12 width: 3000.4883
value: 63.45 width: 3000.4883
value: 89.15 width: 3000.4883
value: 54.25 width: 3000.4883
{noformat}

> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: 

[jira] [Commented] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Jim Halpert (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470727#comment-16470727
 ] 

Jim Halpert commented on PDFBOX-4216:
-

[~tilman] Here is the PDF generated in Red Hat. [^test.pdf]

[~msahyoun] I used Acrobat Reader in Windows 2018.011.020036 and chrome to view 
the pdf. I also used Linux Mint and Ubuntu to view the pdf. It's same. 

> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470788#comment-16470788
 ] 

Tilman Hausherr commented on PDFBOX-4216:
-

We should trace {{PlainTextFormatter.format()}} to find out what's going on. A 
good start would be to have width and lineWidth. My results are:

lineWidth: 30.004883
width: 64.40001

> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470788#comment-16470788
 ] 

Tilman Hausherr edited comment on PDFBOX-4216 at 5/10/18 5:29 PM:
--

We should trace {{PlainTextFormatter.format()}} to find out what's going on. A 
good start would be to have width and lineWidth. My results (when setting 
amtPaidSalesTax) are:

lineWidth: 30.004883
width: 64.40001


was (Author: tilman):
We should trace {{PlainTextFormatter.format()}} to find out what's going on. A 
good start would be to have width and lineWidth. My results are:

lineWidth: 30.004883
width: 64.40001

> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4216) PDFBox decimal value cutting off in Red Hat Enterprise 7.4

2018-05-10 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470846#comment-16470846
 ] 

Tilman Hausherr commented on PDFBOX-4216:
-

Another idea - maybe the courier font or its replacements is missing.
Please go to your user directory in that redhat system, and open the file 
.pdfbox.cache, and post all lines that include courier, liberation, and 
nimbusmon. Make the search case insensitive. Include all lines that have the 
string, i.e. also "CourierNew". Or just post the whole file.

> PDFBox decimal value cutting off in Red Hat Enterprise 7.4
> --
>
> Key: PDFBOX-4216
> URL: https://issues.apache.org/jira/browse/PDFBOX-4216
> Project: PDFBox
>  Issue Type: Bug
>  Components: AcroForm
>Affects Versions: 2.0.9
> Environment: LINUX
>Reporter: Jim Halpert
>Priority: Major
> Attachments: Capture.PNG, pdfbox_issue.PNG, 
> pdfbox_linux_issue-saved-AR.pdf, pdfbox_linux_issue-saved.pdf, 
> pdfbox_linux_issue.pdf, test.pdf
>
>
> Facing issue with Pdf decimal value mapping in the pdffiled in LINUX 
> environment, right side decimal values are cutting off, appreciate quick help 
> on this.
> {code:java}
>  PDDocument pdfDoc = PDDocument.load(new File("pdfbox_linux_issue.pdf"));
> PDDocumentCatalog docCatalog = pdfDoc.getDocumentCatalog();
> PDAcroForm acroForm = docCatalog.getAcroForm();
> Map m = new HashMap();
> m.put("amtPaidForUnit", "15,999.23");
> m.put("amtPubFreightFees", "22.55");
> m.put("amtPaidTotAccessories", "45612.12");
> m.put("dealerDocPrepFees", "55.22");
> m.put("amtDownTradeTotal", "56.89");
> m.put("amtPaidSalesTax", "99.55");
> m.put("amtSerContractTo", "895.66");
> m.put("amtSerContractAmt", "965.36");
> m.put("amtGapProtTo", "798.56");
> m.put("amtGapProtAmt", "64654.33");
> m.put("amtTireGuardTo", "45465.22");
> m.put("amtTireGuardAmt", "455.66");
> m.put("amtPaidOptExtWarr", "88.56");
> m.put("amtPaidOptExtWarrAmt", "663.44");
> m.put("amtPubTitleFees", "54.25");
> m.put("amtPubLicFees", "4654.56");
> m.put("amtPubRegFees", "545.13");
> m.put("amtPubLienFees", "89.22");
> m.put("amtPubFilingFees", "564.65");
> m.put("amtPubStampFees", "56.65");
> m.put("amtPubToAmt", "789.45");
> m.put("amtPubTo2Amt", "15.645");
> m.put("subtotalOfSectionsABC", "13.456");
> m.put("amtLenderOrigFeesAmt", "64.454");
> m.put("amtLender1FeesAmt", "63.56");
> m.put("subtotalOfSection2", "89.12");
> m.put("subtotalOfSection3", "63.45");
> m.put("subtotalOfSection4", "89.15");
> m.put("discAmtFinanced", "63.25");
> for (Object fieldObj : acroForm.getFields())
> {
> PDField field = (PDField) fieldObj;
> if (m.get(field.getFullyQualifiedName()) != null) // set value of 
> map when map key and pdf key is matched 
> {
> 
> field.setValue(m.get(field.getFullyQualifiedName()).toString());
> }
> }
> 
> pdfDoc.save(new File("pdfbox_linux_issue-saved.pdf"));
> {code}
> Works in Windows, Linux Mint, Ubuntu as expected. Issue is only with Red Hat 
> Enterprise 7.4.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4184) [PATCH]: Support simple lossless compression of 16 bit RGB images

2018-05-10 Thread Emmeran Seehuber (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4184?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Emmeran Seehuber updated PDFBOX-4184:
-
Attachment: lossless_predictor_based_imageencoding.patch

> [PATCH]: Support simple lossless compression of 16 bit RGB images
> -
>
> Key: PDFBOX-4184
> URL: https://issues.apache.org/jira/browse/PDFBOX-4184
> Project: PDFBox
>  Issue Type: Improvement
>  Components: Writing
>Affects Versions: 2.0.9
>Reporter: Emmeran Seehuber
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: lossless_predictor_based_imageencoding.patch, 
> pdfbox_support_16bit_image_write.patch, png16-arrow-bad-no-smask.pdf, 
> png16-arrow-bad.pdf, png16-arrow-good-no-mask.pdf, png16-arrow-good.pdf
>
>
> The attached patch add support to write 16 bit per component images 
> correctly. I've integrated a test for this here: 
> [https://github.com/rototor/pdfbox-graphics2d/commit/8bf089cb74945bd4f0f15054754f51dd5b361fe9]
> It only supports 16-Bit TYPE_CUSTOM with DataType == USHORT images - but this 
> is what you usually get when you read a 16 bit PNG file.
> This would also fix [https://github.com/danfickle/openhtmltopdf/issues/173].
> The patch is against 2.0.9, but should apply to 3.0.0 too.
> There is still some room for improvements when writing lossless images, as 
> the images are currently not efficiently encoded. I.e. you could use PNG 
> encodings to get a better compression. (By adding a COSName.DECODE_PARMS with 
> a COSName.PREDICTOR == 15 and encoding the images as PNG). But this is 
> something for a later patch. It would also need another API, as there is a 
> tradeoff speed vs compression ratio. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4184) [PATCH]: Support simple lossless compression of 16 bit RGB images

2018-05-10 Thread Emmeran Seehuber (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4184?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16470976#comment-16470976
 ] 

Emmeran Seehuber commented on PDFBOX-4184:
--

As the topic image encoding comes up again in OpenHTMLToPDF (see 
[https://github.com/danfickle/openhtmltopdf/issues/212)] I reworked my 16 bit 
predictor based encoding I had laying around and extended it to support most 
BufferedImage formats and CMYK images. I originally did this for using with 
iText some time ago. See [^lossless_predictor_based_imageencoding.patch]

It implements image encoding with a PNG predictor. Depending on the image to 
encoding this results in massive space savings compared to simple image 
encoding without a predictor. Also image with extended color profiles work. 

To test the CMYK support I need a CMYK profile. Any one would do. For a quick 
test I used a profile from here:  
[http://download.adobe.com/pub/adobe/iccprofiles/win/AdobeICCProfiles.zip]

I have no idea if we are allowed to include this profile in the test resources. 
It's missing in the patch, you must copy it from the download archive. I think 
we might also be allowed to use a profile from 
[http://www.eci.org/en/downloads]. But they did not publish any license 
information :(

I did not do any performance tests yet, but the predictor encoding should be 
faster then the existing encoding, as it tries to be more friendly to the cache 
(e.g. writing a row directly into a zip stream).

Please review this patch. Do I need to sign a CLA?

> [PATCH]: Support simple lossless compression of 16 bit RGB images
> -
>
> Key: PDFBOX-4184
> URL: https://issues.apache.org/jira/browse/PDFBOX-4184
> Project: PDFBox
>  Issue Type: Improvement
>  Components: Writing
>Affects Versions: 2.0.9
>Reporter: Emmeran Seehuber
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: lossless_predictor_based_imageencoding.patch, 
> pdfbox_support_16bit_image_write.patch, png16-arrow-bad-no-smask.pdf, 
> png16-arrow-bad.pdf, png16-arrow-good-no-mask.pdf, png16-arrow-good.pdf
>
>
> The attached patch add support to write 16 bit per component images 
> correctly. I've integrated a test for this here: 
> [https://github.com/rototor/pdfbox-graphics2d/commit/8bf089cb74945bd4f0f15054754f51dd5b361fe9]
> It only supports 16-Bit TYPE_CUSTOM with DataType == USHORT images - but this 
> is what you usually get when you read a 16 bit PNG file.
> This would also fix [https://github.com/danfickle/openhtmltopdf/issues/173].
> The patch is against 2.0.9, but should apply to 3.0.0 too.
> There is still some room for improvements when writing lossless images, as 
> the images are currently not efficiently encoded. I.e. you could use PNG 
> encodings to get a better compression. (By adding a COSName.DECODE_PARMS with 
> a COSName.PREDICTOR == 15 and encoding the images as PNG). But this is 
> something for a later patch. It would also need another API, as there is a 
> tradeoff speed vs compression ratio. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4106) Vertical text creation

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471291#comment-16471291
 ] 

John Hewson commented on PDFBOX-4106:
-

(!) So we have a problem. While looking at building a proper ToUnicodeMap for 
PDFBOX-4189 I've encountered some significant issues related to this feature. 
Given that this was shipped in 2.0.9, we're likely going to face some hard 
choices.

Most of the handling of vertical text in this patch is fine. It generally does 
a good job of handling the intricacies of both PDF and OpenType and juggling 
the sometimes competing concerns.

The issue is that the new APIs added to FontBox's TrueTypeFont are incompatible 
with PDFBox's multi-threading. Unlike most of PDFBox, fonts in FontBox must be 
thread safe - they are cached and shared globally between all PDDocument 
instances. For this reason a FontBoxFont must not contain any document-specific 
state.

The following fields added to TrueTypeFont contain document-specific state:

{{List enabledGsubFeatures}}

The following methods added to TrueTypeFont write document-specific state:

{{enableVerticalSubstitutions()}}
 {{enableGsubFeature(String)}}
 {{disableGsubFeature(String)}}

The following methods added to TrueTypeFont read document-specific state:

{{getUnicodeCmapLookup()}}
 {{getUnicodeCmapLookup(boolean)}}

None of the additions are thread safe, anyone who calls these methods will 
clobber the corresponding state for all other threads. This problem can even 
occur if the user is manipulating more than one document with even just one 
thread. *There's no way around this and no way to fix these methods* - 
document-specific state can't live in shared global fonts :(

(flag) Tough choices: Given that these are all just auxiliary methods limited 
to just FontBox's TrueTypeFont class, we _could_ remove them. These are very 
obscure methods which have only been around for a few weeks. It's unlikely that 
_any_ users would be affected by their removal. Obviously the missing 
functionality will be implemented in the appropriate location, so vertical text 
will still work in 2.0 and the existing PDTyoe0Font.loadVertical API - which is 
the only thing that matters - will remain unchanged! :)

Yes, I'm suggesting a *very obscure* breaking API change to 2.0 but as it 
stands we have just shipped a breaking functionality change to 2.0 and broken 
existing functionality in an irreparable manner, and that seems worse. Thoughts?

> Vertical text creation
> --
>
> Key: PDFBOX-4106
> URL: https://issues.apache.org/jira/browse/PDFBOX-4106
> Project: PDFBox
>  Issue Type: New Feature
>  Components: FontBox, Parsing, Writing
>Reporter: Aaron Madlon-Kay
>Assignee: Tilman Hausherr
>Priority: Major
>  Labels: embed, gsub, parsing, vertical
> Fix For: 2.0.9, 3.0.0 PDFBox
>
> Attachments: 
> 0001-Add-OpenTypeScript-class-to-get-OT-script-tags-for-c.patch, 
> 0002-Optimize-Unicode-script-storage-and-lookup.patch, 
> 0003-Parse-GSUB-table.patch, 
> 0004-Abstract-cmap-lookup-into-an-interface.patch, 
> 0005-Implement-GSUB-substitution-on-TrueTypeFont.patch, 
> 0006-Use-vhea-vmtx-to-fix-vertical-displacements-in-PCIDF.patch, 
> 0007-Add-factory-methods-for-loading-TTF-as-vertical-font.patch, 
> 0008-Implement-vertical-metrics-support-when-embedding-subsetting.patch, 
> FIX-0001-PDFBOX-4106-Remove-early-outs-leading-to-spurious-wa.patch, 
> FIX-0002-PDFBOX-4106-Document-GlyphSubstitutionTable-public-m.patch, 
> FIX-0003-PDFBOX-4106-Correct-deltaGlyphID-data-size.patch, 
> FIX-0004-PDFBOX-4106-Remove-unnecessary-vertical-displacement.patch, 
> FIX-0005-PDFBOX-4106-Remove-duplicate-DW2-creation.patch, 
> FIX-0006-PDFBOX-4106-Fix-non-embedded-vertical-font-rendering.patch, 
> FIX-0007-PDFBOX-4106-Fix-incorrect-parsing-of-W2-first-format.patch, 
> FIX-0008-PDFBOX-4106-Rename-misleading-field.patch, 
> FIX-0009-PDFBOX-4106-Allow-retrieving-vmtx-topSideBearing.patch, 
> FIX-0010-PDFBOX-4106-Correct-vmtx-embedding-for-proportional-.patch, 
> sample_code.txt, vertical.pdf
>
>
> I needed to output vertical Japanese text, but was stymied by several 
> limitations:
> * No API to load a TTF as Identity-V encoding
> * No support for 'vert' glyph substitution
> * No support for vertical metrics ('vhea' and 'vmtx' tables are parsed but 
> not used at all)
> I have attached a series of patches that implement the above features. 
> Highlights:
> * The GSUB glyph substitution table is parsed (limitation: type 1 lookups 
> only; this is sufficient for many features including 'vert'/'vrt2' vertical 
> glyph substitution)
> * Cmap lookup makes use of GSUB when features are enabled on a TTF
> * 'vhea' and 'vmtx' metrics are applied to PDCIDFont when appropriate, and 
> are embedded/subsetted correctly through the DW2/W2 

[jira] [Updated] (PDFBOX-4106) Vertical text creation

2018-05-10 Thread John Hewson (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

John Hewson updated PDFBOX-4106:

Issue Type: Bug  (was: New Feature)

> Vertical text creation
> --
>
> Key: PDFBOX-4106
> URL: https://issues.apache.org/jira/browse/PDFBOX-4106
> Project: PDFBox
>  Issue Type: Bug
>  Components: FontBox, Parsing, Writing
>Reporter: Aaron Madlon-Kay
>Assignee: Tilman Hausherr
>Priority: Major
>  Labels: embed, gsub, parsing, vertical
> Fix For: 2.0.9, 3.0.0 PDFBox
>
> Attachments: 
> 0001-Add-OpenTypeScript-class-to-get-OT-script-tags-for-c.patch, 
> 0002-Optimize-Unicode-script-storage-and-lookup.patch, 
> 0003-Parse-GSUB-table.patch, 
> 0004-Abstract-cmap-lookup-into-an-interface.patch, 
> 0005-Implement-GSUB-substitution-on-TrueTypeFont.patch, 
> 0006-Use-vhea-vmtx-to-fix-vertical-displacements-in-PCIDF.patch, 
> 0007-Add-factory-methods-for-loading-TTF-as-vertical-font.patch, 
> 0008-Implement-vertical-metrics-support-when-embedding-subsetting.patch, 
> FIX-0001-PDFBOX-4106-Remove-early-outs-leading-to-spurious-wa.patch, 
> FIX-0002-PDFBOX-4106-Document-GlyphSubstitutionTable-public-m.patch, 
> FIX-0003-PDFBOX-4106-Correct-deltaGlyphID-data-size.patch, 
> FIX-0004-PDFBOX-4106-Remove-unnecessary-vertical-displacement.patch, 
> FIX-0005-PDFBOX-4106-Remove-duplicate-DW2-creation.patch, 
> FIX-0006-PDFBOX-4106-Fix-non-embedded-vertical-font-rendering.patch, 
> FIX-0007-PDFBOX-4106-Fix-incorrect-parsing-of-W2-first-format.patch, 
> FIX-0008-PDFBOX-4106-Rename-misleading-field.patch, 
> FIX-0009-PDFBOX-4106-Allow-retrieving-vmtx-topSideBearing.patch, 
> FIX-0010-PDFBOX-4106-Correct-vmtx-embedding-for-proportional-.patch, 
> sample_code.txt, vertical.pdf
>
>
> I needed to output vertical Japanese text, but was stymied by several 
> limitations:
> * No API to load a TTF as Identity-V encoding
> * No support for 'vert' glyph substitution
> * No support for vertical metrics ('vhea' and 'vmtx' tables are parsed but 
> not used at all)
> I have attached a series of patches that implement the above features. 
> Highlights:
> * The GSUB glyph substitution table is parsed (limitation: type 1 lookups 
> only; this is sufficient for many features including 'vert'/'vrt2' vertical 
> glyph substitution)
> * Cmap lookup makes use of GSUB when features are enabled on a TTF
> * 'vhea' and 'vmtx' metrics are applied to PDCIDFont when appropriate, and 
> are embedded/subsetted correctly through the DW2/W2 CIDFont dictionary
> * An API has been added for loading a TTF as a vertical font, setting 
> Identity-V encoding and enabling 'vert'/'vrt2' substitution
> Each patch could approximately be split out into a separate ticket, if 
> desired.
> Also attached is some sample code that exercises these patches and 
> illustrates the effect of vertical glyph positioning. The sample output PDF 
> is also attached.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Reopened] (PDFBOX-4106) Vertical text creation

2018-05-10 Thread John Hewson (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

John Hewson reopened PDFBOX-4106:
-

> Vertical text creation
> --
>
> Key: PDFBOX-4106
> URL: https://issues.apache.org/jira/browse/PDFBOX-4106
> Project: PDFBox
>  Issue Type: New Feature
>  Components: FontBox, Parsing, Writing
>Reporter: Aaron Madlon-Kay
>Assignee: Tilman Hausherr
>Priority: Major
>  Labels: embed, gsub, parsing, vertical
> Fix For: 2.0.9, 3.0.0 PDFBox
>
> Attachments: 
> 0001-Add-OpenTypeScript-class-to-get-OT-script-tags-for-c.patch, 
> 0002-Optimize-Unicode-script-storage-and-lookup.patch, 
> 0003-Parse-GSUB-table.patch, 
> 0004-Abstract-cmap-lookup-into-an-interface.patch, 
> 0005-Implement-GSUB-substitution-on-TrueTypeFont.patch, 
> 0006-Use-vhea-vmtx-to-fix-vertical-displacements-in-PCIDF.patch, 
> 0007-Add-factory-methods-for-loading-TTF-as-vertical-font.patch, 
> 0008-Implement-vertical-metrics-support-when-embedding-subsetting.patch, 
> FIX-0001-PDFBOX-4106-Remove-early-outs-leading-to-spurious-wa.patch, 
> FIX-0002-PDFBOX-4106-Document-GlyphSubstitutionTable-public-m.patch, 
> FIX-0003-PDFBOX-4106-Correct-deltaGlyphID-data-size.patch, 
> FIX-0004-PDFBOX-4106-Remove-unnecessary-vertical-displacement.patch, 
> FIX-0005-PDFBOX-4106-Remove-duplicate-DW2-creation.patch, 
> FIX-0006-PDFBOX-4106-Fix-non-embedded-vertical-font-rendering.patch, 
> FIX-0007-PDFBOX-4106-Fix-incorrect-parsing-of-W2-first-format.patch, 
> FIX-0008-PDFBOX-4106-Rename-misleading-field.patch, 
> FIX-0009-PDFBOX-4106-Allow-retrieving-vmtx-topSideBearing.patch, 
> FIX-0010-PDFBOX-4106-Correct-vmtx-embedding-for-proportional-.patch, 
> sample_code.txt, vertical.pdf
>
>
> I needed to output vertical Japanese text, but was stymied by several 
> limitations:
> * No API to load a TTF as Identity-V encoding
> * No support for 'vert' glyph substitution
> * No support for vertical metrics ('vhea' and 'vmtx' tables are parsed but 
> not used at all)
> I have attached a series of patches that implement the above features. 
> Highlights:
> * The GSUB glyph substitution table is parsed (limitation: type 1 lookups 
> only; this is sufficient for many features including 'vert'/'vrt2' vertical 
> glyph substitution)
> * Cmap lookup makes use of GSUB when features are enabled on a TTF
> * 'vhea' and 'vmtx' metrics are applied to PDCIDFont when appropriate, and 
> are embedded/subsetted correctly through the DW2/W2 CIDFont dictionary
> * An API has been added for loading a TTF as a vertical font, setting 
> Identity-V encoding and enabling 'vert'/'vrt2' substitution
> Each patch could approximately be split out into a separate ticket, if 
> desired.
> Also attached is some sample code that exercises these patches and 
> illustrates the effect of vertical glyph positioning. The sample output PDF 
> is also attached.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4189) Enable PDF creation with Indian languages, by reading and utilizing the GSUB table

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471296#comment-16471296
 ] 

John Hewson commented on PDFBOX-4189:
-

I'm trying to ToUnicodeMap generation working properly but have hit problems 
introduced by PDFBOX-4106. We'll have to resolve that before I can proceed here.

> Enable PDF creation with Indian languages, by reading and utilizing the GSUB 
> table
> --
>
> Key: PDFBOX-4189
> URL: https://issues.apache.org/jira/browse/PDFBOX-4189
> Project: PDFBox
>  Issue Type: New Feature
>  Components: FontBox, PDModel
>Reporter: Palash Ray
>Priority: Major
> Attachments: Bengali-text-after.pdf, Bengali-text-before.pdf, 
> BengaliPdfGenerationHelloWorld.java, bengali-example.pdf, 
> bengali-example2.pdf, bengali-example3.pdf, committed.patch, screenshot.png
>
>   Original Estimate: 336h
>  Remaining Estimate: 336h
>
> Implemented proper rendering of Indian languages, which need extensive Glyph 
> substitution. The GSUB table has been read and used effectively to replace 
> some compound words with their respective Glyphs. All tests are passing. I 
> have tested this for the Bengali font. Please review these changes and let me 
> know if it makes sense to incorporate these.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-4189) Enable PDF creation with Indian languages, by reading and utilizing the GSUB table

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471296#comment-16471296
 ] 

John Hewson edited comment on PDFBOX-4189 at 5/10/18 11:56 PM:
---

I'm trying to get ToUnicodeMap generation working properly with GSUB but have 
hit problems introduced by PDFBOX-4106. We'll have to resolve that before I can 
proceed here.


was (Author: jahewson):
I'm trying to ToUnicodeMap generation working properly but have hit problems 
introduced by PDFBOX-4106. We'll have to resolve that before I can proceed here.

> Enable PDF creation with Indian languages, by reading and utilizing the GSUB 
> table
> --
>
> Key: PDFBOX-4189
> URL: https://issues.apache.org/jira/browse/PDFBOX-4189
> Project: PDFBox
>  Issue Type: New Feature
>  Components: FontBox, PDModel
>Reporter: Palash Ray
>Priority: Major
> Attachments: Bengali-text-after.pdf, Bengali-text-before.pdf, 
> BengaliPdfGenerationHelloWorld.java, bengali-example.pdf, 
> bengali-example2.pdf, bengali-example3.pdf, committed.patch, screenshot.png
>
>   Original Estimate: 336h
>  Remaining Estimate: 336h
>
> Implemented proper rendering of Indian languages, which need extensive Glyph 
> substitution. The GSUB table has been read and used effectively to replace 
> some compound words with their respective Glyphs. All tests are passing. I 
> have tested this for the Bengali font. Please review these changes and let me 
> know if it makes sense to incorporate these.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-4106) Vertical text creation

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471291#comment-16471291
 ] 

John Hewson edited comment on PDFBOX-4106 at 5/11/18 12:00 AM:
---

(!) So we have a problem. While looking at building a proper ToUnicodeMap for 
PDFBOX-4189 I've encountered some significant issues related to this feature. 
Given that this was shipped in 2.0.9, we're likely going to face some hard 
choices.

Most of the handling of vertical text in this patch is fine. It generally does 
a good job of handling the intricacies of both PDF and OpenType and juggling 
the sometimes competing concerns.

The issue is that the new APIs added to FontBox's TrueTypeFont are incompatible 
with PDFBox's multi-threading. Unlike most of PDFBox, fonts in FontBox must be 
thread safe - they are cached and shared globally between all PDDocument 
instances. For this reason a FontBoxFont must not contain any document-specific 
state.

The following fields added to TrueTypeFont contain document-specific state:

{{List enabledGsubFeatures}}

The following methods added to TrueTypeFont write document-specific state:

{{enableVerticalSubstitutions()}}
 {{enableGsubFeature(String)}}
 {{disableGsubFeature(String)}}

The following methods added to TrueTypeFont read document-specific state:

{{getUnicodeCmapLookup()}}
 {{getUnicodeCmapLookup(boolean)}}

None of the additions are thread safe, anyone who calls these methods will 
clobber the corresponding state for all other threads. This problem can even 
occur if the user is manipulating more than one document within a single 
thread. *There's no way around this and no way to fix these methods* - 
document-specific state can't live in shared global fonts :(

(flag) Tough choices: Given that these are all just auxiliary methods limited 
to just FontBox's TrueTypeFont class, we _could_ remove them. These are very 
obscure methods which have only been around for a few weeks. It's unlikely that 
_any_ users would be affected by their removal. Obviously the missing 
functionality will be implemented in the appropriate location, so vertical text 
will still work in 2.0 and the existing PDType0Font.loadVertical API - which is 
the only thing that matters - will remain unchanged! :)

Yes, I'm suggesting a *very obscure* breaking API change to 2.0 but as it 
stands we have just shipped a breaking functionality change to 2.0 and broken 
existing functionality in an irreparable manner, and that seems worse. Thoughts?


was (Author: jahewson):
(!) So we have a problem. While looking at building a proper ToUnicodeMap for 
PDFBOX-4189 I've encountered some significant issues related to this feature. 
Given that this was shipped in 2.0.9, we're likely going to face some hard 
choices.

Most of the handling of vertical text in this patch is fine. It generally does 
a good job of handling the intricacies of both PDF and OpenType and juggling 
the sometimes competing concerns.

The issue is that the new APIs added to FontBox's TrueTypeFont are incompatible 
with PDFBox's multi-threading. Unlike most of PDFBox, fonts in FontBox must be 
thread safe - they are cached and shared globally between all PDDocument 
instances. For this reason a FontBoxFont must not contain any document-specific 
state.

The following fields added to TrueTypeFont contain document-specific state:

{{List enabledGsubFeatures}}

The following methods added to TrueTypeFont write document-specific state:

{{enableVerticalSubstitutions()}}
 {{enableGsubFeature(String)}}
 {{disableGsubFeature(String)}}

The following methods added to TrueTypeFont read document-specific state:

{{getUnicodeCmapLookup()}}
 {{getUnicodeCmapLookup(boolean)}}

None of the additions are thread safe, anyone who calls these methods will 
clobber the corresponding state for all other threads. This problem can even 
occur if the user is manipulating more than one document with even just one 
thread. *There's no way around this and no way to fix these methods* - 
document-specific state can't live in shared global fonts :(

(flag) Tough choices: Given that these are all just auxiliary methods limited 
to just FontBox's TrueTypeFont class, we _could_ remove them. These are very 
obscure methods which have only been around for a few weeks. It's unlikely that 
_any_ users would be affected by their removal. Obviously the missing 
functionality will be implemented in the appropriate location, so vertical text 
will still work in 2.0 and the existing PDTyoe0Font.loadVertical API - which is 
the only thing that matters - will remain unchanged! :)

Yes, I'm suggesting a *very obscure* breaking API change to 2.0 but as it 
stands we have just shipped a breaking functionality change to 2.0 and broken 
existing functionality in an irreparable manner, and that seems worse. Thoughts?

> Vertical text creation
> --
>
> 

[jira] [Comment Edited] (PDFBOX-4106) Vertical text creation

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471291#comment-16471291
 ] 

John Hewson edited comment on PDFBOX-4106 at 5/11/18 12:02 AM:
---

(!) So we have a problem. While looking at building a proper ToUnicodeMap for 
PDFBOX-4189 I've encountered some significant issues related to this feature. 
Given that this was shipped in 2.0.9, we're likely going to face some hard 
choices.

Most of the handling of vertical text in this patch is fine. It generally does 
a good job of handling the intricacies of both PDF and OpenType and juggling 
the sometimes competing concerns.

The issue is that the new APIs added to FontBox's TrueTypeFont are incompatible 
with PDFBox's multi-threading. Unlike most of PDFBox, fonts in FontBox must be 
thread safe - they are cached and shared globally between all PDDocument 
instances. For this reason a FontBoxFont must not contain any document-specific 
state.

The following fields added to TrueTypeFont contain document-specific state:

{{List enabledGsubFeatures}}

The following methods added to TrueTypeFont write document-specific state:

{{enableVerticalSubstitutions()}}
 {{enableGsubFeature(String)}}
 {{disableGsubFeature(String)}}

The following methods added to TrueTypeFont read document-specific state:

{{getUnicodeCmapLookup()}}
 {{getUnicodeCmapLookup(boolean)}}

None of the additions are thread safe, anyone who calls these methods will 
clobber the corresponding state for all other threads. This problem can even 
occur if the user is manipulating more than one document within a single 
thread. *There's no way around this and no way to fix these methods* - 
document-specific state can't live in shared global fonts :(

(flag) Tough choices: Given that these are all just auxiliary methods limited 
to just FontBox's TrueTypeFont class, we _could_ remove them. These are very 
obscure methods which have only been around for a few weeks. It's unlikely that 
_any_ users would be affected by their removal. Obviously the missing 
functionality will be implemented in the appropriate location*, so vertical 
text will still work in 2.0 and the existing PDType0Font.loadVertical API - 
which is the only thing that matters - will remain unchanged! :)

Yes, I'm suggesting a *very obscure* breaking API change to 2.0 but as it 
stands we have just shipped a breaking functionality change to 2.0 and broken 
existing functionality in an irreparable manner, and that seems worse. Thoughts?

* = And I have some ideas how to achieve this and am happy to do it


was (Author: jahewson):
(!) So we have a problem. While looking at building a proper ToUnicodeMap for 
PDFBOX-4189 I've encountered some significant issues related to this feature. 
Given that this was shipped in 2.0.9, we're likely going to face some hard 
choices.

Most of the handling of vertical text in this patch is fine. It generally does 
a good job of handling the intricacies of both PDF and OpenType and juggling 
the sometimes competing concerns.

The issue is that the new APIs added to FontBox's TrueTypeFont are incompatible 
with PDFBox's multi-threading. Unlike most of PDFBox, fonts in FontBox must be 
thread safe - they are cached and shared globally between all PDDocument 
instances. For this reason a FontBoxFont must not contain any document-specific 
state.

The following fields added to TrueTypeFont contain document-specific state:

{{List enabledGsubFeatures}}

The following methods added to TrueTypeFont write document-specific state:

{{enableVerticalSubstitutions()}}
 {{enableGsubFeature(String)}}
 {{disableGsubFeature(String)}}

The following methods added to TrueTypeFont read document-specific state:

{{getUnicodeCmapLookup()}}
 {{getUnicodeCmapLookup(boolean)}}

None of the additions are thread safe, anyone who calls these methods will 
clobber the corresponding state for all other threads. This problem can even 
occur if the user is manipulating more than one document within a single 
thread. *There's no way around this and no way to fix these methods* - 
document-specific state can't live in shared global fonts :(

(flag) Tough choices: Given that these are all just auxiliary methods limited 
to just FontBox's TrueTypeFont class, we _could_ remove them. These are very 
obscure methods which have only been around for a few weeks. It's unlikely that 
_any_ users would be affected by their removal. Obviously the missing 
functionality will be implemented in the appropriate location, so vertical text 
will still work in 2.0 and the existing PDType0Font.loadVertical API - which is 
the only thing that matters - will remain unchanged! :)

Yes, I'm suggesting a *very obscure* breaking API change to 2.0 but as it 
stands we have just shipped a breaking functionality change to 2.0 and broken 
existing functionality in an irreparable manner, and that seems worse. Thoughts?

> 

[jira] [Comment Edited] (PDFBOX-4106) Vertical text creation

2018-05-10 Thread John Hewson (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471291#comment-16471291
 ] 

John Hewson edited comment on PDFBOX-4106 at 5/11/18 12:02 AM:
---

(!) So we have a problem. While looking at building a proper ToUnicodeMap for 
PDFBOX-4189 I've encountered some significant issues related to this feature. 
Given that this was shipped in 2.0.9, we're likely going to face some hard 
choices.

Most of the handling of vertical text in this patch is fine. It generally does 
a good job of handling the intricacies of both PDF and OpenType and juggling 
the sometimes competing concerns.

The issue is that the new APIs added to FontBox's TrueTypeFont are incompatible 
with PDFBox's multi-threading. Unlike most of PDFBox, fonts in FontBox must be 
thread safe - they are cached and shared globally between all PDDocument 
instances. For this reason a FontBoxFont must not contain any document-specific 
state.

The following fields added to TrueTypeFont contain document-specific state:

{{List enabledGsubFeatures}}

The following methods added to TrueTypeFont write document-specific state:

{{enableVerticalSubstitutions()}}
 {{enableGsubFeature(String)}}
 {{disableGsubFeature(String)}}

The following methods added to TrueTypeFont read document-specific state:

{{getUnicodeCmapLookup()}}
 {{getUnicodeCmapLookup(boolean)}}

None of the additions are thread safe, anyone who calls these methods will 
clobber the corresponding state for all other threads. This problem can even 
occur if the user is manipulating more than one document within a single 
thread. *There's no way around this and no way to fix these methods* - 
document-specific state can't live in shared global fonts :(

(flag) Tough choices: Given that these are all just auxiliary methods limited 
to just FontBox's TrueTypeFont class, we _could_ remove them. These are very 
obscure methods which have only been around for a few weeks. It's unlikely that 
_any_ users would be affected by their removal. Obviously the missing 
functionality will be implemented in the appropriate location*, so vertical 
text will still work in 2.0 and the existing PDType0Font.loadVertical API - 
which is the only thing that matters - will remain unchanged! :)

Yes, I'm suggesting a *very obscure* breaking API change to 2.0 but as it 
stands we have just shipped a breaking functionality change to 2.0 and broken 
existing functionality in an irreparable manner, and that seems worse. Thoughts?

\* And I have some ideas how to achieve this and am happy to do it


was (Author: jahewson):
(!) So we have a problem. While looking at building a proper ToUnicodeMap for 
PDFBOX-4189 I've encountered some significant issues related to this feature. 
Given that this was shipped in 2.0.9, we're likely going to face some hard 
choices.

Most of the handling of vertical text in this patch is fine. It generally does 
a good job of handling the intricacies of both PDF and OpenType and juggling 
the sometimes competing concerns.

The issue is that the new APIs added to FontBox's TrueTypeFont are incompatible 
with PDFBox's multi-threading. Unlike most of PDFBox, fonts in FontBox must be 
thread safe - they are cached and shared globally between all PDDocument 
instances. For this reason a FontBoxFont must not contain any document-specific 
state.

The following fields added to TrueTypeFont contain document-specific state:

{{List enabledGsubFeatures}}

The following methods added to TrueTypeFont write document-specific state:

{{enableVerticalSubstitutions()}}
 {{enableGsubFeature(String)}}
 {{disableGsubFeature(String)}}

The following methods added to TrueTypeFont read document-specific state:

{{getUnicodeCmapLookup()}}
 {{getUnicodeCmapLookup(boolean)}}

None of the additions are thread safe, anyone who calls these methods will 
clobber the corresponding state for all other threads. This problem can even 
occur if the user is manipulating more than one document within a single 
thread. *There's no way around this and no way to fix these methods* - 
document-specific state can't live in shared global fonts :(

(flag) Tough choices: Given that these are all just auxiliary methods limited 
to just FontBox's TrueTypeFont class, we _could_ remove them. These are very 
obscure methods which have only been around for a few weeks. It's unlikely that 
_any_ users would be affected by their removal. Obviously the missing 
functionality will be implemented in the appropriate location*, so vertical 
text will still work in 2.0 and the existing PDType0Font.loadVertical API - 
which is the only thing that matters - will remain unchanged! :)

Yes, I'm suggesting a *very obscure* breaking API change to 2.0 but as it 
stands we have just shipped a breaking functionality change to 2.0 and broken 
existing functionality in an irreparable manner, and that seems worse. Thoughts?

* = 

[jira] [Commented] (PDFBOX-4106) Vertical text creation

2018-05-10 Thread Aaron Madlon-Kay (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471307#comment-16471307
 ] 

Aaron Madlon-Kay commented on PDFBOX-4106:
--

Hi John. Thanks for raising these concerns, and sorry for having gotten us into 
this mess.

I am fine with any API changes deemed necessary. As for functionality, the only 
non-obvious thing that I want to mention is that it's important to be able to 
selectively enable/disable {{vrt2}}. The reason is that the substitutions 
performed by {{vrt2}} are not always more desirable than {{vert}}, and it is 
common to want to use only {{vert}} substitutions with a font that supports 
both.

> Vertical text creation
> --
>
> Key: PDFBOX-4106
> URL: https://issues.apache.org/jira/browse/PDFBOX-4106
> Project: PDFBox
>  Issue Type: Bug
>  Components: FontBox, Parsing, Writing
>Reporter: Aaron Madlon-Kay
>Assignee: Tilman Hausherr
>Priority: Major
>  Labels: embed, gsub, parsing, vertical
> Fix For: 2.0.9, 3.0.0 PDFBox
>
> Attachments: 
> 0001-Add-OpenTypeScript-class-to-get-OT-script-tags-for-c.patch, 
> 0002-Optimize-Unicode-script-storage-and-lookup.patch, 
> 0003-Parse-GSUB-table.patch, 
> 0004-Abstract-cmap-lookup-into-an-interface.patch, 
> 0005-Implement-GSUB-substitution-on-TrueTypeFont.patch, 
> 0006-Use-vhea-vmtx-to-fix-vertical-displacements-in-PCIDF.patch, 
> 0007-Add-factory-methods-for-loading-TTF-as-vertical-font.patch, 
> 0008-Implement-vertical-metrics-support-when-embedding-subsetting.patch, 
> FIX-0001-PDFBOX-4106-Remove-early-outs-leading-to-spurious-wa.patch, 
> FIX-0002-PDFBOX-4106-Document-GlyphSubstitutionTable-public-m.patch, 
> FIX-0003-PDFBOX-4106-Correct-deltaGlyphID-data-size.patch, 
> FIX-0004-PDFBOX-4106-Remove-unnecessary-vertical-displacement.patch, 
> FIX-0005-PDFBOX-4106-Remove-duplicate-DW2-creation.patch, 
> FIX-0006-PDFBOX-4106-Fix-non-embedded-vertical-font-rendering.patch, 
> FIX-0007-PDFBOX-4106-Fix-incorrect-parsing-of-W2-first-format.patch, 
> FIX-0008-PDFBOX-4106-Rename-misleading-field.patch, 
> FIX-0009-PDFBOX-4106-Allow-retrieving-vmtx-topSideBearing.patch, 
> FIX-0010-PDFBOX-4106-Correct-vmtx-embedding-for-proportional-.patch, 
> sample_code.txt, vertical.pdf
>
>
> I needed to output vertical Japanese text, but was stymied by several 
> limitations:
> * No API to load a TTF as Identity-V encoding
> * No support for 'vert' glyph substitution
> * No support for vertical metrics ('vhea' and 'vmtx' tables are parsed but 
> not used at all)
> I have attached a series of patches that implement the above features. 
> Highlights:
> * The GSUB glyph substitution table is parsed (limitation: type 1 lookups 
> only; this is sufficient for many features including 'vert'/'vrt2' vertical 
> glyph substitution)
> * Cmap lookup makes use of GSUB when features are enabled on a TTF
> * 'vhea' and 'vmtx' metrics are applied to PDCIDFont when appropriate, and 
> are embedded/subsetted correctly through the DW2/W2 CIDFont dictionary
> * An API has been added for loading a TTF as a vertical font, setting 
> Identity-V encoding and enabling 'vert'/'vrt2' substitution
> Each patch could approximately be split out into a separate ticket, if 
> desired.
> Also attached is some sample code that exercises these patches and 
> illustrates the effect of vertical glyph positioning. The sample output PDF 
> is also attached.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-4184) [PATCH]: Support simple lossless compression of 16 bit RGB images

2018-05-10 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-4184?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16471034#comment-16471034
 ] 

Tilman Hausherr commented on PDFBOX-4184:
-

Re icc profile, we have "ISOcoated_v2_300_bas.icc", see usage in PDDeviceCMYK.

Re CLA, probably yes…

You're using DeflaterOutputStream directly, would it be longer if you use 
{{FilterFactory.INSTANCE.getFilter(COSName.FLATE_DECODE);}} as done elsewhere?

Re comparing CMYK - why not get the RGB values, and compare that they have at 
most a difference of 2 ?

> [PATCH]: Support simple lossless compression of 16 bit RGB images
> -
>
> Key: PDFBOX-4184
> URL: https://issues.apache.org/jira/browse/PDFBOX-4184
> Project: PDFBox
>  Issue Type: Improvement
>  Components: Writing
>Affects Versions: 2.0.9
>Reporter: Emmeran Seehuber
>Priority: Minor
> Fix For: 2.0.10, 3.0.0 PDFBox
>
> Attachments: lossless_predictor_based_imageencoding.patch, 
> pdfbox_support_16bit_image_write.patch, png16-arrow-bad-no-smask.pdf, 
> png16-arrow-bad.pdf, png16-arrow-good-no-mask.pdf, png16-arrow-good.pdf
>
>
> The attached patch add support to write 16 bit per component images 
> correctly. I've integrated a test for this here: 
> [https://github.com/rototor/pdfbox-graphics2d/commit/8bf089cb74945bd4f0f15054754f51dd5b361fe9]
> It only supports 16-Bit TYPE_CUSTOM with DataType == USHORT images - but this 
> is what you usually get when you read a 16 bit PNG file.
> This would also fix [https://github.com/danfickle/openhtmltopdf/issues/173].
> The patch is against 2.0.9, but should apply to 3.0.0 too.
> There is still some room for improvements when writing lossless images, as 
> the images are currently not efficiently encoded. I.e. you could use PNG 
> encodings to get a better compression. (By adding a COSName.DECODE_PARMS with 
> a COSName.PREDICTOR == 15 and encoding the images as PNG). But this is 
> something for a later patch. It would also need another API, as there is a 
> tradeoff speed vs compression ratio. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org