Replace
Qt Code:
graphicsView.show(); MainWindow w;To copy to clipboard, switch view to plain text mode
with
Qt Code:
MainWindow w; w.setCentralWidget(&graphicsView);To copy to clipboard, switch view to plain text mode
You created two distinct widgets and showed them.
You need to add the graphics view to the main window.
Bookmarks