def __init__( self, iface ): QWidget.__init__( self ) self.iface = iface self.resampling_method = ('nearest', 'average', 'gauss', 'average_mp', 'average_magphase', 'mode') self.setupUi( self ) BaseBatchWidget.__init__( self, self.iface, "gdaladdo" ) # set the default QSpinBoxes and QProgressBar value self.progressBar.setValue(0) self.progressBar.hide() # we don't need load to canvas functionality self.base.loadCheckBox.hide() self.setParamsStatus( [ (self.inputLayerCombo, [SIGNAL("currentIndexChanged(int)"), SIGNAL("editTextChanged(const QString &)")] ), ( self.algorithmCombo, SIGNAL( "currentIndexChanged( int )" ), self.algorithmCheck ), ( self.levelsEdit, SIGNAL( "textChanged( const QString & )" ) ), ( self.roModeCheck, SIGNAL( "stateChanged( int )" ) ), ( self.rrdCheck, SIGNAL( "stateChanged(int)" ) ), ( self.jpegQualitySpin, SIGNAL( "valueChanged (int)" ) ), ( self.jpegQualityContainer, None, self.tiffjpegCheck), ( self.jpegQualityContainer, None, None, "1.7.0"), #only show for GDAL >=1.7.0 ( self.cleanCheck, SIGNAL( "stateChanged(int)" ), None, "1.7.0" ) #only show for GDAL >=1.7.0 ] ) self.connect( self.selectInputFileButton, SIGNAL( "clicked()" ), self.fillInputFile ) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) # fill layers combo self.fillInputLayerCombo()
def __init__( self, iface ): QWidget.__init__( self ) self.iface = iface self.setupUi( self ) BaseBatchWidget.__init__( self, self.iface, "gdalwarp" ) self.inSelector.setType( self.inSelector.FILE ) # set the default QSpinBoxes and QProgressBar value self.progressBar.setValue(0) self.progressBar.hide() self.recurseCheck.hide() self.setParamsStatus( [ ( self.inSelector, SIGNAL( "filenameChanged()" ) ), ( self.desiredSRSEdit, SIGNAL( "textChanged( const QString & )" ) ) ] ) self.connect( self.inSelector, SIGNAL( "selectClicked()" ), self.fillInputFileEdit ) self.connect( self.selectDesiredSRSButton, SIGNAL( "clicked()" ), self.fillDesiredSRSEdit ) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) self.connect( self.recurseCheck, SIGNAL( "stateChanged( int )" ), self.enableRecurse )
def __init__( self, iface ): QWidget.__init__( self ) self.iface = iface self.setupUi( self ) BaseBatchWidget.__init__( self, self.iface, "gdal_fillnodata.py" ) self.inSelector.setType( self.inSelector.FILE_LAYER ) self.outSelector.setType( self.outSelector.FILE ) self.maskSelector.setType( self.maskSelector.FILE ) self.progressBar.setValue(0) self.progressBar.hide() self.formatLabel.hide() self.formatCombo.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ ( self.inSelector, SIGNAL( "filenameChanged()" ) ), ( self.outSelector, SIGNAL( "filenameChanged()" ) ), ( self.maskSelector, SIGNAL( "filenameChanged()" ), self.maskCheck ), ( self.distanceSpin, SIGNAL( "valueChanged( int )" ), self.distanceCheck ), ( self.smoothSpin, SIGNAL( "valueChanged( int )" ), self.smoothCheck ), ( self.bandSpin, SIGNAL( "valueChanged( int )" ), self.bandCheck ), ( self.nomaskCheck, SIGNAL( "stateChanged( int )" ) ) ]) self.connect( self.inSelector, SIGNAL( "selectClicked()" ), self.fillInputFile ) self.connect( self.outSelector, SIGNAL( "selectClicked()" ), self.fillOutputFile) self.connect( self.maskSelector, SIGNAL( "selectClicked()" ), self.fillMaskFile) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) # add raster filters to combo self.formatCombo.addItems( Utils.FileFilter.allRastersFilter().split( ";;" ) )
def __init__( self, iface ): QWidget.__init__( self ) self.iface = iface self.resampling_method = ('nearest', 'average', 'gauss', 'cubic', 'average_mp', 'average_magphase', 'mode') self.setupUi( self ) BaseBatchWidget.__init__( self, self.iface, "gdaladdo" ) # set the default QSpinBoxes and QProgressBar value self.progressBar.setValue(0) self.progressBar.hide() # we don't need load to canvas functionality self.base.loadCheckBox.hide() self.setParamsStatus( [ ( self.inSelector, SIGNAL("filenameChanged()")), ( self.cleanCheck, SIGNAL( "stateChanged(int)" ), None, 1700 ), ( self.mPyramidOptionsWidget, SIGNAL( "overviewListChanged()" )), ( self.mPyramidOptionsWidget, SIGNAL( "someValueChanged()" )) ] ) self.connect( self.inSelector, SIGNAL( "selectClicked()" ), self.fillInputFile ) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) self.init = False #workaround bug that pyramid options widgets are not initialized at first
def __init__( self, iface ): QWidget.__init__( self ) self.iface = iface self.setupUi( self ) BaseBatchWidget.__init__( self, self.iface, "gdal_fillnodata.py" ) self.inSelector.setType( self.inSelector.FILE_LAYER ) self.outSelector.setType( self.outSelector.FILE ) self.maskSelector.setType( self.maskSelector.FILE ) self.progressBar.setValue(0) self.progressBar.hide() self.formatLabel.hide() self.formatCombo.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ ( self.inSelector, SIGNAL( "filenameChanged()" ) ), ( self.outSelector, SIGNAL( "filenameChanged()" ) ), ( self.maskSelector, SIGNAL( "filenameChanged()" ), self.maskCheck ), ( self.distanceSpin, SIGNAL( "valueChanged( int )" ), self.distanceCheck ), ( self.smoothSpin, SIGNAL( "valueChanged( int )" ), self.smoothCheck ), ( self.bandSpin, SIGNAL( "valueChanged( int )" ), self.bandCheck ), ( self.nomaskCheck, SIGNAL( "stateChanged( int )" ) ) ]) self.connect( self.inSelector, SIGNAL( "selectClicked()" ), self.fillInputFile ) self.connect( self.outSelector, SIGNAL( "selectClicked()" ), self.fillOutputFile) self.connect( self.maskSelector, SIGNAL( "selectClicked()" ), self.fillMaskFile) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) # add raster filters to combo self.formatCombo.addItems( Utils.FileFilter.allRastersFilter().split( ";;" ) )
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.canvas = self.iface.mapCanvas() self.expand_method = ('gray', 'rgb', 'rgba') self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "gdal_translate") self.outSelector.setType(self.outSelector.FILE) # set the default QSpinBoxes and QProgressBar value self.outsizeSpin.setValue(25) self.progressBar.setValue(0) self.progressBar.hide() self.formatLabel.hide() self.formatCombo.hide() if Utils.Version(Utils.GdalConfig.version()) < "1.7": index = self.expandCombo.findText('gray', Qt.MatchFixedString) if index >= 0: self.expandCombo.removeItem(index) self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.targetSRSEdit, SIGNAL("textChanged(const QString &)"), self.targetSRSCheck), (self.selectTargetSRSButton, None, self.targetSRSCheck), (self.creationOptionsWidget, SIGNAL("optionsChanged()")), (self.outsizeSpin, SIGNAL("valueChanged(const QString &)"), self.outsizeCheck), (self.nodataSpin, SIGNAL("valueChanged(int)"), self.nodataCheck), (self.expandCombo, SIGNAL("currentIndexChanged(int)"), self.expandCheck, 1600), (self.sdsCheck, SIGNAL("stateChanged(int)")), (self.srcwinEdit, SIGNAL("textChanged(const QString &)"), self.srcwinCheck), (self.prjwinEdit, SIGNAL("textChanged(const QString &)"), self.prjwinCheck) ]) #self.connect(self.canvas, SIGNAL("layersChanged()"), self.fillInputLayerCombo) self.connect(self.inSelector, SIGNAL("layerChanged()"), self.fillTargetSRSEditDefault) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect(self.selectTargetSRSButton, SIGNAL("clicked()"), self.fillTargetSRSEdit) self.connect(self.batchCheck, SIGNAL("stateChanged( int )"), self.switchToolMode) # add raster filters to combo self.formatCombo.addItems( Utils.FileFilter.allRastersFilter().split(";;"))
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "pct2rgb.py") # we use one widget for two tools, so change control labels self.base.setWindowTitle( self.tr( "Convert paletted image to RGB" ) ) self.colorsCheck.setText( self.tr( "Band to convert:" ) ) self.colorsSpin.setRange( 1, 256 ) self.colorsSpin.setValue( 1 ) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus( [ (self.inputLayerCombo, [ SIGNAL("currentIndexChanged(int)"), SIGNAL("editTextChanged(const QString &)") ] ), (self.outputFileEdit, SIGNAL("textChanged(const QString &)")), (self.colorsSpin, SIGNAL("valueChanged(int)"), self.colorsCheck), ] ) self.connect(self.selectInputFileButton, SIGNAL("clicked()"), self.fillInputFile) self.connect(self.selectOutputFileButton, SIGNAL("clicked()"), self.fillOutputFileEdit) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) self.fillInputLayerCombo()
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "rgb2pct.py") self.outSelector.setType( self.outSelector.FILE ) # set the default QSpinBoxes and QProgressBar value self.colorsSpin.setValue(2) self.progressBar.setValue(0) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.colorsSpin, SIGNAL("valueChanged(int)"), self.colorsCheck), (self.bandSpin, SIGNAL("valueChanged(int)"), self.bandCheck, "-1") # hide this option ]) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode )
def __init__( self, iface ): QWidget.__init__( self ) self.iface = iface self.resampling_method = ('nearest', 'average', 'gauss', 'cubic', 'average_mp', 'average_magphase', 'mode') self.setupUi( self ) BaseBatchWidget.__init__( self, self.iface, "gdaladdo" ) # set the default QSpinBoxes and QProgressBar value self.progressBar.setValue(0) self.progressBar.hide() # we don't need load to canvas functionality self.base.loadCheckBox.hide() self.setParamsStatus([ ( self.inSelector, SIGNAL("filenameChanged()")), ( self.cleanCheck, SIGNAL( "stateChanged(int)" ), None, 1700 ), ( self.mPyramidOptionsWidget, SIGNAL( "overviewListChanged()" )), ( self.mPyramidOptionsWidget, SIGNAL( "someValueChanged()" )) ]) self.connect( self.inSelector, SIGNAL( "selectClicked()" ), self.fillInputFile ) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) self.init = False # workaround bug that pyramid options widgets are not initialized at first
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "pct2rgb.py") # we use one widget for two tools self.base.setWindowTitle(self.tr("Convert paletted image to RGB")) self.outSelector.setType(self.outSelector.FILE) # set the default QSpinBoxes and QProgressBar value self.bandSpin.setValue(1) self.progressBar.setValue(0) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.colorsSpin, SIGNAL("valueChanged(int)"), self.colorsCheck, "-1"), # hide this option (self.bandSpin, SIGNAL("valueChanged(int)"), self.bandCheck) ]) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect(self.batchCheck, SIGNAL("stateChanged( int )"), self.switchToolMode)
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "rgb2pct.py") # set the default QSpinBoxes and QProgressBar value self.colorsSpin.setValue(2) self.progressBar.setValue(0) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus( [ (self.inputLayerCombo, [ SIGNAL("currentIndexChanged(int)"), SIGNAL("editTextChanged(const QString &)") ] ), (self.outputFileEdit, SIGNAL("textChanged(const QString &)")), (self.colorsSpin, SIGNAL("valueChanged(int)"), self.colorsCheck), ] ) self.connect(self.selectInputFileButton, SIGNAL("clicked()"), self.fillInputFile) self.connect(self.selectOutputFileButton, SIGNAL("clicked()"), self.fillOutputFileEdit) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) self.fillInputLayerCombo()
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "pct2rgb.py") # we use one widget for two tools self.base.setWindowTitle( self.tr( "Convert paletted image to RGB" ) ) self.outSelector.setType( self.outSelector.FILE ) # set the default QSpinBoxes and QProgressBar value self.bandSpin.setValue(1) self.progressBar.setValue(0) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.colorsSpin, SIGNAL("valueChanged(int)"), self.colorsCheck, "-1"), # hide this option (self.bandSpin, SIGNAL("valueChanged(int)"), self.bandCheck) ]) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode )
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "rgb2pct.py") self.outSelector.setType(self.outSelector.FILE) # set the default QSpinBoxes and QProgressBar value self.colorsSpin.setValue(2) self.progressBar.setValue(0) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.colorsSpin, SIGNAL("valueChanged(int)"), self.colorsCheck), (self.bandSpin, SIGNAL("valueChanged(int)"), self.bandCheck, "-1" ) # hide this option ]) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect(self.batchCheck, SIGNAL("stateChanged( int )"), self.switchToolMode)
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.resampling_method = ('nearest', 'average', 'gauss', 'cubic', 'average_mp', 'average_magphase', 'mode') self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "gdaladdo") # set the default QSpinBoxes and QProgressBar value self.progressBar.setValue(0) self.jpegQualitySpin.setValue(80) self.progressBar.hide() # we don't need load to canvas functionality self.base.loadCheckBox.hide() self.setParamsStatus([ (self.inSelector, SIGNAL("filenameChanged()")), (self.algorithmCombo, SIGNAL("currentIndexChanged( int )"), self.algorithmCheck), (self.levelsEdit, SIGNAL("textChanged( const QString & )")), (self.roModeCheck, SIGNAL("stateChanged( int )"), None, "1.6.0"), (self.rrdCheck, SIGNAL("stateChanged(int)")), (self.jpegQualitySpin, SIGNAL("valueChanged (int)")), (self.jpegQualityContainer, None, self.tiffjpegCheck), (self.jpegQualityContainer, None, None, "1.7.0"), (self.cleanCheck, SIGNAL("stateChanged(int)"), None, "1.7.0") ]) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.batchCheck, SIGNAL("stateChanged( int )"), self.switchToolMode)
def __init__(self, iface, commandName, helpFileBaseName = None): BaseBatchWidget.__init__(self, iface, commandName, helpFileBaseName) layerMap = QgsMapLayerRegistry.instance().mapLayers() self.layerList = [] for name, layer in layerMap.iteritems(): if layer.type() == QgsMapLayer.RasterLayer: self.layerList.append( unicode( layer.name() ) )
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.resampling_method = ('near', 'bilinear', 'cubic', 'cubicspline', 'lanczos') self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "gdalwarp") self.outSelector.setType(self.outSelector.FILE) # set the default QSpinBoxes and QProgressBar value self.widthSpin.setValue(3000) self.heightSpin.setValue(3000) self.progressBar.setValue(0) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus([ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.sourceSRSEdit, SIGNAL("textChanged(const QString &)"), self.sourceSRSCheck), (self.selectSourceSRSButton, None, self.sourceSRSCheck), (self.targetSRSEdit, SIGNAL("textChanged(const QString &)"), self.targetSRSCheck), (self.selectTargetSRSButton, None, self.targetSRSCheck), (self.resamplingCombo, SIGNAL("currentIndexChanged(int)"), self.resamplingCheck), (self.cacheSpin, SIGNAL("valueChanged(int)"), self.cacheCheck), ([self.widthSpin, self.heightSpin], SIGNAL("valueChanged(int)"), self.resizeGroupBox), (self.multithreadCheck, SIGNAL("stateChanged(int)")), (self.noDataEdit, SIGNAL("textChanged( const QString & )"), self.noDataCheck), (self.maskSelector, SIGNAL("filenameChanged()"), self.maskCheck, "1.6.0"), ]) self.connect(self.inSelector, SIGNAL("layerChanged()"), self.fillSourceSRSEditDefault) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect(self.selectSourceSRSButton, SIGNAL("clicked()"), self.fillSourceSRSEdit) self.connect(self.selectTargetSRSButton, SIGNAL("clicked()"), self.fillTargetSRSEdit) self.connect(self.maskSelector, SIGNAL("selectClicked()"), self.fillMaskFile) self.connect(self.batchCheck, SIGNAL("stateChanged( int )"), self.switchToolMode)
def onFinished(self, exitCode, status): if not self.isBatchEnabled(): BaseBatchWidget.onFinished(self, exitCode, status) return oldFile = QFile( self.inFiles[self.batchIndex] ) newFile = QFile( self.outFiles[self.batchIndex] ) if oldFile.remove(): newFile.rename(self.inFiles[self.batchIndex]) BaseBatchWidget.onFinished(self, exitCode, status)
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.canvas = self.iface.mapCanvas() self.expand_method = ( 'gray', 'rgb', 'rgba' ) self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "gdal_translate") self.outSelector.setType( self.outSelector.FILE ) # set the default QSpinBoxes and QProgressBar value self.outsizeSpin.setValue(25) self.progressBar.setValue(0) self.progressBar.hide() self.formatLabel.hide() self.formatCombo.hide() if Utils.Version( Utils.GdalConfig.version() ) < "1.7": index = self.expandCombo.findText('gray', Qt.MatchFixedString) if index >= 0: self.expandCombo.removeItem(index) self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus( [ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.targetSRSEdit, SIGNAL("textChanged(const QString &)"), self.targetSRSCheck), (self.selectTargetSRSButton, None, self.targetSRSCheck), (self.creationOptionsTable, [SIGNAL("cellValueChanged(int, int)"), SIGNAL("rowRemoved()")], self.creationGroupBox), (self.outsizeSpin, SIGNAL("valueChanged(const QString &)"), self.outsizeCheck), (self.nodataSpin, SIGNAL("valueChanged(int)"), self.nodataCheck), (self.expandCombo, SIGNAL("currentIndexChanged(int)"), self.expandCheck, "1.6.0"), (self.sdsCheck, SIGNAL("stateChanged(int)")), (self.srcwinEdit, SIGNAL("textChanged(const QString &)"), self.srcwinCheck), (self.prjwinEdit, SIGNAL("textChanged(const QString &)"), self.prjwinCheck) ] ) #self.connect(self.canvas, SIGNAL("layersChanged()"), self.fillInputLayerCombo) self.connect(self.inSelector, SIGNAL("layerChanged()"), self.fillTargetSRSEditDefault) self.connect( self.inSelector, SIGNAL( "selectClicked()" ), self.fillInputFile ) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect(self.selectTargetSRSButton, SIGNAL("clicked()"), self.fillTargetSRSEdit) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode ) # add raster filters to combo self.formatCombo.addItems( Utils.FileFilter.allRastersFilter().split( ";;" ) )
def __init__(self, iface): QWidget.__init__(self) self.iface = iface self.resampling_method = ('near', 'bilinear', 'cubic', 'cubicspline', 'lanczos') self.setupUi(self) BaseBatchWidget.__init__(self, self.iface, "gdalwarp") self.outSelector.setType( self.outSelector.FILE ) # set the default QSpinBoxes and QProgressBar value self.widthSpin.setValue(3000) self.heightSpin.setValue(3000) self.progressBar.setValue(0) self.progressBar.hide() self.outputFormat = Utils.fillRasterOutputFormat() self.setParamsStatus( [ (self.inSelector, SIGNAL("filenameChanged()")), (self.outSelector, SIGNAL("filenameChanged()")), (self.sourceSRSEdit, SIGNAL("textChanged(const QString &)"), self.sourceSRSCheck), (self.selectSourceSRSButton, None, self.sourceSRSCheck), (self.targetSRSEdit, SIGNAL("textChanged(const QString &)"), self.targetSRSCheck), (self.selectTargetSRSButton, None, self.targetSRSCheck), (self.resamplingCombo, SIGNAL("currentIndexChanged(int)"), self.resamplingCheck), (self.cacheSpin, SIGNAL("valueChanged(int)"), self.cacheCheck), ( [self.widthSpin, self.heightSpin], SIGNAL( "valueChanged(int)" ), self.resizeGroupBox ), (self.multithreadCheck, SIGNAL("stateChanged(int)")), (self.noDataEdit, SIGNAL( "textChanged( const QString & )" ), self.noDataCheck), (self.maskSelector, SIGNAL("filenameChanged()"), self.maskCheck, "1.6.0"), ] ) self.connect(self.inSelector, SIGNAL("layerChanged()"), self.fillSourceSRSEditDefault) self.connect(self.inSelector, SIGNAL("selectClicked()"), self.fillInputFile) self.connect(self.outSelector, SIGNAL("selectClicked()"), self.fillOutputFileEdit) self.connect(self.selectSourceSRSButton, SIGNAL("clicked()"), self.fillSourceSRSEdit) self.connect(self.selectTargetSRSButton, SIGNAL("clicked()"), self.fillTargetSRSEdit) self.connect(self.maskSelector, SIGNAL("selectClicked()"), self.fillMaskFile) self.connect( self.batchCheck, SIGNAL( "stateChanged( int )" ), self.switchToolMode )
def show_(self): BaseBatchWidget.show_(self) self.someValueChanged()
def getBatchOutputFileName(self, fn): # get GeoTiff fn = re.sub( r'\.[a-zA-Z]{2,4}$', r'.tif', fn ) return BaseBatchWidget.getBatchOutputFileName( self, fn )
def show_(self): BaseBatchWidget.show_(self) self.someValueChanged()
def runItem(self, index, total): if index >= total: self.outFiles = self.inFiles BaseBatchWidget.runItem(self, index, total)
def getBatchOutputFileName(self, fn): # get GeoTiff fn = QString( fn ).replace( QRegExp( "\.[a-zA-Z]{2,4}$" ), ".tif" ) return BaseBatchWidget.getBatchOutputFileName( self, fn )
def getBatchOutputFileName(self, fn): # get GeoTiff fn = QString( fn ).replace( QRegExp( "\.[a-zA-Z]{2,4}$" ), ".tif" ) return BaseBatchWidget.getBatchOutputFileName( self, fn )