Use new callbacks system of Document