fix plain text mode