Geometry: Plot: Fix x axes.

mesh
Pierre-Antoine Rouby 2023-06-07 16:04:01 +02:00
parent 6c9657af66
commit f28e1c4586
2 changed files with 10 additions and 1 deletions

View File

@ -52,6 +52,10 @@ class PlotKPC(APlot):
z_min = self.data.get_z_min()
z_max = self.data.get_z_max()
self.canvas.axes.set_xlim(
left = min(kp), right = max(kp)
)
self.line_kp_zmin_zmax = self.canvas.axes.vlines(
x=kp,
ymin=z_min, ymax=z_max,

View File

@ -52,6 +52,11 @@ class PlotXY(APlot):
color='green', fontsize=12
)
kp = self.data.get_kp()
self.canvas.axes.set_xlim(
left = min(kp), right = max(kp)
)
# Draw line for each profile
self.line_xy = [
self.canvas.axes.plot(
@ -61,7 +66,7 @@ class PlotXY(APlot):
)
for x, y, kp in zip(
self.data.get_x(), self.data.get_y(),
self.data.get_kp()
kp
)
]