/****************************************************************************
** ui.h extension file, included from the uic-generated form implementation.
**
** If you want to add, delete, or rename functions or slots, use
** Qt Designer to update this file, preserving your code.
**
** You should not define a constructor or destructor in this file.
** Instead, write your code in functions called init() and destroy().
** These will automatically be called by the form's constructor and
** destructor.
*****************************************************************************/
#include <qstring.h>

void ColorMapPlotDialog::loadCurrentValues(float min, bool minFlag, float max , bool maxFlag,unsigned int numberOfLegendBoxes, unsigned int numberAccuracy, bool _legendEnable){
	minLineEdit->setText(QString().setNum(min));
	maxLineEdit->setText(QString().setNum(max));
    if(minFlag){
	minCheckBox->setChecked(true);
    }else{
	minCheckBox->setChecked(false);
	minLineEdit->setEnabled(false);
    }
    
    if(maxFlag){
	maxCheckBox->setChecked(true);

    }else{
	maxCheckBox->setChecked(false);
	maxLineEdit->setEnabled(false);	
    }
    boxSpinBox->setMinValue(2);
    boxSpinBox->setMaxValue(99);
    
    accuracySpinBox->setMinValue(0);
    accuracySpinBox->setMaxValue(5);
	
    boxSpinBox->setValue(numberOfLegendBoxes);
    accuracySpinBox->setValue(numberAccuracy);

      showLegendBox->setChecked(_legendEnable);
    
    if(!showLegendBox->isOn()){
      boxSpinBox->setEnabled(false);
      accuracySpinBox->setEnabled(false);
    }
  return;  
}
