@@ -53,7 +53,7 @@ def Main():
53
53
54
54
#sets the preview pane to see the preview portion
55
55
Preview = [ [sg .Menu (menu_def )],
56
- [sg .Column (columm_layout , size = (410 ,100 ), scrollable = True )]]
56
+ [sg .Column (columm_layout , size = (410 ,100 ), scrollable = True ), sg . Table ( values = data , ) ]]
57
57
#sets the layout for the graph settings on the box
58
58
Setting = [[sg .Slider (range = (1 ,650 ), default_value = 650 , size = (10 ,10 ), orientation = 'horizontal' , key = 'height' ,font = ('Helvetica' , 12 )),
59
59
sg .Text (' Name: ' , size = (10 ,1 )), sg .InputText (key = 'graphtitle' , size = (15 ,1 )), sg .Text (' Title of x-axis ' , size = (14 ,1 )),
@@ -97,6 +97,12 @@ def Main():
97
97
#opens up a window to choose a file with the extension .csv
98
98
filename = sg .PopupGetFile ('filename to open' , no_window = True , file_types = (("CSV Files" ,"*.csv" ),))
99
99
100
+ if filename is not None :
101
+ df = pd .read_csv (filename , sep = ',' ,engine = 'python' , header = None )
102
+ data = df .values .tolist ()
103
+
104
+
105
+
100
106
#populates the first box for choosing the x axis
101
107
if filename is not None :
102
108
with open (filename , "r" ) as infile :
0 commit comments