Change Doctree Event Handle Function