What about encoding in notmuch the elements composing the line, print the elements with a separator that would be encoded if it appears in an element, then do the reverse in emacs. One such encoding might be URL-encoding. Servilio