[
https://issues.apache.org/jira/browse/PDFBOX-1936?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13940692#comment-13940692
]
Tilman Hausherr edited comment on PDFBOX-1936 at 3/19/14 5:24 PM:
------------------------------------------------------------------
Update on this:
It's not a regression; the text was black last year because at that time,
pixels that weren't rendered were left black, and today such pixels are left
transparent.
The reason that nothing is shown is because AxialShadingContext is created with
a wrong AffineTransform, that has giant scale values. That AffineTransform is
related to the text rendering (drawString()) and is OK for that, but not for
the shading. When I replace the wrong AffineTransform with a standard one for
that dpi (e.g. [4.16, 0, 0][0, 4.16, 2508] for 300dpi) I get a perfectly
shaded text.
That's of course only a brute force solution that won't find a place in the
sources. However I wonder why this is so.
was (Author: tilman):
Update on this:
It's not a regression; the text was black last year because at that time,
pixels that weren't rendered were left black, and today such pixels are left
transparent.
The reason that nothing is shown is because AxialShadingContext is created with
a wrong AffineTransform, that has giant scale values. That AffineTransform is
related to the text rendering (drawString()) and is OK for that, but not for
the shading. When I replace the wrong AffineTransform with a standard one for
that dpi (e.g. [4.16, 0, 0][0, 4.16, 2508] for 300dpi) I get a perfectly
shaded text.
> text outline with shading pattern is invisible
> ----------------------------------------------
>
> Key: PDFBOX-1936
> URL: https://issues.apache.org/jira/browse/PDFBOX-1936
> Project: PDFBox
> Issue Type: Bug
> Components: Rendering
> Affects Versions: 2.0.0
> Reporter: Tilman Hausherr
> Labels: shading, shadingpattern
> Attachments: color_gradient.pdf, color_gradient.pdf-1.png,
> color_gradient.pdf-1.png, pslib-shading.pdf, pslib-shading.pdf-4.png,
> pslib-shading.pdf-4.png
>
>
> This is also somewhat of a regression: in PDFBOX-615, the file
> color_gradient.pdf-1.png had the text rendered, although in black. Currently,
> the text is invisible.
--
This message was sent by Atlassian JIRA
(v6.2#6252)