87 void title(
const QString & title );
91 void setTitle(
const QString& title );
94 const QString & title()
const;
102 bool isDirty()
const;
105 void dirty(
bool b );
109 void setDirty(
bool b );
117 void setFileName(
const QString & name );
120 QString fileName()
const;
146 bool read(
const QFileInfo &
file );
163 bool read( QDomNode & layerNode );
176 bool write(
const QFileInfo & file );
185 void clearProperties();
197 bool writeEntry(
const QString & scope,
const QString & key,
bool value );
199 bool writeEntry(
const QString & scope,
const QString & key,
double value );
200 bool writeEntry(
const QString & scope,
const QString & key,
int value );
201 bool writeEntry(
const QString & scope,
const QString & key,
const QString & value );
202 bool writeEntry(
const QString & scope,
const QString & key,
const QStringList & value );
214 QStringList readListEntry(
const QString & scope,
const QString & key, QStringList def = QStringList(),
bool *ok = 0 )
const;
216 QString readEntry(
const QString & scope,
const QString & key,
const QString & def = QString::null,
bool * ok = 0 )
const;
217 int readNumEntry(
const QString & scope,
const QString & key,
int def = 0,
bool * ok = 0 )
const;
218 double readDoubleEntry(
const QString & scope,
const QString & key,
double def = 0,
bool * ok = 0 )
const;
219 bool readBoolEntry(
const QString & scope,
const QString & key,
bool def =
false,
bool * ok = 0 )
const;
224 bool removeEntry(
const QString & scope,
const QString & key );
231 QStringList entryList(
const QString & scope,
const QString & key )
const;
237 QStringList subkeyList(
const QString & scope,
const QString & key )
const;
245 void dumpProperties()
const;
248 QString writePath( QString filename, QString relativeBasePath = QString::null )
const;
251 QString readPath( QString filename )
const;
254 QString error()
const;
261 QString layerIsEmbedded(
const QString&
id )
const;
266 bool createEmbeddedLayer(
const QString& layerId,
const QString& projectFilePath, QList<QDomNode>& brokenNodes,
267 QList< QPair< QgsVectorLayer*, QDomElement > >& vectorLayerList,
bool saveFlag =
true );
272 QgsLayerTreeGroup* createEmbeddedGroup(
const QString& groupName,
const QString& projectFilePath,
const QStringList &invisibleLayers );
276 bool avoidIntersection );
280 bool& avoidIntersection )
const;
283 void setTopologicalEditing(
bool enabled );
286 bool topologicalEditing()
const;
290 QString homePath()
const;
307 void setError( QString errorMessage );
314 bool addLayer(
const QDomElement& layerElem, QList<QDomNode>& brokenNodes, QList< QPair< QgsVectorLayer*, QDomElement > >& vectorLayerList );
317 void initializeEmbeddedSubtree(
const QString& projectFilePath,
QgsLayerTreeGroup* group );
324 void readProject(
const QDomDocument & );
327 void writeProject( QDomDocument & );
337 void readMapLayer(
QgsMapLayer *mapLayer,
const QDomElement &layerNode );
347 void writeMapLayer(
QgsMapLayer *mapLayer, QDomElement &layerElem, QDomDocument &doc );
353 void oldProjectVersionWarning( QString );
358 void layerLoaded(
int i,
int n );
360 void loadingLayer( QString );
362 void snapSettingsChanged();
373 QScopedPointer<Imp> imp_;
377 QPair< bool, QList<QDomNode> > _getMapLayers( QDomDocument
const &doc );
379 QString mErrorMessage;
386 QHash< QString, QPair< QString, bool> > mEmbeddedLayers;
388 void snapSettings( QStringList& layerIdList, QStringList& enabledList, QStringList& snapTypeList, QStringList& snapUnitList, QStringList& toleranceUnitList,
389 QStringList& avoidIntersectionList )
const;
404 virtual void handleBadLayers( QList<QDomNode> layers, QDomDocument projectDom ) = 0;
413 virtual void handleBadLayers( QList<QDomNode> layers, QDomDocument projectDom )
override;