Use a custom type for document writers.

This avoids possible problems ocurring while printing objects with
both the __unicode__ and __call__ methods. Before this change, such an
object would be assumed to be a document writer and given the writing
procedure when composing the document.