refactor(workspace): Use new API from DocManager (closes #4705)