renderText fix

This commit is contained in:
Mark Watkins 2011-08-07 09:22:06 +10:00
parent 9f5317ac18
commit 35ab3ef6bb
3 changed files with 3 additions and 3 deletions

View File

@ -138,7 +138,7 @@ void gFlagsLine::Plot(gGraphWindow & w,float scrx,float scry)
float x,y;
GetTextExtent(m_label,x,y);
w.qglColor(Qt::black);
w.renderText(start_px-x-10,(line_top)+(line_h/2)-(y/2),0,m_label);
w.renderText(start_px-x-10,(scry-line_top)-(line_h/2)+(y/2),m_label);
//DrawText(w,m_label,start_px-x-10,(scry-line_top)-(line_h/2)+(y/2));
float x1,x2;

View File

@ -165,7 +165,7 @@ void gXAxis::Plot(gGraphWindow & w,float scrx,float scry)
}
}
w.renderText(px-(x/2),(w.GetBottomMargin()-18),0,tmpstr);
w.renderText(px-(x/2),scry-(w.GetBottomMargin()-18),tmpstr);
//DrawText(w,tmpstr,px-(x/2),scry-(w.GetBottomMargin()-18),0);
py=px;
for (int j=1;j<10;j++) {

View File

@ -150,7 +150,7 @@ void gYAxis::Plot(gGraphWindow &w,float scrx,float scry)
GetTextExtent(fd,x,y);
if (x>labelW) labelW=x;
h=start_py+ty;
w.renderText(start_px-12-x,h-(y/2.0),0,fd);
w.renderText(start_px-12-x,scry-(h-(y/2.0)),fd);
//DrawText(w,fd,start_px-12-x,scry-(h-(y/2.0)),0,m_text_color);
vertarray[vertcnt++]=start_px-4;