mirror of https://gitlab.com/pamhyr/pamhyr2
SL: Plots reverse draw order.
parent
17d4b15761
commit
47ec0ac9b5
|
|
@ -73,16 +73,16 @@ class Plot(APlot):
|
|||
[z]
|
||||
)
|
||||
|
||||
for i, zsl in enumerate(z_sl):
|
||||
for i, zsl in enumerate(reversed(z_sl)):
|
||||
self.line_kp_sl.append(None)
|
||||
self.line_kp_sl[i], = self.canvas.axes.plot(
|
||||
x, zsl,
|
||||
label=names[i],
|
||||
linestyle="solid" if i == 0 else "--",
|
||||
label=names[-(i+1)],
|
||||
linestyle="solid" if i == len(names) - 1 else "--",
|
||||
lw=1.8,
|
||||
color='grey' if i == 0 else None
|
||||
color='grey' if i == len(names) - 1 else None
|
||||
)
|
||||
self.canvas.axes.text(x[0] + 0.01, zsl[0] + 0.01, f'{names[i]}')
|
||||
self.canvas.axes.text(x[0] + 0.01, zsl[0] + 0.01, f'{names[-(i+1)]}')
|
||||
|
||||
self.canvas.figure.tight_layout()
|
||||
self.canvas.figure.canvas.draw_idle()
|
||||
|
|
|
|||
|
|
@ -69,13 +69,13 @@ class Plot(APlot):
|
|||
[z_min]
|
||||
)
|
||||
|
||||
for i, z in enumerate(z_sl):
|
||||
for i, z in enumerate(reversed(z_sl)):
|
||||
self.line_kp_sl.append(None)
|
||||
self.line_kp_sl[i], = self.canvas.axes.plot(
|
||||
kp, z,
|
||||
linestyle="solid" if i == 0 else "--",
|
||||
linestyle="solid" if i == len(z_sl) - 1 else "--",
|
||||
lw=1.8,
|
||||
color='grey' if i == 0 else None
|
||||
color='grey' if i == len(z_sl) - 1 else None
|
||||
)
|
||||
|
||||
self.canvas.figure.tight_layout()
|
||||
|
|
|
|||
|
|
@ -68,13 +68,13 @@ class Plot(APlot):
|
|||
[z]
|
||||
)
|
||||
|
||||
for i, zsl in enumerate(z_sl):
|
||||
for i, zsl in enumerate(reversed(z_sl)):
|
||||
self.line_kp_sl.append(None)
|
||||
self.line_kp_sl[i], = self.canvas.axes.plot(
|
||||
x, zsl,
|
||||
linestyle="solid" if i == 0 else "--",
|
||||
linestyle="solid" if i == len(z_sl) - 1 else "--",
|
||||
lw=1.8,
|
||||
color='grey' if i == 0 else None
|
||||
color='grey' if i == len(z_sl) - 1 else None
|
||||
)
|
||||
|
||||
self.canvas.figure.tight_layout()
|
||||
|
|
|
|||
Loading…
Reference in New Issue