Use getCurrentDoc() more.