make encoding non-editable if document filetype isn't Text or Html; remove unused imports;