Fixed escape in empty paint editor text field throwing error

Fixes #271.