Hi,
I am facing the same problem, did you got any clue ??? pl. share.
Thank you.
Hi,
I am facing the same problem, did you got any clue ??? pl. share.
Thank you.
Hi guys.
Please run this test code.
You will see, the scrollbars comes automatically.
Because the GV cannot show the full line.
I hope you are getting my point.
Qt Code:
#include <QApplication> #include <QGraphicsScene> #include <QGraphicsView> int main(int argc, char *argv[]) { QGraphicsScene scene; scene.addLine(0,0,2000,2000); view.show(); return a.exec(); }To copy to clipboard, switch view to plain text mode
Hi yogeshgokul,
If you add items from scene then it scrolls, that is fine.
The problem I am facing is I am drawing text using QPointer in QGraphicsView::drawForeground(), in this case the text gets cuts towards the rigth side of the view and it is not showing scrollbars.
do you have any idea for this case ?
Thank you.
You have to set the scene size properly and the scrollbars will appear.
Bookmarks