[dvipdfmx] color stack and color special order at second page

Ulrike Fischer news3 at nililand.de
Wed Dec 9 23:06:07 CET 2020



When using both the pdfcolorstack and the bcolor special, the order on
the second page seems to be wrong. The bcolor value is always first:

0 0 1 RG 0 0 1 rg 1 0 0 rg 1 0 0 RG 0 1 0 rg 0 1 0 RG


\documentclass{article}
\begin{document}
\special{pdfcolorstackinit 0 page direct (0 g)}
\special{pdfcolorstack 0 push (1 0 0 rg 1 0 0 RG)}
this is red
\special{pdfcolorstackinit 1 page direct (0 g)}
\special{pdfcolorstack 1 push (0 1 0 rg 0 1 0 RG)}
this is green
\special{pdf:bcolor [0 0 1]}
this ist blue
\newpage
this should be blue but is green
\special{pdf:ecolor}
\end{document}


What could one do to keep this in order? (With pdflatex the main color
command is stack 0, so there is no problem.)


-- 
Mit freundlichen Grüßen
Ulrike Fischer
mailto:news3 at nililand.de




More information about the dvipdfmx mailing list.