- double x1[3] = {-1.5, 0, 1.5}; 
- 	double y1[3] = {0, 0, 0}; 
- 	double x2[3] = {0, 0, 0}; 
- 	double y2[3] = {-1.5, 0, 1.5};	 
-   
- 	x_1_line->setSamples(x1,y1,3); 
- 	y_1_line->setSamples(x2,y2,3); 
-   
- 	x_1_line -- >setPen (QPen(QColor(- Qt ::black)- , 1- ,Qt ::DashLine))- ; 
- 	y_1_line -- >setPen (QPen(QColor(- Qt ::black)- , 1- ,Qt ::DashLine))- ; 
-   
- 	x_1_line->attach(ui_plot); 
- 	y_1_line->attach(ui_plot); 
-   
- 	ui_plot->replot(); 
        double x1[3] = {-1.5, 0, 1.5};
	double y1[3] = {0, 0, 0};
	double x2[3] = {0, 0, 0};
	double y2[3] = {-1.5, 0, 1.5};	
	x_1_line->setSamples(x1,y1,3);
	y_1_line->setSamples(x2,y2,3);
	x_1_line->setPen(QPen(QColor(Qt::black),1,Qt::DashLine));
	y_1_line->setPen(QPen(QColor(Qt::black),1,Qt::DashLine));
	x_1_line->attach(ui_plot);
	y_1_line->attach(ui_plot);
	ui_plot->replot();
To copy to clipboard, switch view to plain text mode 
  
				
Bookmarks