I'll note my "progress" here in hopes that if I'm way off base in the concept, one of you can throw a flag.
It does seem that there should be a class to represent a Shading Dictionary. Conceptually it is parallel to PDPattern, so I now have a PDShading class. I haven't committed this code as it's really not doing anything yet ... but it looks like part of the solution.
The piece I completely overlooked in last night's comment was the sh operator. I'm implementing it as o.a.p.util.operator.pagedrawer.SHFill.
At this point its process method is simply logging the argument list.
This operator is getting a single name argument – just like the spec says it should. In my case it's:
I must say I'm a little confused regarding how to take that name and get the Shading Dictionary.
The relevant section of the PDF file looks like this:
<</Parent 2 0 R
/Contents 178 0 R
/BleedBox[0.0 0.0 1152.0 1656.0]
<</Illustrator 142 0 R>>
/ArtBox[39.6431 171.689 963.828 1655.02]
/MediaBox[0.0 0.0 1152.0 1656.0]
/Thumb 183 0 R
/TrimBox[0.0 0.0 1152.0 1656.0]
<</Sh0 170 0 R>>
<</CS0 174 0 R/CS1 162 0 R/CS2 175 0 R/CS3 168 0 R/CS4 163 0 R/CS5 169 0 R>>
<</T1_0 176 0 R>>
<</MC0 158 0 R>>
<</GS0 161 0 R>>
The Sh0 name is clearly there ... and it refers to object 170 if I'm reading it right. Object 170 appears to be:
170 0 obj
<</ColorSpace 162 0 R/AntiAlias false/Coords[0.0 0.0 1.0 0.0]/Function 171 0 R/Extend[true true]/Domain[0.0 1.0]/ShadingType 2>>
This contains the required entries for a shading dictionary of ShadingType 2 (Axial) as well as a couple of the optional ones.
Which all brings me back to trying to get the Shading Dictionary from the name Sh0.
Again, pointers are MUCH appreciated.