27 mXAttributeComboBox->addItem(
"" );
28 mYAttributeComboBox->addItem(
"" );
46 if ( layer->
layerType() !=
"VectorField" )
56 mXAttributeComboBox->setCurrentIndex( mXAttributeComboBox->findText(
mLayer->
xAttribute() ) );
57 mYAttributeComboBox->setCurrentIndex( mYAttributeComboBox->findText(
mLayer->
yAttribute() ) );
63 mCartesianRadioButton->setChecked(
true );
67 mPolarRadioButton->setChecked(
true );
71 mHeightRadioButton->setChecked(
true );
77 mClockwiseFromNorthRadioButton->setChecked(
true );
81 mCounterclockwiseFromEastRadioButton->setChecked(
true );
87 mDegreesRadioButton->setChecked(
true );
91 mRadiansRadioButton->setChecked(
true );
94 mDistanceUnitWidget->blockSignals(
true );
97 mDistanceUnitWidget->blockSignals(
false );
107 void QgsVectorFieldSymbolLayerWidget::on_mScaleSpinBox_valueChanged(
double d )
116 void QgsVectorFieldSymbolLayerWidget::on_mXAttributeComboBox_currentIndexChanged(
int index )
125 void QgsVectorFieldSymbolLayerWidget::on_mYAttributeComboBox_currentIndexChanged(
int index )
134 void QgsVectorFieldSymbolLayerWidget::on_mCartesianRadioButton_toggled(
bool checked )
139 mXAttributeComboBox->setEnabled(
true );
140 mYAttributeComboBox->setEnabled(
true );
141 mXAttributeLabel->setText(
tr(
"X attribute" ) );
142 mYAttributeLabel->setText(
tr(
"Y attribute" ) );
147 void QgsVectorFieldSymbolLayerWidget::on_mPolarRadioButton_toggled(
bool checked )
152 mXAttributeComboBox->setEnabled(
true );
153 mYAttributeComboBox->setEnabled(
true );
154 mXAttributeLabel->setText(
tr(
"Length attribute" ) );
155 mYAttributeLabel->setText(
tr(
"Angle attribute" ) );
160 void QgsVectorFieldSymbolLayerWidget::on_mHeightRadioButton_toggled(
bool checked )
165 mXAttributeLabel->setText(
"" );
166 mXAttributeComboBox->setEnabled(
false );
167 mYAttributeLabel->setText(
tr(
"Height attribute" ) );
172 void QgsVectorFieldSymbolLayerWidget::on_mDegreesRadioButton_toggled(
bool checked )
181 void QgsVectorFieldSymbolLayerWidget::on_mRadiansRadioButton_toggled(
bool checked )
190 void QgsVectorFieldSymbolLayerWidget::on_mClockwiseFromNorthRadioButton_toggled(
bool checked )
199 void QgsVectorFieldSymbolLayerWidget::on_mCounterclockwiseFromEastRadioButton_toggled(
bool checked )
208 void QgsVectorFieldSymbolLayerWidget::on_mDistanceUnitWidget_changed()
void setXAttribute(const QString &attribute)
void setYAttribute(const QString &attribute)
void setAngleUnits(AngleUnits units)
QIcon iconForField(int fieldIdx) const
Returns an icon corresponding to a field index, based on the field's type and source.
AngleOrientation angleOrientation() const
The output shall be in pixels.
QgsSymbolV2::OutputUnit distanceUnit() const
QString yAttribute() const
QString tr(const char *sourceText, const char *disambiguation, int n)
QgsFields fields() const
Returns the list of fields of this layer.
A symbol layer class for displaying displacement arrows based on point layer attributes.
The output shall be in millimeters.
const QgsMapUnitScale & distanceMapUnitScale() const
The output shall be in map unitx.
void setDistanceMapUnitScale(const QgsMapUnitScale &scale)
Encapsulate a field in an attribute table or data source.
AngleUnits angleUnits() const
QString xAttribute() const
virtual QString layerType() const =0
Returns a string that represents this layer type.
void setDistanceUnit(QgsSymbolV2::OutputUnit unit)
void setAngleOrientation(AngleOrientation orientation)
Represents a vector layer which manages a vector based data sets.
VectorFieldType vectorFieldType() const
void setVectorFieldType(VectorFieldType type)