diff layer/SliceLayer.cpp @ 316:c0b9eec70639

* Make XmlExportable::toXml the function that is universally overridden (and pure virtual) instead of toXmlString. Tidies up some classes, notably the model classes, significantly. Closes #1794561.
author Chris Cannam
date Thu, 18 Oct 2007 10:15:07 +0000
parents 3101c68a00c1
children 984c1975f1ff
line wrap: on
line diff
--- a/layer/SliceLayer.cpp	Wed Oct 17 12:58:45 2007 +0000
+++ b/layer/SliceLayer.cpp	Thu Oct 18 10:15:07 2007 +0000
@@ -27,6 +27,8 @@
 
 #include <QPainter>
 #include <QPainterPath>
+#include <QTextStream>
+
 
 SliceLayer::SliceLayer() :
     m_sliceableModel(0),
@@ -870,8 +872,9 @@
         (QString(darkbg ? "Bright Blue" : "Blue"));
 }
 
-QString
-SliceLayer::toXmlString(QString indent, QString extraAttributes) const
+void
+SliceLayer::toXml(QTextStream &stream,
+                  QString indent, QString extraAttributes) const
 {
     QString s;
     
@@ -886,7 +889,7 @@
         .arg(m_gain)
         .arg(m_normalize ? "true" : "false");
 
-    return SingleColourLayer::toXmlString(indent, extraAttributes + " " + s);
+    SingleColourLayer::toXml(stream, indent, extraAttributes + " " + s);
 }
 
 void