From 1a8f6614c1dff4ade82e8bdf9a74420a4e4b8d90 Mon Sep 17 00:00:00 2001 From: Sebastian Gutwein Date: Sat, 23 Dec 2023 19:36:14 -0500 Subject: [PATCH] NoData harmonization --- .../processing/algs/gdal/ClipRasterByExtent.py | 2 +- .../processing/algs/gdal/ClipRasterByMask.py | 2 +- python/plugins/processing/algs/gdal/contour.py | 2 +- .../plugins/processing/algs/gdal/fillnodata.py | 2 +- .../plugins/processing/algs/gdal/gdal2xyz.py | 6 +++--- .../plugins/processing/algs/gdal/gdalcalc.py | 2 +- python/plugins/processing/algs/gdal/merge.py | 4 ++-- .../plugins/processing/algs/gdal/rasterize.py | 2 +- .../plugins/processing/algs/gdal/translate.py | 2 +- src/analysis/processing/qgsalgorithmdrape.cpp | 4 ++-- .../qgsalgorithmrasterlayerproperties.cpp | 6 +++--- .../qgsalgorithmrasterlayeruniquevalues.cpp | 4 ++-- .../processing/qgsalgorithmrasterlogicalop.cpp | 14 +++++++------- .../qgsalgorithmrasterzonalstats.cpp | 4 ++-- .../qgsalgorithmreclassifybylayer.cpp | 4 ++-- .../processing/qgsalgorithmrescaleraster.cpp | 4 ++-- .../processing/qgsalgorithmvectorize.cpp | 4 ++-- src/core/providers/gdal/qgsgdalprovider.cpp | 12 ++++++------ src/core/raster/qgsrasterlayer.cpp | 2 +- src/gui/raster/qgsrastertransparencywidget.cpp | 2 +- .../raster/qgspostgresrasterprovider.cpp | 6 +++--- src/ui/qgsrasterlayersaveasdialogbase.ui | 6 +++--- src/ui/raster/qgsrastertransparencywidget.ui | 18 +++++++++--------- 23 files changed, 57 insertions(+), 57 deletions(-) diff --git a/python/plugins/processing/algs/gdal/ClipRasterByExtent.py b/python/plugins/processing/algs/gdal/ClipRasterByExtent.py index 8583d293163..678dfadb8eb 100644 --- a/python/plugins/processing/algs/gdal/ClipRasterByExtent.py +++ b/python/plugins/processing/algs/gdal/ClipRasterByExtent.py @@ -64,7 +64,7 @@ class ClipRasterByExtent(GdalAlgorithm): self.tr('Override the projection for the output file'), defaultValue=False)) self.addParameter(QgsProcessingParameterNumber(self.NODATA, - self.tr('Assign a specified nodata value to output bands'), + self.tr('Assign a specified NoData value to output bands'), type=QgsProcessingParameterNumber.Double, defaultValue=None, optional=True)) diff --git a/python/plugins/processing/algs/gdal/ClipRasterByMask.py b/python/plugins/processing/algs/gdal/ClipRasterByMask.py index ee0a10960a8..ceec6c649c8 100644 --- a/python/plugins/processing/algs/gdal/ClipRasterByMask.py +++ b/python/plugins/processing/algs/gdal/ClipRasterByMask.py @@ -83,7 +83,7 @@ class ClipRasterByMask(GdalAlgorithm): self.tr('Target extent'), optional=True)) self.addParameter(QgsProcessingParameterNumber(self.NODATA, - self.tr('Assign a specified nodata value to output bands'), + self.tr('Assign a specified NoData value to output bands'), type=QgsProcessingParameterNumber.Double, defaultValue=None, optional=True)) diff --git a/python/plugins/processing/algs/gdal/contour.py b/python/plugins/processing/algs/gdal/contour.py index ed0ff984963..51994964ed5 100644 --- a/python/plugins/processing/algs/gdal/contour.py +++ b/python/plugins/processing/algs/gdal/contour.py @@ -85,7 +85,7 @@ class contour(GdalAlgorithm): self.addParameter(ignore_nodata_param) nodata_param = QgsProcessingParameterNumber(self.NODATA, - self.tr('Input pixel value to treat as "nodata"'), + self.tr('Input pixel value to treat as NoData'), type=QgsProcessingParameterNumber.Double, defaultValue=None, optional=True) diff --git a/python/plugins/processing/algs/gdal/fillnodata.py b/python/plugins/processing/algs/gdal/fillnodata.py index d0792e9ba18..af426e1a83b 100644 --- a/python/plugins/processing/algs/gdal/fillnodata.py +++ b/python/plugins/processing/algs/gdal/fillnodata.py @@ -98,7 +98,7 @@ class fillnodata(GdalAlgorithm): return 'fillnodata' def displayName(self): - return self.tr('Fill nodata') + return self.tr('Fill NoData') def group(self): return self.tr('Raster analysis') diff --git a/python/plugins/processing/algs/gdal/gdal2xyz.py b/python/plugins/processing/algs/gdal/gdal2xyz.py index d1e24b25cb6..7c1ab4dfd96 100644 --- a/python/plugins/processing/algs/gdal/gdal2xyz.py +++ b/python/plugins/processing/algs/gdal/gdal2xyz.py @@ -53,13 +53,13 @@ class gdal2xyz(GdalAlgorithm): parentLayerParameterName=self.INPUT)) self.addParameter(QgsProcessingParameterNumber(self.SRCNODATA, - self.tr('Input pixel value to treat as "nodata"'), + self.tr('Input pixel value to treat as NoData'), optional=True)) # GDAL > 3.6.3 self.addParameter(QgsProcessingParameterNumber(self.DSTNODATA, - self.tr('Assign specified "nodata" value to output'), + self.tr('Assign specified NoData value to output'), optional=True)) # GDAL > 3.6.3 self.addParameter(QgsProcessingParameterBoolean(self.SKIPNODATA, - self.tr('Do not output nodata values'), + self.tr('Do not output NoData values'), defaultValue=False)) # GDAL > 3.3 self.addParameter(QgsProcessingParameterBoolean(self.CSV, self.tr('Output comma-separated values'), diff --git a/python/plugins/processing/algs/gdal/gdalcalc.py b/python/plugins/processing/algs/gdal/gdalcalc.py index 2c535634fd5..9a34dc5791d 100644 --- a/python/plugins/processing/algs/gdal/gdalcalc.py +++ b/python/plugins/processing/algs/gdal/gdalcalc.py @@ -139,7 +139,7 @@ class gdalcalc(GdalAlgorithm): self.addParameter( QgsProcessingParameterNumber( self.NO_DATA, - self.tr('Set output nodata value'), + self.tr('Set output NoData value'), type=QgsProcessingParameterNumber.Double, defaultValue=None, optional=True)) diff --git a/python/plugins/processing/algs/gdal/merge.py b/python/plugins/processing/algs/gdal/merge.py index 51c952a7393..d5ab1d1c662 100644 --- a/python/plugins/processing/algs/gdal/merge.py +++ b/python/plugins/processing/algs/gdal/merge.py @@ -69,7 +69,7 @@ class merge(GdalAlgorithm): defaultValue=False)) nodata_param = QgsProcessingParameterNumber(self.NODATA_INPUT, - self.tr('Input pixel value to treat as "nodata"'), + self.tr('Input pixel value to treat as NoData'), type=QgsProcessingParameterNumber.Double, defaultValue=None, optional=True) @@ -77,7 +77,7 @@ class merge(GdalAlgorithm): self.addParameter(nodata_param) nodata_out_param = QgsProcessingParameterNumber(self.NODATA_OUTPUT, - self.tr('Assign specified "nodata" value to output'), + self.tr('Assign specified NoData value to output'), type=QgsProcessingParameterNumber.Double, defaultValue=None, optional=True) diff --git a/python/plugins/processing/algs/gdal/rasterize.py b/python/plugins/processing/algs/gdal/rasterize.py index 0654cefdb2f..a12a6117efb 100644 --- a/python/plugins/processing/algs/gdal/rasterize.py +++ b/python/plugins/processing/algs/gdal/rasterize.py @@ -103,7 +103,7 @@ class rasterize(GdalAlgorithm): self.tr('Output extent'), optional=True)) nodataParam = QgsProcessingParameterNumber(self.NODATA, - self.tr('Assign a specified nodata value to output bands'), + self.tr('Assign a specified NoData value to output bands'), type=QgsProcessingParameterNumber.Double, optional=True) nodataParam.setGuiDefaultValueOverride(QVariant(QVariant.Double)) diff --git a/python/plugins/processing/algs/gdal/translate.py b/python/plugins/processing/algs/gdal/translate.py index 4bfcd94adc4..25924671b30 100644 --- a/python/plugins/processing/algs/gdal/translate.py +++ b/python/plugins/processing/algs/gdal/translate.py @@ -62,7 +62,7 @@ class translate(GdalAlgorithm): defaultValue=None, optional=True)) self.addParameter(QgsProcessingParameterNumber(self.NODATA, - self.tr('Assign a specified nodata value to output bands'), + self.tr('Assign a specified NoData value to output bands'), type=QgsProcessingParameterNumber.Double, defaultValue=None, optional=True)) diff --git a/src/analysis/processing/qgsalgorithmdrape.cpp b/src/analysis/processing/qgsalgorithmdrape.cpp index e1b0823df91..c1d252f2dd5 100644 --- a/src/analysis/processing/qgsalgorithmdrape.cpp +++ b/src/analysis/processing/qgsalgorithmdrape.cpp @@ -45,10 +45,10 @@ void QgsDrapeAlgorithmBase::initParameters( const QVariantMap & ) // nodata value std::unique_ptr< QgsProcessingParameterNumber > nodata = std::make_unique< QgsProcessingParameterNumber >( QStringLiteral( "NODATA" ), - QObject::tr( "Value for nodata or non-intersecting vertices" ), QgsProcessingParameterNumber::Double, + QObject::tr( "Value for NoData or non-intersecting vertices" ), QgsProcessingParameterNumber::Double, 0.0 ); nodata->setIsDynamic( true ); - nodata->setDynamicPropertyDefinition( QgsPropertyDefinition( QStringLiteral( "NODATA" ), QObject::tr( "Value for nodata or non-intersecting vertices" ), QgsPropertyDefinition::Double ) ); + nodata->setDynamicPropertyDefinition( QgsPropertyDefinition( QStringLiteral( "NODATA" ), QObject::tr( "Value for NoData or non-intersecting vertices" ), QgsPropertyDefinition::Double ) ); nodata->setDynamicLayerParameterName( QStringLiteral( "INPUT" ) ); addParameter( nodata.release() ); diff --git a/src/analysis/processing/qgsalgorithmrasterlayerproperties.cpp b/src/analysis/processing/qgsalgorithmrasterlayerproperties.cpp index a03551fca74..e782dc23fae 100644 --- a/src/analysis/processing/qgsalgorithmrasterlayerproperties.cpp +++ b/src/analysis/processing/qgsalgorithmrasterlayerproperties.cpp @@ -62,15 +62,15 @@ void QgsRasterLayerPropertiesAlgorithm::initAlgorithm( const QVariantMap & ) addOutput( new QgsProcessingOutputString( QStringLiteral( "CRS_AUTHID" ), QObject::tr( "CRS authority identifier" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "WIDTH_IN_PIXELS" ), QObject::tr( "Width in pixels" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "HEIGHT_IN_PIXELS" ), QObject::tr( "Height in pixels" ) ) ); - addOutput( new QgsProcessingOutputBoolean( QStringLiteral( "HAS_NODATA_VALUE" ), QObject::tr( "Band has a nodata value set" ) ) ); - addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_VALUE" ), QObject::tr( "Band nodata value" ) ) ); + addOutput( new QgsProcessingOutputBoolean( QStringLiteral( "HAS_NODATA_VALUE" ), QObject::tr( "Band has a NoData value set" ) ) ); + addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_VALUE" ), QObject::tr( "Band NoData value" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "BAND_COUNT" ), QObject::tr( "Number of bands in raster" ) ) ); } QString QgsRasterLayerPropertiesAlgorithm::shortHelpString() const { return QObject::tr( "This algorithm returns basic properties of the given raster layer, including the extent, size in pixels and dimensions of pixels (in map units).\n\n" - "If an optional band number is specified then the nodata value for the selected band will also be returned." ); + "If an optional band number is specified then the NoData value for the selected band will also be returned." ); } QgsRasterLayerPropertiesAlgorithm *QgsRasterLayerPropertiesAlgorithm::createInstance() const diff --git a/src/analysis/processing/qgsalgorithmrasterlayeruniquevalues.cpp b/src/analysis/processing/qgsalgorithmrasterlayeruniquevalues.cpp index d9692d5ae1d..47991ef3987 100644 --- a/src/analysis/processing/qgsalgorithmrasterlayeruniquevalues.cpp +++ b/src/analysis/processing/qgsalgorithmrasterlayeruniquevalues.cpp @@ -64,7 +64,7 @@ void QgsRasterLayerUniqueValuesReportAlgorithm::initAlgorithm( const QVariantMap addOutput( new QgsProcessingOutputNumber( QStringLiteral( "WIDTH_IN_PIXELS" ), QObject::tr( "Width in pixels" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "HEIGHT_IN_PIXELS" ), QObject::tr( "Height in pixels" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "TOTAL_PIXEL_COUNT" ), QObject::tr( "Total pixel count" ) ) ); - addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_PIXEL_COUNT" ), QObject::tr( "NODATA pixel count" ) ) ); + addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_PIXEL_COUNT" ), QObject::tr( "NoData pixel count" ) ) ); } QString QgsRasterLayerUniqueValuesReportAlgorithm::shortHelpString() const @@ -200,7 +200,7 @@ QVariantMap QgsRasterLayerUniqueValuesReportAlgorithm::processAlgorithm( const Q out << QObject::tr( "

