fix bug found during test development: fire currentDocumentChanged when image is replacing a text document