Hi Martin.
I tried the setXlink and viewbox linkedViewChanged, as is showed at the
example link that you shared to me.
Didn't work, mi method to update data and 'view size' is in plot_station.py
and is this:
```
def setData(self, data):
for name, axis in self.map_axis.items():
data_axis = data[name]
curve = getattr(self, axis)
if curve:
timelist = [a for a,b in data_axis]
valuelist = [b for a,b in data_axis]
curve.setData(
x=timelist,
y=valuelist)
self.p1.setAutoVisible()
self.p2.setAutoVisible()
self.p3.setAutoVisible()
# self.p2.setGeometry(self.p1.vb.sceneBoundingRect())
# self.p3.setGeometry(self.p2.vb.sceneBoundingRect())
self.p2.vb.linkedViewChanged(self.p1.vb, self.p2.vb.XAxis)
self.p3.vb.linkedViewChanged(self.p2.vb, self.p3.vb.XAxis)
```
The las two lines are, if I understand correctly, the linked to the chart
on the left and positionen acordly it.
But the problem can'y be resolved in that way.
This happend when I put more than 10 rows, so ...
There some more mannually form to assign a % for every item in a row?
Best regards!
David Pineda Osorio
Ingeniero Civil Electricista
Ingeniero en área Geodesia del Centro Sismológico
f: +56 9 82142267
El lun, 13 jun 2022 a las 17:58, Martin Chase (<[email protected]>)
escribió:
> Hola David,
>
> Have you tried `setXLink`? Probably somewhere in your
> `StationLayoutWidget` class, I'm guessing, but it'll work anywhere you have
> access to all the plots you want linked together. Here's an example:
> https://github.com/pyqtgraph/pyqtgraph/blob/master/pyqtgraph/examples/MultiplePlotAxes.py#L23
>
> Buena suerte,
> - Martin (he/him)
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "pyqtgraph" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/pyqtgraph/ip_uoZzLTgE/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pyqtgraph/CAD_p8v2YVR%3DDEC47SuiXR9ndTY6XMza7LyDnTZtvrxs5vG8ViQ%40mail.gmail.com
> <https://groups.google.com/d/msgid/pyqtgraph/CAD_p8v2YVR%3DDEC47SuiXR9ndTY6XMza7LyDnTZtvrxs5vG8ViQ%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>
--
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/CA%2B1671%3Dai_7_zH3tXtdpD%2BPZD4PUn6t4_n6zzrqKK%2BJpbXqPuA%40mail.gmail.com.