Performance tweaks for listening to documents

* the text listener we were using previously seemed to fire events a
little too frequently - this should be more concise