- in legacy graphic engine, fixed bug that made the old object disappear when a new object was loaded
- in legacy graphic engine, fixed bug that crashed the app when creating a new project
This commit is contained in:
@@ -306,10 +306,21 @@ class PlotCanvasLegacy(QtCore.QObject):
|
||||
self.figure.add_axes(self.axes)
|
||||
self.axes.set_aspect(1)
|
||||
self.axes.grid(True)
|
||||
self.axes.axhline(color=(0.70, 0.3, 0.3), linewidth=2)
|
||||
self.axes.axvline(color=(0.70, 0.3, 0.3), linewidth=2)
|
||||
|
||||
self.adjust_axes(-10, -10, 100, 100)
|
||||
|
||||
# Re-draw
|
||||
self.canvas.draw_idle()
|
||||
|
||||
def redraw(self):
|
||||
"""
|
||||
Created only to serve for compatibility with the VisPy plotcanvas (the other graphic engine, 3D)
|
||||
:return:
|
||||
"""
|
||||
self.clear()
|
||||
|
||||
def adjust_axes(self, xmin, ymin, xmax, ymax):
|
||||
"""
|
||||
Adjusts all axes while maintaining the use of the whole canvas
|
||||
|
||||
Reference in New Issue
Block a user