[dvipdfmx] pdf:bxgstate fails if other packages add opacity too
平田俊作
shunsaku.hirata74 at gmail.com
Fri Sep 4 01:36:12 CEST 2020
Thanks for the report.
I think merging resource dictionary is still not properly done when it’s entry is supplied as an indirect object via pdf:put.
I already identified a problem in the dvipdfmx code and will inspect it in detail later.
Thanks,
Shunsaku Hirata
2020/09/04 7:30、Ulrike Fischer <news3 at nililand.de>のメール:
> I try the new \special{pdf:bxgstate ...} ... \special{pdf:exgstate}
> (using the binary from w32tex.org)
>
> When used alone in a document it works fine, but if use together with
> a package which sets ExtGState too, e.g. tikz it fails to correctly
> reset a transparency after a page break
>
>
> \RequirePackage{l3pdf}
> \ExplSyntaxOn
> \pdf_uncompress:
> \ExplSyntaxOff
> \documentclass{article}
> \usepackage{tikz}
> \begin{document}
> blblbllb
> \tikz[opacity=0.3]\fill[red](0,0)rectangle(1,1);
> \special{pdf:bxgstate << /CA 0.2 /ca 0.2 >>}
> Transparent\newpage text. %second page is black again
> \special{pdf:exgstate}%
> \end{document}
>
>
> Looking in the pdf one can see that the ExtGState entries have been
> correctly merge, but the numbering of the dvipdfmx entries are wrong:
>
> The dictionary shows 0 and 2:
>
>
> <</pgf at CA0.3<</CA .3>>
> /pgf at ca0.3<</ca .3>>
> /DPX_GS0<</CA .2/ca .2>>
> /DPX_GS2<</CA 1/ca 1>>
>>>
>
>
> and the stream of the first pages uses the 0 entry /DPX_GS0 gs, but on the second
> page /DPX_GS1 gs is used.
>
>
> With tikz only one ExtGState object is used and referenced by every
> page, without tikz every page has its own ExtGState setting.
>
>
> Ulrike Fischer
>
More information about the dvipdfmx
mailing list.