If you’ve tried printing from my Rich Text editor DelightEd, or saved a document to PDF format from it, you’ll have discovered its rough edges. Printing respected the appearance of a window, so if you forgot to switch it to Light Mode, you got Dark Mode pages from your printer.
The reason for this is that AppKit, Apple’s app framework on which DelightEd depends, doesn’t handle printing text views in Dark Mode, but assumes that the app will do that for it. I had been unable to find any further explanation of how that might be accomplished, until recently when I stumbled across an example cunningly hidden in Apple’s developer documentation.
I have now implemented this in a new version of DelightEd, which should at last print all pages in Light Mode.
Another area which was a problem in the previous release was saving an existing document in PDF format. Again, I have been following Apple’s developer documentation, and used the correct call to generate PDF from a view, only the best that this is capable of, as far as I can see, is writing the whole document into a single very tall page of PDF. That works, but probably isn’t what you were hoping for, and to add another issue, it too occurred in the current appearance set for a view.
Whilst it may on occasion be useful, or mildly entertaining, to create these vast PDF pages in Dark Mode, a better solution was needed.
This new version offers two alternatives, both of which create properly paginated PDF documents set in Light Mode. One is to use a new Export to PDF command, and the other is to go through the Print command and then Save as PDF from the standard print dialog. Although the resulting documents are similar, they interpret font sizes and page layouts slightly differently.
I have created a new product page for DelightEd and Podofyllin, which also links to separate support pages for those two apps. DelightEd version 1.3, with these printing and PDF improvements and direct link to its product page in the Help menu, is now available from there.
I am now in the midst of addressing the problems of printing views in Podofyllin, and later this week intend posting an update to that to the same product page. If there are any of my other apps which you want to support improved printing in a similar way, please let me know.