1
/***************************************************************************
2
qgsinterpolationdialog.h
3
------------------------
5
copyright : (C) 2008 by Marco Hugentobler
6
email : marco dot hugentobler at karto dot baug dot ethz dot ch
7
***************************************************************************/
9
/***************************************************************************
11
* This program is free software; you can redistribute it and/or modify *
12
* it under the terms of the GNU General Public License as published by *
13
* the Free Software Foundation; either version 2 of the License, or *
14
* (at your option) any later version. *
16
***************************************************************************/
18
#ifndef QGSINTERPOLATIONDIALOG_H
19
#define QGSINTERPOLATIONDIALOG_H
21
#include "ui_qgsinterpolationdialogbase.h"
22
#include "qgsrectangle.h"
23
#include "qgisinterface.h"
26
class QgsInterpolatorDialog;
29
class QgsInterpolationDialog: public QDialog, private Ui::QgsInterpolationDialogBase
33
QgsInterpolationDialog( QWidget* parent, QgisInterface* iface );
34
~QgsInterpolationDialog();
38
void on_buttonBox_accepted();
39
void on_mInputLayerComboBox_currentIndexChanged( const QString& text );
40
void on_mOutputFileButton_clicked();
41
void on_mOutputFileLineEdit_textChanged();
42
void on_mConfigureInterpolationButton_clicked();
43
void on_mInterpolationMethodComboBox_currentIndexChanged( const QString &text );
44
void on_mAddPushButton_clicked();
45
void on_mRemovePushButton_clicked();
47
void on_mNumberOfColumnsSpinBox_valueChanged( int value );
48
void on_mNumberOfRowsSpinBox_valueChanged( int value );
49
void on_mCellsizeXSpinBox_valueChanged( double value );
50
void on_mCellSizeYSpinBox_valueChanged( double value );
51
void on_mBBoxToCurrentExtent_clicked();
53
void on_mXMinLineEdit_textEdited( const QString& text );
54
void on_mXMaxLineEdit_textEdited( const QString& text );
55
void on_mYMinLineEdit_textEdited( const QString& text );
56
void on_mYMaxLineEdit_textEdited( const QString& text );
61
QgisInterface* mIface;
62
/**Dialog to get input for the current interpolation method*/
63
QgsInterpolatorDialog* mInterpolatorDialog;
65
/**Returns the vector layer object with the given name
66
Returns a pointer to the vector layer or 0 in case of error.*/
67
QgsVectorLayer* vectorLayerFromName( const QString& name );
68
/**Enables or disables the Ok button depending on the availability of input layers and the output file*/
69
void enableOrDisableOkButton();
70
/**Get the current output bounding box (might be different to the compound layers bounding box because of user edits)
71
@return the bounding box or an empty bounding box in case of error*/
72
QgsRectangle currentBoundingBox();
73
/**Returns the compound bounding box of the inserted layers*/
74
QgsRectangle boundingBoxOfLayers();
75
/**Inserts the compound bounding box of the input layers into the line edits for the output bounding box*/
76
void setLayersBoundingBox();
77
/**Set cellsizes according to nex bounding box and number of columns / rows */
78
void setNewCellsizeOnBoundingBoxChange();
79
void setNewCellsizeXOnNColumnsChange();
80
void setNewCellsizeYOnNRowschange();
81
void setNColsOnCellsizeXChange();
82
void setNRowsOnCellsizeYChange();