bool AuroraMapWriter::writeTileset(const Tileset *tileset, const QString &fileName) { MapWriter writer; writer.setDtdEnabled(false); bool result = writer.writeTileset(tileset, fileName); if (!result) { mError = writer.errorString(); } else { mError.clear(); } return result; }
bool TmxMapWriter::writeTileset(const Tileset *tileset, const QString &fileName) { Preferences *prefs = Preferences::instance(); MapWriter writer; writer.setDtdEnabled(prefs->dtdEnabled()); bool result = writer.writeTileset(tileset, fileName); if (!result) mError = writer.errorString(); else mError.clear(); return result; }
bool TmxMapWriter::write(const Map *map, const QString &fileName) { Preferences *prefs = Preferences::instance(); MapWriter writer; writer.setLayerDataFormat(prefs->layerDataFormat()); writer.setDtdEnabled(prefs->dtdEnabled()); bool result = writer.writeMap(map, fileName); if (!result) mError = writer.errorString(); else mError.clear(); return result; }
bool AuroraMapWriter::write(const Map *map, const QString &fileName) { Map::LayerDataFormat format = map->layerDataFormat(); if (format == Map::Default) format = Map::Base64Zlib; format = Map::Base64Zlib; MapWriter writer; writer.setLayerDataFormat(format); writer.setDtdEnabled(false); bool result = writer.writeMap(map, fileName); if (!result) { mError = writer.errorString(); } else { mError.clear(); } return result; }