Add error domain and enum to libgedit-document

It will be useful for the document saver (and probably the document
loader too).