+ bool ImportXML(wxRichTextBuffer* buffer, wxRichTextObject* obj, wxXmlNode* node);
+
+ /**
+ Call with XML node name, C++ class name so that wxRTC can read in the node.
+ If you add a custom object, call this.
+ */
+ static void RegisterNodeName(const wxString& nodeName, const wxString& className) { sm_nodeNameToClassMap[nodeName] = className; }
+
+ /**
+ Cleans up the mapping between node name and C++ class.
+ */
+ static void ClearNodeToClassMap() { sm_nodeNameToClassMap.clear(); }
+
+protected:
+
+ /**
+ Loads buffer context from the given stream.
+ */
+ virtual bool DoLoadFile(wxRichTextBuffer* buffer, wxInputStream& stream);
+
+ /**
+ Saves buffer context to the given stream.
+ */
+ virtual bool DoSaveFile(wxRichTextBuffer* buffer, wxOutputStream& stream);