@@ -332,7 +332,7 @@ void ProfilePlot::setDefocusValue(double val){
332332 m_plot->replot ();
333333 }
334334}
335- QPolygonF ProfilePlot::createAverageProfile (double umnits, wavefront *wf , bool removeNull = false ){
335+ QPolygonF ProfilePlot::createAverageProfile (double /* umnits*/ , wavefront * /* wf */ , bool /* removeNull = false*/ ){
336336 surfaceAnalysisTools *saTools = surfaceAnalysisTools::get_Instance ();
337337 QList<int > list = saTools->SelectedWaveFronts ();
338338 QPolygonF avg;
@@ -518,7 +518,7 @@ void ProfilePlot::populate()
518518 compass->setGeometry (QRect (80 ,80 ,70 ,70 ));
519519 QString tmp (" nanometers" );
520520 if (m_showNm == 1 .)
521- tmp = QString (). sprintf ( " waves of %6.1lf nm" , outputLambda);
521+ tmp = QString (" waves of %1 nm" ). arg ( outputLambda, 6 , ' f ' , 1 );
522522 m_plot->setAxisTitle ( m_plot->yLeft , " Error in " + tmp );
523523 m_plot->setAxisTitle ( m_plot->xBottom , " Radius mm" );
524524
@@ -536,7 +536,9 @@ void ProfilePlot::populate()
536536
537537 if (m_wf->m_outside .m_radius > 0 && settings.value (" GBlur" , false ).toBool ()){
538538 double val = .01 * (m_wf->diameter ) * smoothing;
539- QString t = QString ().sprintf (" Surface Smoothing diameter %6.2lf%% of surface diameter %6.1lf mm" , smoothing , val );
539+ QString t = QString (" Surface Smoothing diameter %1% of surface diameter %2 mm" )
540+ .arg (smoothing, 6 , ' f' , 2 )
541+ .arg (val, 6 , ' f' , 1 );
540542 QwtText title (t);
541543 title.setRenderFlags ( Qt::AlignHCenter | Qt::AlignTop );
542544
@@ -587,7 +589,6 @@ void ProfilePlot::populate()
587589
588590 surfaceAnalysisTools *saTools = surfaceAnalysisTools::get_Instance ();
589591 QList<int > list = saTools->SelectedWaveFronts ();
590- bool firstPlot = true ;
591592 QColor penColor = QColor (" blue" );
592593
593594 for (int indx = 0 ; indx < list.size (); ++indx){
@@ -789,7 +790,6 @@ void ProfilePlot::contourPointSelected(const QPointF &pos){
789790 double dely = pos.y () - m_wf->data .cols /2 ;
790791
791792 double angle = atan2 (delx,dely); // swaped x and y to rotate by 90 deg.
792- double angle2 = angle;
793793 const double twopi = M_PI * 2 .;
794794 // force 0 to 360
795795 if (angle < 0 )
@@ -806,11 +806,13 @@ void ProfilePlot::contourPointSelected(const QPointF &pos){
806806}
807807void ProfilePlot::showCorrection (){
808808 if (m_wf == 0 )
809+ {
809810 return ;
811+ }
810812
811- m_pcdlg->show ();
812- m_pcdlg->raise ();
813- make_correction_graph ();
813+ m_pcdlg->show ();
814+ m_pcdlg->raise ();
815+ make_correction_graph ();
814816
815817
816818}
0 commit comments