Skip to content
Permalink
Browse files
also support relative paths for textures
git-svn-id: http://svn.osgeo.org/qgis/trunk@11785 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed Oct 9, 2009
1 parent 9037374 commit 277cfac30e0b86c3454f487e30897e784e423a2c
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/core/symbology/qgssymbol.cpp
@@ -548,7 +548,7 @@ bool QgsSymbol::writeXML( QDomNode & item, QDomDocument & document, const QgsVec
symbol.appendChild( fillcolor );

appendText( symbol, document, "fillpattern", QgsSymbologyUtils::brushStyle2QString( mBrush.style() ) );
appendText( symbol, document, "texturepath", mTextureFilePath );
appendText( symbol, document, "texturepath", QgsProject::instance()->writePath( mTextureFilePath ) );

return returnval;
}
@@ -668,7 +668,7 @@ bool QgsSymbol::readXML( QDomNode &synode, const QgsVectorLayer *vl )

QDomNode texturepathnode = synode.namedItem( "texturepath" );
QDomElement texturepathelement = texturepathnode.toElement();
setCustomTexture( texturepathelement.text() );
setCustomTexture( QgsProject::instance()->readPath( texturepathelement.text() ) );

//run this after setting the custom texture path, so we override the brush if it isn't the custom pattern brush.
QDomNode fillpnode = synode.namedItem( "fillpattern" );

0 comments on commit 277cfac

Please sign in to comment.