I'm attempting to export the contents of a full window or layout. The 
layout consists of a central ImageView with x and y axes. I'm able to 
export the image but then it ignores the axes and y inversion. For 
instance, something like this will export the central image.

```
from pyqtgraph.Qt import QtGui
import pyqtgraph as pg
import pyqtgraph.exporters
import numpy as np

app = QtGui.QApplication([])
win = QtGui.QMainWindow()
imv = pg.ImageView(view=pg.PlotItem())
img_view = imv.getView()
img_view.invertY(False)
img_view.setLimits(yMin=0, yMax=512)
img_view.getAxis("left").setScale(0.5)
win.setCentralWidget(imv)
win.show()
win.setWindowTitle("Range Plot")
imv.setPredefinedGradient("flame")
imv.setImage(np.zeros((2000, 513)), xvals=[i for i in range(2000)])
imv.setLevels(0, 100)
app.processEvents()
imv.export("plot.png")
```

How can I get this to export the full window as an image (preserving axes, 
aspect ratios, y-inversion, etc.)? Is there some window class or layout on 
which I can call `scene()`? Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"pyqtgraph" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pyqtgraph/7faa1802-d85c-409a-80af-04ee45a2cd1eo%40googlegroups.com.

Reply via email to