Exemplo n.º 1
0
 private static void AddResource(ref PDFArray arr, DocResourceSet res)
 {
     foreach (Resource resource1 in res)
     {
         arr.Add(resource1.Direct);
         if (resource1.Dict["OPI"] != null)
         {
             arr.Add(resource1.Dict["OPI"].Direct);
         }
         if (resource1.Resources == null)
         {
             continue;
         }
         ObjectCollection.AddResource(arr, resource1.Resources);
     }
 }
Exemplo n.º 2
0
 // Methods
 internal DocResourceSet(PDFDict resourceDict, PDFDict parentDict, DocResourceSet parent)
 {
     this.mParentDict    = null;
     this.mParent        = new WeakReference(null);
     this.mParentDict    = parentDict;
     this.mResourceDict  = resourceDict;
     this.mParent.Target = parent;
     if (this.mResourceDict == null)
     {
         return;
     }
     this.ScanResourceType(((PDFDict)resourceDict["ExtGState"]), typeof(ExtGState));
     this.ScanResourceType(((PDFDict)resourceDict["ColorSpace"]), typeof(ColorSpace));
     this.ScanResourceType(((PDFDict)resourceDict["Pattern"]), typeof(Pattern));
     this.ScanResourceType(((PDFDict)resourceDict["Shading"]), typeof(Shading));
     this.ScanResourceType(((PDFDict)resourceDict["XObject"]), typeof(XObject));
     this.ScanResourceType(((PDFDict)resourceDict["Font"]), typeof(Font));
     this.ScanResourceType(((PDFDict)resourceDict["Properties"]), typeof(Properties));
 }