Currently we have this:
Using that means we're taking the system default printer's name, and using that to get settings using the
initPrintSettingsFromPrefs() methods. If the user has never printed using that printer before, then we're going to end up with a default initialized print settings without taking into account the limitations of the printer, such as unwritable margins. That's a shame, since we actually have the nsIPrinter for that printer at that point in the code and could call
createDefaultSettings() on it.
I think ultimately we need some new API to create the settings for a printer while copying over as many as are valid from another printer. In this case, creating a settings object for the default printer (or the first printer in the nsIPrinterList if none is selected as the default), and then copying over as many settings as possible from the
Save as PDF printer. That API would be closely related to whatever we end up with for bug 1669149, and probably should feed into the design of what we end up with there.