Subversion Repositories Scribus

Compare Revisions

Ignore whitespace Rev 8328 → Rev 8327

/branches/Version13x/Scribus/scribus/serializer.cpp
49,13 → 49,8
Xml_attr attr;
handler.beginDoc();
handler.begin("SCRIBUSFRAGMENT", attr);
ScribusDoc* doc = selection.itemAt(0)->doc();
for (uint i=0; i < doc->Items->count(); ++i)
{
int k = selection.findItem(doc->Items->at(i));
if (k >=0)
doc->Items->at(i)->saxx(handler);
}
for (uint i=0; i < selection.count(); ++i)
selection.itemAt(i)->saxx(handler);
handler.end("SCRIBUSFRAGMENT");
handler.endDoc();
}
72,7 → 67,6
 
for (uint i=0; i < objects->count(); ++i)
{
// qDebug(QString("deserialized item: %1,%2").arg(objects->at(i)->xPos()).arg(objects->at(i)->yPos()));
result.addItem(objects->at(i));
}
 
80,10 → 74,10
return result;
}
 
Selection Serializer::deserializeObjects(const QFile & file)
Selection Serializer::deserializeObjects(const QFile & xml)
{
store<ScribusDoc>("<scribusdoc>", &m_Doc);
QFileInfo fi(file);
QFileInfo fi(xml);
parseFile(fi.filePath());
QPtrList<PageItem>* objects = result<QPtrList<PageItem> >();
91,7 → 85,6
for (uint i=0; i < objects->count(); ++i)
{
// qDebug(QString("deserialized item: %1,%2").arg(objects->at(i)->xPos()).arg(objects->at(i)->yPos()));
result.addItem(objects->at(i));
}