Fix ESC handling in automation dialogs when no button IDs are set

Closes #1660.
Improve the error message in the fonts collector when a style does not exist

Closes #1661.