GraphicsLayoutWidget#

class pyqtgraph.GraphicsLayoutWidget(
parent=None,
show=False,
size=None,
title=None,
**kargs,
)[source]#

Convenience class consisting of a GraphicsView with a single GraphicsLayout as its central item.

This widget is an easy starting point for generating multi-panel figures. Example:

w = pg.GraphicsLayoutWidget()
p1 = w.addPlot(row=0, col=0)
p2 = w.addPlot(row=0, col=1)
v = w.addViewBox(row=1, col=0, colspan=2)

parent

(QWidget or None) The parent widget.

show

(bool) If True, then immediately show the widget after it is created. If the widget has no parent, then it will be shown inside a new window.

size

(width, height) tuple. Optionally resize the widget. Note: if this widget is placed inside a layout, then this argument has no effect.

title

(str or None) If specified, then set the window title for this widget.

kargs

All extra arguments are passed to GraphicsLayout.__init__

This class wraps several methods from its internal GraphicsLayout: nextRow nextColumn addPlot addViewBox addItem getItem addLabel addLayout removeItem itemIndex clear

__init__(
parent=None,
show=False,
size=None,
title=None,
**kargs,
)[source]#