summaryrefslogtreecommitdiff
path: root/Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps
diff options
context:
space:
mode:
authorReinhard Kotucha <reinhard.kotucha@web.de>2021-09-29 01:02:39 +0000
committerReinhard Kotucha <reinhard.kotucha@web.de>2021-09-29 01:02:39 +0000
commit032fbe3299ba69dfde0e6b488c63d7172f5526cc (patch)
tree609e446095e13bafd341617218852c3db3bb254c /Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps
parent73f30335fe2918b048eaaedddc30503169fb8be9 (diff)
Upgrade gs-9.54.0 -> gs-9.55.0
git-svn-id: svn://tug.org/texlive/trunk@60648 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps')
-rw-r--r--Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps32
1 files changed, 21 insertions, 11 deletions
diff --git a/Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps b/Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps
index fe61b12dcdb..27c2068088f 100644
--- a/Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps
+++ b/Master/tlpkg/tlgs/Resource/Init/pdf_ops.ps
@@ -680,8 +680,8 @@ end
} def
/Dpop { //OPsaveDstack begin previous { def } forall end } def
-% colorspaces that don't require special overprint transparency handling
-/okOPcs mark /DeviceGray 0 /DeviceCMYK 1 /DeviceN 2 /Separation 3 .dicttomark def
+% colorspaces that require special overprint transparency handling
+/specialOPcs mark /DeviceGray 0 /DeviceCMYK 1 /DeviceN 2 /Separation 3 .dicttomark def
% Take care of pushing a transparency group if we need it for SMask or for Overprint..
% After pushing the group, we save the ca and CA and change them
@@ -696,11 +696,18 @@ end
//OPsaveDstack begin
//Dpush exec % push the current OPsaveDstack values into 'previous'
/SupportsDevn .special_op
- okOPcs currentcolorspace 0 get dup /Indexed eq {
+ specialOPcs currentcolorspace 0 get dup /Indexed eq {
pop currentcolorspace 1 get % use the base space
} if
known or {
- 1 index /stroke ne { .currentfilloverprint } { .currentstrokeoverprint } ifelse
+ dup /stroke ne {
+ .currentfilloverprint
+ 1 index dup /.fillstroke eq exch /.eofillstroke eq or {
+ .currentstrokeoverprint or
+ } if
+ } {
+ .currentstrokeoverprint
+ } ifelse
% Change BM to CompatibleOverprint if this has overprint true
dup /ChangeBM exch def
.currentblendmode dup /Normal eq exch /Compatible eq or
@@ -961,12 +968,12 @@ currentdict dup /Dpush .undef /Dpop .undef
n
} bind executeonly def
/b { closepath B* } bind executeonly def
-/n { end { currentpoint } stopped not { pop pop clip } if newpath } bind executeonly def
+/n { end .currentpoint_valid { clip } if newpath } bind executeonly def
end readonly def
/W { //Wdict begin } bind executeonly def
/W*dict 8 dict dup begin
Wdict { def } forall
-/n { end { currentpoint } stopped not { pop pop eoclip } if newpath } bind executeonly def
+/n { end .currentpoint_valid { eoclip } if newpath } bind executeonly def
end readonly def
/W* { //W*dict begin } bind executeonly def
% ---------------- Text control ---------------- %
@@ -1057,7 +1064,8 @@ end readonly def
/settextposition {
% Update the TextMatrix translation.
gsave TextSaveMatrix setmatrix
- {currentpoint} stopped not {
+ .currentpoint_valid {
+ currentpoint
.currenttextrise
sub
matrix .currenttextmatrix
@@ -1105,6 +1113,9 @@ end readonly def
} bind executeonly odef
/BT {
+ % Bug 703996 has a path defined before BT, then stroked afterwards
+ .currentpoint_valid { //false upath } { //null } ifelse
+ /BT_upath gput
//false /illegal_BT gput
currentdict /TextSaveMatrix known {
( **** Error: illegal nested BT operator detected.\n)
@@ -1153,10 +1164,8 @@ end readonly def
/clip_if_required {
.currenttextrenderingmode 4 ge
- {currentpoint} //.internalstopped exec
- {//false}
- {pop pop //true}
- ifelse and
+ .currentpoint_valid
+ and
{ .currentfilladjust2 0 dup .setfilladjust2 clip .setfilladjust2} if
newpath
} bind def
@@ -1183,6 +1192,7 @@ end readonly def
%% in a nested text block (inside a gsave).
currentdict /qTextSaveMatrix known not {
switch_to_normal_marking_ops
+ currentdict /BT_upath get dup //null eq { pop } { newpath uappend } ifelse
} if
} bind executeonly def