From: Jorge G. <cl...@us...> - 2007-05-24 20:29:01
|
Update of /cvsroot/easycalc/easycalc In directory sc8-pr-cvs17:/tmp/cvs-serv14755 Modified Files: graph.c Log Message: Fixed bug Index: graph.c =================================================================== RCS file: /cvsroot/easycalc/easycalc/graph.c,v retrieving revision 1.56 retrieving revision 1.57 diff -C2 -d -r1.56 -r1.57 *** graph.c 11 May 2007 10:50:58 -0000 1.56 --- graph.c 24 May 2007 20:28:55 -0000 1.57 *************** *** 354,365 **** if(!isnan(y)) { ! Coord xx=graph_xgr2scr(x); Coord y0=graph_ygr2scr(0.0); - Coord yy=graph_ygr2scr(y); ! if(xx>ScrPrefs.xmax || xx<ScrPrefs.xmin) break; /* polar, parametric or DRAW_AT_ONCE !=1 */ ! if(yy<ScrPrefs.ymax || isinf(y)>0){ if(y0<=ScrPrefs.ymax) break; if(y0>=ScrPrefs.ymin) y0=ScrPrefs.ymin; --- 354,364 ---- if(!isnan(y)) { ! Coord yy,xx; Coord y0=graph_ygr2scr(0.0); ! if(x>graphPrefs.xmax || x<graphPrefs.xmin) break; /* polar, parametric or DRAW_AT_ONCE !=1 */ ! if(y>graphPrefs.ymax){ if(y0<=ScrPrefs.ymax) break; if(y0>=ScrPrefs.ymin) y0=ScrPrefs.ymin; *************** *** 367,371 **** yy=ScrPrefs.ymax; } ! else if(yy>ScrPrefs.ymin || isinf(y)<0){ if(y0>=ScrPrefs.ymin) break; if(y0<=ScrPrefs.ymax) y0=ScrPrefs.ymax; --- 366,370 ---- yy=ScrPrefs.ymax; } ! else if(y<graphPrefs.ymin){ if(y0>=ScrPrefs.ymin) break; if(y0<=ScrPrefs.ymax) y0=ScrPrefs.ymax; *************** *** 374,377 **** --- 373,377 ---- } else{ + yy=graph_ygr2scr(y); if(y0<=ScrPrefs.ymax) y0=ScrPrefs.ymax; else if(y0>=ScrPrefs.ymin) y0=ScrPrefs.ymin; *************** *** 379,382 **** --- 379,383 ---- } + xx=graph_xgr2scr(x); clie_drawline(xx,y0,xx,yy); } |