@@ -953,7 +953,7 @@ def airfoil_exited(self, airfoil: Airfoil):
953953 def removeCurve (self , curve ):
954954 self .geo_col .remove_pymead_obj (curve )
955955
956- def exportPlot (self ):
956+ def exportPlot (self , theme : dict ):
957957 color_bar_data = self .color_bar_data
958958 current_min_level , current_max_level = None , None
959959 if color_bar_data is not None :
@@ -968,6 +968,9 @@ def exportPlot(self):
968968 # Get the inputs from the dialog
969969 inputs = dialog .value ()
970970
971+ self .plot .setLabel (axis = "bottom" , text = f"x/c" )
972+ self .plot .setLabel (axis = "left" , text = f"y/c" )
973+
971974 # Create the pyqtgraph ImageExporter object from the airfoil canvas
972975 exporter = pg .exporters .ImageExporter (self .plot )
973976
@@ -993,6 +996,9 @@ def exportPlot(self):
993996 # Export the image
994997 exporter .export (file_path )
995998
999+ # Return the axis labels to their original state
1000+ self .setAxisLabels (theme = theme )
1001+
9961002 # Display success message
9971003 self .gui_obj .disp_message_box (f"Plot saved to { file_path } " , message_mode = "info" )
9981004
@@ -1082,7 +1088,7 @@ def contextMenuEvent(self, event, **kwargs):
10821088 elif res == splitPolyAction and curve is not None :
10831089 self .splitPoly (curve )
10841090 elif res == exportPlotAction :
1085- self .exportPlot ()
1091+ self .exportPlot (theme = self . gui_obj . themes [ self . gui_obj . current_theme ] )
10861092 elif res == makeAirfoilAbsoluteAction :
10871093 self .makeAbsolute ()
10881094 elif res == makeAirfoilRelativeAction :
0 commit comments