menu: add autoformat code to tools menu