Skip to content
Permalink
Browse files
wms bugfix
git-svn-id: http://svn.osgeo.org/qgis/trunk@6956 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed May 22, 2007
1 parent 8643bfb commit 8d62d5ae9a54f42bbe14d8e5c843f0c345d6b216
Showing with 11 additions and 5 deletions.
  1. +11 −5 src/providers/wms/qgswmsprovider.cpp
@@ -462,10 +462,13 @@ QImage* QgsWmsProvider::draw(QgsRect const & viewExtent, int pixelWidth, int pi
url += "STYLES=" + styles;
url += "&";
url += "FORMAT=" + imageMimeType;
url += "&";
url += "TRANSPARENT=TRUE";
if(!imageMimeType.contains("jpeg", Qt::CaseInsensitive) && !imageMimeType.contains("jpg", Qt::CaseInsensitive)) //MH: jpeg does not support transparency and some servers complain if jpg and transparent=true
{
url += "&";
url += "TRANSPARENT=TRUE";
}

//qWarning(url);
qWarning(url);

// cache some details for if the user wants to do an identifyAsHtml() later
mGetFeatureInfoUrlBase = baseUrl;
@@ -488,8 +491,11 @@ QImage* QgsWmsProvider::draw(QgsRect const & viewExtent, int pixelWidth, int pi
mGetFeatureInfoUrlBase += "STYLES=" + styles;
mGetFeatureInfoUrlBase += "&";
mGetFeatureInfoUrlBase += "FORMAT=" + imageMimeType;
mGetFeatureInfoUrlBase += "&";
mGetFeatureInfoUrlBase += "TRANSPARENT=TRUE";
if(!imageMimeType.contains("jpeg", Qt::CaseInsensitive) && !imageMimeType.contains("jpg", Qt::CaseInsensitive))
{
mGetFeatureInfoUrlBase += "&";
mGetFeatureInfoUrlBase += "TRANSPARENT=TRUE";
}


QByteArray imagesource;

0 comments on commit 8d62d5a

Please sign in to comment.