Opening very large (1000s of pages) PDFs seems very slow. I traced it to PdfFile.GetPDFDocInfo which is retrieving the page info for every page before returning. I wonder if a better solution might be to lazily retrieve (and then store for future use) the page info for each page as needed. It should just be a matter of a custom IList<T> implementation for the PdfDocument.PageSizes property. Thoughts?
Opening very large (1000s of pages) PDFs seems very slow. I traced it to
PdfFile.GetPDFDocInfo
which is retrieving the page info for every page before returning. I wonder if a better solution might be to lazily retrieve (and then store for future use) the page info for each page as needed. It should just be a matter of a customIList<T>
implementation for thePdfDocument.PageSizes
property. Thoughts?