%1: %2 (%3 %4)

\n" ).arg( QObject::tr( "Height in pixels" ) ).arg( mLayerHeight ).arg( QObject::tr( "units per pixel" ) ).arg( mRasterUnitsPerPixelY ); out << QObject::tr( "

%1: %2

\n" ).arg( QObject::tr( "Total pixel count" ) ).arg( layerSize ); if ( mHasNoDataValue ) - out << QObject::tr( "

%1: %2

\n" ).arg( QObject::tr( "NODATA pixel count" ) ).arg( noDataCount ); + out << QObject::tr( "

%1: %2

\n" ).arg( QObject::tr( "NoData pixel count" ) ).arg( noDataCount ); out << QStringLiteral( "\n" ).arg( QObject::tr( "Value" ), QObject::tr( "Pixel count" ), QObject::tr( "Area" ), encodedAreaUnit ); for ( auto it = sortedUniqueValues.constBegin(); it != sortedUniqueValues.constEnd(); ++it ) diff --git a/src/analysis/processing/qgsalgorithmrasterlogicalop.cpp b/src/analysis/processing/qgsalgorithmrasterlogicalop.cpp index 9c93a834e82..597950cf887 100644 --- a/src/analysis/processing/qgsalgorithmrasterlogicalop.cpp +++ b/src/analysis/processing/qgsalgorithmrasterlogicalop.cpp @@ -46,10 +46,10 @@ void QgsRasterBooleanLogicAlgorithmBase::initAlgorithm( const QVariantMap & ) QObject::tr( "Input layers" ), QgsProcessing::TypeRaster ) ); addParameter( new QgsProcessingParameterRasterLayer( QStringLiteral( "REF_LAYER" ), QObject::tr( "Reference layer" ) ) ); - addParameter( new QgsProcessingParameterBoolean( QStringLiteral( "NODATA_AS_FALSE" ), QObject::tr( "Treat nodata values as false" ), false ) ); + addParameter( new QgsProcessingParameterBoolean( QStringLiteral( "NODATA_AS_FALSE" ), QObject::tr( "Treat NoData values as false" ), false ) ); std::unique_ptr< QgsProcessingParameterNumber > noDataValueParam = std::make_unique< QgsProcessingParameterNumber >( QStringLiteral( "NO_DATA" ), - QObject::tr( "Output no data value" ), QgsProcessingParameterNumber::Double, -9999 ); + QObject::tr( "Output NoData value" ), QgsProcessingParameterNumber::Double, -9999 ); noDataValueParam->setFlags( QgsProcessingParameterDefinition::FlagAdvanced ); addParameter( noDataValueParam.release() ); @@ -65,7 +65,7 @@ void QgsRasterBooleanLogicAlgorithmBase::initAlgorithm( const QVariantMap & ) addOutput( new QgsProcessingOutputNumber( QStringLiteral( "WIDTH_IN_PIXELS" ), QObject::tr( "Width in pixels" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "HEIGHT_IN_PIXELS" ), QObject::tr( "Height in pixels" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "TOTAL_PIXEL_COUNT" ), QObject::tr( "Total pixel count" ) ) ); - addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_PIXEL_COUNT" ), QObject::tr( "NODATA pixel count" ) ) ); + addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_PIXEL_COUNT" ), QObject::tr( "NoData pixel count" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "TRUE_PIXEL_COUNT" ), QObject::tr( "True pixel count" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "FALSE_PIXEL_COUNT" ), QObject::tr( "False pixel count" ) ) ); } @@ -220,8 +220,8 @@ QString QgsRasterLogicalOrAlgorithm::shortHelpString() const "that pixel will be set to 1 in the output raster. If all the input rasters have 0 values for the pixel it will be set to 0 in the output raster.\n\n" "The reference layer parameter specifies an existing raster layer to use as a reference when creating the output raster. The output raster " "will have the same extent, CRS, and pixel dimensions as this layer.\n\n" - "By default, a nodata pixel in ANY of the input layers will result in a nodata pixel in the output raster. If the " - "'Treat nodata values as false' option is checked, then nodata inputs will be treated the same as a 0 input value." ); + "By default, a NoData pixel in ANY of the input layers will result in a NoData pixel in the output raster. If the " + "'Treat NoData values as false' option is checked, then NoData inputs will be treated the same as a 0 input value." ); } QgsRasterLogicalOrAlgorithm *QgsRasterLogicalOrAlgorithm::createInstance() const @@ -297,8 +297,8 @@ QString QgsRasterLogicalAndAlgorithm::shortHelpString() const "that pixel will be set to 1 in the output raster. If any of the input rasters have 0 values for the pixel it will be set to 0 in the output raster.\n\n" "The reference layer parameter specifies an existing raster layer to use as a reference when creating the output raster. The output raster " "will have the same extent, CRS, and pixel dimensions as this layer.\n\n" - "By default, a nodata pixel in ANY of the input layers will result in a nodata pixel in the output raster. If the " - "'Treat nodata values as false' option is checked, then nodata inputs will be treated the same as a 0 input value." ); + "By default, a NoData pixel in ANY of the input layers will result in a NoData pixel in the output raster. If the " + "'Treat NoData values as false' option is checked, then NoData inputs will be treated the same as a 0 input value." ); } QgsRasterLogicalAndAlgorithm *QgsRasterLogicalAndAlgorithm::createInstance() const diff --git a/src/analysis/processing/qgsalgorithmrasterzonalstats.cpp b/src/analysis/processing/qgsalgorithmrasterzonalstats.cpp index 5803f63c50a..69f0087c5ed 100644 --- a/src/analysis/processing/qgsalgorithmrasterzonalstats.cpp +++ b/src/analysis/processing/qgsalgorithmrasterzonalstats.cpp @@ -72,7 +72,7 @@ void QgsRasterLayerZonalStatsAlgorithm::initAlgorithm( const QVariantMap & ) addOutput( new QgsProcessingOutputNumber( QStringLiteral( "WIDTH_IN_PIXELS" ), QObject::tr( "Width in pixels" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "HEIGHT_IN_PIXELS" ), QObject::tr( "Height in pixels" ) ) ); addOutput( new QgsProcessingOutputNumber( QStringLiteral( "TOTAL_PIXEL_COUNT" ), QObject::tr( "Total pixel count" ) ) ); - addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_PIXEL_COUNT" ), QObject::tr( "NODATA pixel count" ) ) ); + addOutput( new QgsProcessingOutputNumber( QStringLiteral( "NODATA_PIXEL_COUNT" ), QObject::tr( "NoData pixel count" ) ) ); } QString QgsRasterLayerZonalStatsAlgorithm::shortDescription() const @@ -85,7 +85,7 @@ QString QgsRasterLayerZonalStatsAlgorithm::shortHelpString() const return QObject::tr( "This algorithm calculates statistics for a raster layer's values, categorized by zones defined in another raster layer.\n\n" "If the reference layer parameter is set to \"Input layer\", then zones are determined by sampling the zone raster layer value at the centroid of each pixel from the source raster layer.\n\n" "If the reference layer parameter is set to \"Zones layer\", then the input raster layer will be sampled at the centroid of each pixel from the zones raster layer.\n\n" - "If either the source raster layer or the zone raster layer value is NODATA for a pixel, that pixel's value will be skipped and not including in the calculated statistics." ); + "If either the source raster layer or the zone raster layer value is NoData for a pixel, that pixel's value will be skipped and not including in the calculated statistics." ); } QgsRasterLayerZonalStatsAlgorithm *QgsRasterLayerZonalStatsAlgorithm::createInstance() const diff --git a/src/analysis/processing/qgsalgorithmreclassifybylayer.cpp b/src/analysis/processing/qgsalgorithmreclassifybylayer.cpp index 31180d443d4..5b61b073964 100644 --- a/src/analysis/processing/qgsalgorithmreclassifybylayer.cpp +++ b/src/analysis/processing/qgsalgorithmreclassifybylayer.cpp @@ -50,7 +50,7 @@ void QgsReclassifyAlgorithmBase::initAlgorithm( const QVariantMap & ) addAlgorithmParams(); std::unique_ptr< QgsProcessingParameterNumber > noDataValueParam = std::make_unique< QgsProcessingParameterNumber >( QStringLiteral( "NO_DATA" ), - QObject::tr( "Output no data value" ), QgsProcessingParameterNumber::Double, -9999 ); + QObject::tr( "Output NoData value" ), QgsProcessingParameterNumber::Double, -9999 ); noDataValueParam->setFlags( QgsProcessingParameterDefinition::FlagAdvanced ); addParameter( noDataValueParam.release() ); @@ -64,7 +64,7 @@ void QgsReclassifyAlgorithmBase::initAlgorithm( const QVariantMap & ) addParameter( boundsHandling.release() ); std::unique_ptr< QgsProcessingParameterBoolean > missingValuesParam = std::make_unique< QgsProcessingParameterBoolean >( QStringLiteral( "NODATA_FOR_MISSING" ), - QObject::tr( "Use no data when no range matches value" ), false, false ); + QObject::tr( "Use NoData when no range matches value" ), false, false ); missingValuesParam->setFlags( QgsProcessingParameterDefinition::FlagAdvanced ); addParameter( missingValuesParam.release() ); diff --git a/src/analysis/processing/qgsalgorithmrescaleraster.cpp b/src/analysis/processing/qgsalgorithmrescaleraster.cpp index 2b2763aa43d..23024631e15 100644 --- a/src/analysis/processing/qgsalgorithmrescaleraster.cpp +++ b/src/analysis/processing/qgsalgorithmrescaleraster.cpp @@ -53,7 +53,7 @@ QString QgsRescaleRasterAlgorithm::shortHelpString() const "(distribution) of the raster's histogram (pixel values). Input values " "are mapped using a linear interpolation from the source raster's minimum " "and maximum pixel values to the destination minimum and maximum pixel range.\n\n" - "By default the algorithm preserves original the NODATA value, but there is " + "By default the algorithm preserves original the NoData value, but there is " "an option to override it." ); } @@ -68,7 +68,7 @@ void QgsRescaleRasterAlgorithm::initAlgorithm( const QVariantMap & ) addParameter( new QgsProcessingParameterBand( QStringLiteral( "BAND" ), QObject::tr( "Band number" ), 1, QStringLiteral( "INPUT" ) ) ); addParameter( new QgsProcessingParameterNumber( QStringLiteral( "MINIMUM" ), QObject::tr( "New minimum value" ), QgsProcessingParameterNumber::Double, 0 ) ); addParameter( new QgsProcessingParameterNumber( QStringLiteral( "MAXIMUM" ), QObject::tr( "New maximum value" ), QgsProcessingParameterNumber::Double, 255 ) ); - addParameter( new QgsProcessingParameterNumber( QStringLiteral( "NODATA" ), QObject::tr( "New NODATA value" ), QgsProcessingParameterNumber::Double, QVariant(), true ) ); + addParameter( new QgsProcessingParameterNumber( QStringLiteral( "NODATA" ), QObject::tr( "New NoData value" ), QgsProcessingParameterNumber::Double, QVariant(), true ) ); addParameter( new QgsProcessingParameterRasterDestination( QStringLiteral( "OUTPUT" ), QObject::tr( "Rescaled" ) ) ); } diff --git a/src/analysis/processing/qgsalgorithmvectorize.cpp b/src/analysis/processing/qgsalgorithmvectorize.cpp index 02389e263e7..258dd103953 100644 --- a/src/analysis/processing/qgsalgorithmvectorize.cpp +++ b/src/analysis/processing/qgsalgorithmvectorize.cpp @@ -157,7 +157,7 @@ QString QgsRasterPixelsToPolygonsAlgorithm::shortHelpString() const { return QObject::tr( "This algorithm converts a raster layer to a vector layer, by creating polygon features " "for each individual pixel's extent in the raster layer.\n\n" - "Any nodata pixels are skipped in the output." ); + "Any NoData pixels are skipped in the output." ); } QString QgsRasterPixelsToPolygonsAlgorithm::shortDescription() const @@ -216,7 +216,7 @@ QString QgsRasterPixelsToPointsAlgorithm::shortHelpString() const { return QObject::tr( "This algorithm converts a raster layer to a vector layer, by creating point features " "for each individual pixel's center in the raster layer.\n\n" - "Any nodata pixels are skipped in the output." ); + "Any NoData pixels are skipped in the output." ); } QString QgsRasterPixelsToPointsAlgorithm::shortDescription() const diff --git a/src/core/providers/gdal/qgsgdalprovider.cpp b/src/core/providers/gdal/qgsgdalprovider.cpp index b943550b33d..1855d8a62ac 100644 --- a/src/core/providers/gdal/qgsgdalprovider.cpp +++ b/src/core/providers/gdal/qgsgdalprovider.cpp @@ -1895,7 +1895,7 @@ bool QgsGdalProvider::hasHistogram( int bandNo, if ( ( sourceHasNoDataValue( bandNo ) && !useSourceNoDataValue( bandNo ) ) || !userNoDataValues( bandNo ).isEmpty() ) { - QgsDebugMsgLevel( QStringLiteral( "Custom no data values -> GDAL histogram not sufficient." ), 3 ); + QgsDebugMsgLevel( QStringLiteral( "Custom NoData values -> GDAL histogram not sufficient." ), 3 ); return false; } @@ -1980,7 +1980,7 @@ QgsRasterHistogram QgsGdalProvider::histogram( int bandNo, if ( ( sourceHasNoDataValue( bandNo ) && !useSourceNoDataValue( bandNo ) ) || !userNoDataValues( bandNo ).isEmpty() ) { - QgsDebugMsgLevel( QStringLiteral( "Custom no data values, using generic histogram." ), 2 ); + QgsDebugMsgLevel( QStringLiteral( "Custom NoData values, using generic histogram." ), 2 ); return QgsRasterDataProvider::histogram( bandNo, binCount, minimum, maximum, boundingBox, sampleSize, includeOutOfRange, feedback ); } @@ -2954,7 +2954,7 @@ bool QgsGdalProvider::hasStatistics( int bandNo, if ( ( sourceHasNoDataValue( bandNo ) && !useSourceNoDataValue( bandNo ) ) || !userNoDataValues( bandNo ).isEmpty() ) { - QgsDebugMsgLevel( QStringLiteral( "Custom no data values -> GDAL statistics not sufficient." ), 2 ); + QgsDebugMsgLevel( QStringLiteral( "Custom NoData values -> GDAL statistics not sufficient." ), 2 ); return false; } @@ -3044,7 +3044,7 @@ QgsRasterBandStats QgsGdalProvider::bandStatistics( int bandNo, int stats, const if ( ( sourceHasNoDataValue( bandNo ) && !useSourceNoDataValue( bandNo ) ) || !userNoDataValues( bandNo ).isEmpty() ) { - QgsDebugMsgLevel( QStringLiteral( "Custom no data values, using generic statistics." ), 2 ); + QgsDebugMsgLevel( QStringLiteral( "Custom NoData values, using generic statistics." ), 2 ); return QgsRasterDataProvider::bandStatistics( bandNo, stats, boundingBox, sampleSize, feedback ); } @@ -3981,9 +3981,9 @@ bool QgsGdalProvider::setNoDataValue( int bandNo, double noDataValue ) { const QStringList errors = handler.popErrors(); if ( !errors.empty() ) - QgsDebugError( QStringLiteral( "Cannot set no data value: %1" ).arg( errors.join( QLatin1String( ", " ) ) ) ); + QgsDebugError( QStringLiteral( "Cannot set NoData value: %1" ).arg( errors.join( QLatin1String( ", " ) ) ) ); else - QgsDebugError( QStringLiteral( "Cannot set no data value" ) ); + QgsDebugError( QStringLiteral( "Cannot set NoData value" ) ); return false; } diff --git a/src/core/raster/qgsrasterlayer.cpp b/src/core/raster/qgsrasterlayer.cpp index 16afc45e37f..eb23c700989 100644 --- a/src/core/raster/qgsrasterlayer.cpp +++ b/src/core/raster/qgsrasterlayer.cpp @@ -507,7 +507,7 @@ QString QgsRasterLayer::htmlMetadata() const // Band table myMetadata += QStringLiteral( "
%1%2%3 (%4)
\n
\n" ) % - QStringLiteral( "\n" ); QgsRasterDataProvider *provider = const_cast< QgsRasterDataProvider * >( mDataProvider ); diff --git a/src/gui/raster/qgsrastertransparencywidget.cpp b/src/gui/raster/qgsrastertransparencywidget.cpp index c82d75f02cb..630f2d271df 100644 --- a/src/gui/raster/qgsrastertransparencywidget.cpp +++ b/src/gui/raster/qgsrastertransparencywidget.cpp @@ -50,7 +50,7 @@ QgsRasterTransparencyWidget::QgsRasterTransparencyWidget( QgsRasterLayer *layer, connect( pbnRemoveSelectedRow, &QToolButton::clicked, this, &QgsRasterTransparencyWidget::pbnRemoveSelectedRow_clicked ); mNodataColorButton->setShowNoColor( true ); - mNodataColorButton->setColorDialogTitle( tr( "Select No Data Color" ) ); + mNodataColorButton->setColorDialogTitle( tr( "Select NoData Color" ) ); syncToLayer(); connect( mOpacityWidget, &QgsOpacityWidget::opacityChanged, this, &QgsPanelWidget::widgetChanged ); diff --git a/src/providers/postgres/raster/qgspostgresrasterprovider.cpp b/src/providers/postgres/raster/qgspostgresrasterprovider.cpp index 20ef03da4e8..2a95dc4d936 100644 --- a/src/providers/postgres/raster/qgspostgresrasterprovider.cpp +++ b/src/providers/postgres/raster/qgspostgresrasterprovider.cpp @@ -1118,7 +1118,7 @@ bool QgsPostgresRasterProvider::init() if ( mBandCount != pxTypes.count( ) || mBandCount != noDataValues.count() ) { - throw QgsPostgresRasterProviderException( tr( "Band count and nodata items count differs" ) ); + throw QgsPostgresRasterProviderException( tr( "Band count and NoData items count differs" ) ); } int i = 0; @@ -1136,7 +1136,7 @@ bool QgsPostgresRasterProvider::init() { if ( noDataValues.at( i ) != QLatin1String( "NULL" ) ) { - QgsMessageLog::logMessage( tr( "Cannot convert nodata value '%1' to double" ) + QgsMessageLog::logMessage( tr( "Cannot convert NoData value '%1' to double" ) .arg( noDataValues.at( i ) ), QStringLiteral( "PostGIS" ), Qgis::MessageLevel::Info ); } @@ -1422,7 +1422,7 @@ bool QgsPostgresRasterProvider::init() if ( ! ok ) { - QgsMessageLog::logMessage( tr( "Cannot convert nodata value '%1' to double, default to: %2" ) + QgsMessageLog::logMessage( tr( "Cannot convert NoData value '%1' to double, default to: %2" ) .arg( result.PQgetvalue( rowNumber, 2 ) ) .arg( std::numeric_limits::min() ), QStringLiteral( "PostGIS" ), Qgis::MessageLevel::Info ); nodataValue = std::numeric_limits::min(); diff --git a/src/ui/qgsrasterlayersaveasdialogbase.ui b/src/ui/qgsrasterlayersaveasdialogbase.ui index de7f0ba56c7..3ffeaa7d91f 100644 --- a/src/ui/qgsrasterlayersaveasdialogbase.ui +++ b/src/ui/qgsrasterlayersaveasdialogbase.ui @@ -38,7 +38,7 @@ - Write out raw raster layer data. Optionally user defined no data values may be applied. + Write out raw raster layer data. Optionally user defined NoData values may be applied. Raw data @@ -483,10 +483,10 @@ datasets with maximum width and height specified below. - Additional no data values. The specified values will be set to no data in output raster. + Additional NoData values. The specified values will be set to NoData in output raster. - No data values + NoData values true diff --git a/src/ui/raster/qgsrastertransparencywidget.ui b/src/ui/raster/qgsrastertransparencywidget.ui index f2eff7bd190..f1280bbb87e 100644 --- a/src/ui/raster/qgsrastertransparencywidget.ui +++ b/src/ui/raster/qgsrastertransparencywidget.ui @@ -70,7 +70,7 @@ - No Data Value + NoData Value true @@ -82,17 +82,17 @@ - Display no data as + Display NoData as - Additional user defined no data value. + Additional user defined NoData value. - Additional no data value + Additional NoData value @@ -104,10 +104,10 @@ - Use original source no data value. + Use original source NoData value. - No data value + NoData value @@ -120,10 +120,10 @@ - Original data source no data value, if exists. + Original data source NoData value, if exists. - <src no data value> + <src NoData value> @@ -132,7 +132,7 @@ - Additional user defined no data value. + Additional user defined NoData value.
" ) % tr( "Number" ) % QStringLiteral( "" ) % tr( "Band" ) % QStringLiteral( "" ) % tr( "No-Data" ) % QStringLiteral( "" ) % + QStringLiteral( "
" ) % tr( "Number" ) % QStringLiteral( "" ) % tr( "Band" ) % QStringLiteral( "" ) % tr( "NoData" ) % QStringLiteral( "" ) % tr( "Min" ) % QStringLiteral( "" ) % tr( "Max" ) % QStringLiteral( "