I am starting with plplot and Qt, looking at the example examples/c++/README.qt_example

It works correctly and I am now proceeding in creating a custom widget to encapsulate my specific plotting needs. I am directly subclassing QtExtWidget.

The issue is that I require multiple widgets in my application, but I do not know how to handle that... Shall I call multiple plinit() for each widget, having one stream for each widget?
How should I handle subplots?

To start, I am trying splitting the 2 plots drawn in the example in 2 separate widgets with 2 methods to plot different things, but until now it seems that only the second (in order of creation) widget is used, while the first is ignored.

Can someone give me some advices about this, please?