Hi...
I am trying to create a line on canvas but it is not being displayed.. i dont understand why it is not getting created... i had created applications using the same idea and they were being created... here it is not the case.. Am i missing something...
{
int xxPoint,xyPoint,yxPoint,yyPoint;
m_pCanvasLine = new Q3CanvasLine(m_pCanvas);
xxPoint = point1.x();
xyPoint = point1.y();
yxPoint = point2.x();
yyPoint = point2.y();
m_pCanvasLine->setPoints(xxPoint,xyPoint,yxPoint,yyPoint);
m_pCanvasLine->show();
resizeContents(400,400);
}
void ImageDraw::drawLine(QPoint point1, QPoint point2)
{
int xxPoint,xyPoint,yxPoint,yyPoint;
m_pCanvasLine = new Q3CanvasLine(m_pCanvas);
xxPoint = point1.x();
xyPoint = point1.y();
yxPoint = point2.x();
yyPoint = point2.y();
m_pCanvasLine->setPoints(xxPoint,xyPoint,yxPoint,yyPoint);
m_pCanvasLine->show();
resizeContents(400,400);
}
To copy to clipboard, switch view to plain text mode
here m_pCanvas is a Canvas Object...
Thank you
Kapil
Bookmarks