PDFDocument write(to:) removes all page labels

XCode 10 GM

iOS 12 GM


PDFDocument write(to:) removes all the existing page labels, like i, ii, iii, etc.


Is this a bug?

Replies

Not only does it remove all the page labels, it doesn't appear there's any way to set the page label either. There's a getter on PDFPage for label, but no setter.

How can we preserve labels, and further how can we set labels?