diff options
Diffstat (limited to 'kmplot/kmplot/diagr.cpp')
-rw-r--r-- | kmplot/kmplot/diagr.cpp | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/kmplot/kmplot/diagr.cpp b/kmplot/kmplot/diagr.cpp index ba65fce8..144e73b0 100644 --- a/kmplot/kmplot/diagr.cpp +++ b/kmplot/kmplot/diagr.cpp @@ -45,9 +45,9 @@ int isinf(double x) CDiagr::CDiagr() { - frameColor=qRgb(0, 0, 0); - axesColor=qRgb(0, 0, 0); - gridColor=qRgb(192, 192, 192); + frameColor=tqRgb(0, 0, 0); + axesColor=tqRgb(0, 0, 0); + gridColor=tqRgb(192, 192, 192); borderThickness=2; axesLineWidth = Settings::axesLineWidth(); gridLineWidth = Settings::gridLineWidth(); @@ -416,7 +416,7 @@ void CDiagr::drawLabels(TQPainter* pDC) int n; TQString s; - //pDC->drawText(x-dx, y+dy, 0, 0, Qt::AlignRight|Qt::AlignVCenter|Qt::DontClip, "0"); + //pDC->drawText(x-dx, y+dy, 0, 0, TQt::AlignRight|TQt::AlignVCenter|TQt::DontClip, "0"); char draw_next=0; TQFontMetrics const test(font); int swidth=0; @@ -463,7 +463,7 @@ void CDiagr::drawLabels(TQPainter* pDC) else draw_next=0; } - pDC->drawText(Transx(d), y+dy, 0, 0, Qt::AlignCenter|Qt::DontClip, s); + pDC->drawText(Transx(d), y+dy, 0, 0, TQt::AlignCenter|TQt::DontClip, s); } else if(fabs(ex-M_PI/3.)<1e-3) { @@ -497,7 +497,7 @@ void CDiagr::drawLabels(TQPainter* pDC) else draw_next=0; } - pDC->drawText(Transx(d), y+dy, 0, 0, Qt::AlignCenter|Qt::DontClip, s); + pDC->drawText(Transx(d), y+dy, 0, 0, TQt::AlignCenter|TQt::DontClip, s); } else if(fabs(ex-M_PI/4.)<1e-3) { @@ -531,7 +531,7 @@ void CDiagr::drawLabels(TQPainter* pDC) else draw_next=0; } - pDC->drawText(Transx(d), y+dy, 0, 0, Qt::AlignCenter|Qt::DontClip, s); + pDC->drawText(Transx(d), y+dy, 0, 0, TQt::AlignCenter|TQt::DontClip, s); } else if((n%5==0 || n==1 || n==-1 || draw_next)) { @@ -552,14 +552,14 @@ void CDiagr::drawLabels(TQPainter* pDC) else draw_next=0; } - pDC->drawText(Transx(d), y+dy, 0, 0, Qt::AlignCenter|Qt::DontClip, s); + pDC->drawText(Transx(d), y+dy, 0, 0, TQt::AlignCenter|TQt::DontClip, s); } } if(ymax<0 && xmax<0) - pDC->drawText(Transx(xmax)-(4*dx), y+(dy-20), 0, 0, Qt::AlignCenter|Qt::DontClip, "x"); + pDC->drawText(Transx(xmax)-(4*dx), y+(dy-20), 0, 0, TQt::AlignCenter|TQt::DontClip, "x"); else - pDC->drawText(Transx(xmax)-dx, y+dy, 0, 0, Qt::AlignCenter|Qt::DontClip, "x"); + pDC->drawText(Transx(xmax)-dx, y+dy, 0, 0, TQt::AlignCenter|TQt::DontClip, "x"); for(d=tsy, n=(int)ceil(ymin/ey); d<ymd; d+=ey, ++n) { @@ -588,9 +588,9 @@ void CDiagr::drawLabels(TQPainter* pDC) else continue; if (xmin>=0) - pDC->drawText(x+dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignLeft|Qt::DontClip, s); + pDC->drawText(x+dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignLeft|TQt::DontClip, s); else - pDC->drawText(x-dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignRight|Qt::DontClip, s); + pDC->drawText(x-dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignRight|TQt::DontClip, s); } else if(fabs(ey-M_PI/3.)<1e-3) { @@ -609,9 +609,9 @@ void CDiagr::drawLabels(TQPainter* pDC) else continue; if (xmin>=0) - pDC->drawText(x+dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignLeft|Qt::DontClip, s); + pDC->drawText(x+dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignLeft|TQt::DontClip, s); else - pDC->drawText(x-dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignRight|Qt::DontClip, s); + pDC->drawText(x-dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignRight|TQt::DontClip, s); } else if(fabs(ey-M_PI/4.)<1e-3) { @@ -630,24 +630,24 @@ void CDiagr::drawLabels(TQPainter* pDC) else continue; if (xmin>=0) - pDC->drawText(x+dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignLeft|Qt::DontClip, s); + pDC->drawText(x+dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignLeft|TQt::DontClip, s); else - pDC->drawText(x-dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignRight|Qt::DontClip, s); + pDC->drawText(x-dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignRight|TQt::DontClip, s); } else if((n%5==0 || n==1 || n==-1)) { s=TQString().sprintf("%+0.3g", n*ey); if (xmin>=0) - pDC->drawText(x+dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignLeft|Qt::DontClip, s); + pDC->drawText(x+dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignLeft|TQt::DontClip, s); else - pDC->drawText(x-dx, Transy(d), 0, 0, Qt::AlignVCenter|Qt::AlignRight|Qt::DontClip, s); + pDC->drawText(x-dx, Transy(d), 0, 0, TQt::AlignVCenter|TQt::AlignRight|TQt::DontClip, s); } } if(ymax<0 && xmax<0) - pDC->drawText(x-dx, Transy(ymax)+(2*dy), 0, 0, Qt::AlignVCenter|Qt::AlignRight|Qt::DontClip, "y"); + pDC->drawText(x-dx, Transy(ymax)+(2*dy), 0, 0, TQt::AlignVCenter|TQt::AlignRight|TQt::DontClip, "y"); else if (xmin>0) - pDC->drawText(x-(2*dx), Transy(ymax)+dy, 0, 0, Qt::AlignVCenter|Qt::AlignRight|Qt::DontClip, "y"); + pDC->drawText(x-(2*dx), Transy(ymax)+dy, 0, 0, TQt::AlignVCenter|TQt::AlignRight|TQt::DontClip, "y"); else - pDC->drawText(x-dx, Transy(ymax)+dy, 0, 0, Qt::AlignVCenter|Qt::AlignRight|Qt::DontClip, "y"); + pDC->drawText(x-dx, Transy(ymax)+dy, 0, 0, TQt::AlignVCenter|TQt::AlignRight|TQt::DontClip, "y"); } |