Moved the EN_UPDATE notification out of the paint handler. Instead, the notification is sent when an InvalidateRect is made after modifying the text.