GraphicsView in tabWidget

Bug #1716851 reported by bcag2
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
pyqtgraph
Undecided
Unassigned

Bug Description

Hello,

this report is based on Python3.5.2 (Anaconda 4.2.0 - 64-bit), Qt 5.6 (dev on Ubuntu Xenial, ops on Win7)

I based my code on crosshair/mouse interaction sample (https://github.com/robertsj/poropy/blob/master/pyqtgraph/examples/crosshair.py)

I created an ui with QtDesigner (v4.8.7). I want include a GraphicsView in tabWidget (one tab for a device synoptic access and one tab for my graphicsview).

After convert my .ui qtdesigner with pyuic5 (5.6), I have in my ui_….py :
self.graphicsView = GraphicsWindow(self.my_tabWidget)

It open two windows instead one (as shown in 201706_pyqt_pmp-2fenêtres_reduite.png attached capture):
the first (which I don't want) as soon self.setupUI(self) was executed with the two plot canevas
the second, Qt one (which I want) without any graph

Of course, if I put my GraphicsView directly in my Qt windows, and adapt the line
self.graphicsView = GraphicsWindow()
it works fine… but my HMI should be more user friendly with tabs!

Thank

Bertrand alias bcag2

Revision history for this message
bcag2 (bcag2) wrote :
Revision history for this message
bcag2 (bcag2) wrote :

I just find that (looks same issue but with pyqt4):
https://stackoverflow.com/questions/28318309/embedding-pyqtgraph-into-tab-widget-pyqt

I didn't try given solution yet!

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers