@@ -93,14 +93,10 @@ def __extract_values_from_help_string(self):
93
93
self .value_dict [target_name + "_" + value_name ] = ""
94
94
# self.type_dict[target_name + "_" + value_name] = value_type
95
95
96
- def get_as_button (
97
- self , wizard , main_screen_obj , parent_frame : tk .Frame , all_buttons : List [tk .Button ]
98
- ) -> tk .Button :
96
+ def get_as_button (self , wizard , main_screen_obj , parent_frame : tk .Frame , all_buttons : List [tk .Button ]) -> tk .Button :
99
97
button = tk .Button (parent_frame , text = self .value_dict ["label" ])
100
98
button .config (
101
- command = lambda : self .highlight_and_update_notebook_screens (
102
- wizard , main_screen_obj , button , all_buttons
103
- )
99
+ command = lambda : self .highlight_and_update_notebook_screens (wizard , main_screen_obj , button , all_buttons )
104
100
)
105
101
self .button = button
106
102
return button
@@ -129,12 +125,8 @@ def highlight_and_update_notebook_screens(
129
125
self .show_details_screen (wizard , main_screen_obj )
130
126
131
127
# update results screen of pressed configuration button and set results tab state based on result existence
132
- main_screen_obj .notebook .tab (
133
- main_screen_obj .results_frame , state = self .__button_state_from_result_existence ()
134
- )
135
- main_screen_obj .notebook .tab (
136
- main_screen_obj .optimizer_frame , state = self .__button_state_from_result_existence ()
137
- )
128
+ main_screen_obj .notebook .tab (main_screen_obj .results_frame , state = self .__button_state_from_result_existence ())
129
+ main_screen_obj .notebook .tab (main_screen_obj .optimizer_frame , state = self .__button_state_from_result_existence ())
138
130
139
131
if self .__button_state_from_result_existence () == "normal" :
140
132
show_suggestions_overview_screen (wizard , main_screen_obj .results_frame , self )
@@ -153,69 +145,51 @@ def show_details_screen(self, wizard, main_screen_obj):
153
145
canvas .grid (row = 1 )
154
146
155
147
# show labels
156
- tk .Label (
157
- canvas , text = "Label:" , justify = tk .RIGHT , anchor = "e" , font = wizard .style_font_bold_small
158
- ).grid (row = 1 , column = 1 , sticky = "ew" )
159
- tk .Label (canvas , text = "Description" , justify = tk .RIGHT , anchor = "e" ).grid (
160
- row = 2 , column = 1 , sticky = "ew"
148
+ tk .Label (canvas , text = "Label:" , justify = tk .RIGHT , anchor = "e" , font = wizard .style_font_bold_small ).grid (
149
+ row = 1 , column = 1 , sticky = "ew"
161
150
)
151
+ tk .Label (canvas , text = "Description" , justify = tk .RIGHT , anchor = "e" ).grid (row = 2 , column = 1 , sticky = "ew" )
162
152
tk .Label (
163
153
canvas ,
164
154
text = "Executable name:" ,
165
155
justify = tk .RIGHT ,
166
156
anchor = "e" ,
167
157
font = wizard .style_font_bold_small ,
168
158
).grid (row = 3 , column = 1 , sticky = "ew" )
169
- tk .Label (canvas , text = "Executable arguments:" , justify = tk .RIGHT , anchor = "e" ).grid (
170
- row = 4 , column = 1 , sticky = "ew"
171
- )
172
- tk .Label (canvas , text = "Make flags:" , justify = tk .RIGHT , anchor = "e" ).grid (
173
- row = 5 , column = 1 , sticky = "ew"
174
- )
159
+ tk .Label (canvas , text = "Executable arguments:" , justify = tk .RIGHT , anchor = "e" ).grid (row = 4 , column = 1 , sticky = "ew" )
160
+ tk .Label (canvas , text = "Make flags:" , justify = tk .RIGHT , anchor = "e" ).grid (row = 5 , column = 1 , sticky = "ew" )
175
161
tk .Label (
176
162
canvas ,
177
163
text = "Project path:" ,
178
164
justify = tk .RIGHT ,
179
165
anchor = "e" ,
180
166
font = wizard .style_font_bold_small ,
181
167
).grid (row = 6 , column = 1 , sticky = "ew" )
182
- tk .Label (canvas , text = "Project linker flags:" , justify = tk .RIGHT , anchor = "e" ).grid (
183
- row = 7 , column = 1 , sticky = "ew"
184
- )
185
- tk .Label (canvas , text = "Make target:" , justify = tk .RIGHT , anchor = "e" ).grid (
186
- row = 8 , column = 1 , sticky = "ew"
187
- )
168
+ tk .Label (canvas , text = "Project linker flags:" , justify = tk .RIGHT , anchor = "e" ).grid (row = 7 , column = 1 , sticky = "ew" )
169
+ tk .Label (canvas , text = "Make target:" , justify = tk .RIGHT , anchor = "e" ).grid (row = 8 , column = 1 , sticky = "ew" )
188
170
tk .Label (
189
171
canvas ,
190
172
text = "Memory Profiling:" ,
191
173
justify = tk .RIGHT ,
192
174
anchor = "e" ,
193
175
font = wizard .style_font_bold_small ,
194
176
).grid (row = 9 , column = 1 , sticky = "ew" )
195
- tk .Label (canvas , text = "Skip function params:" , justify = tk .RIGHT , anchor = "e" ).grid (
196
- row = 10 , column = 1 , sticky = "ew"
197
- )
177
+ tk .Label (canvas , text = "Skip function params:" , justify = tk .RIGHT , anchor = "e" ).grid (row = 10 , column = 1 , sticky = "ew" )
198
178
tk .Label (
199
179
canvas ,
200
180
text = "Additional:" ,
201
181
justify = tk .RIGHT ,
202
182
anchor = "e" ,
203
183
font = wizard .style_font_bold_small ,
204
184
).grid (row = 11 , column = 1 , sticky = "ew" )
205
- tk .Label (canvas , text = "Tags:" , justify = tk .RIGHT , anchor = "e" ).grid (
206
- row = 12 , column = 1 , sticky = "ew"
207
- )
208
- tk .Label (canvas , text = "Notes:" , justify = tk .RIGHT , anchor = "e" ).grid (
209
- row = 13 , column = 1 , sticky = "ew"
210
- )
185
+ tk .Label (canvas , text = "Tags:" , justify = tk .RIGHT , anchor = "e" ).grid (row = 12 , column = 1 , sticky = "ew" )
186
+ tk .Label (canvas , text = "Notes:" , justify = tk .RIGHT , anchor = "e" ).grid (row = 13 , column = 1 , sticky = "ew" )
211
187
212
188
# show input fields
213
189
label = tk .Entry (canvas )
214
190
label .grid (row = 1 , column = 2 , sticky = "ew" )
215
191
label .insert (tk .END , self .value_dict ["label" ])
216
- create_tool_tip (
217
- label , "Name of the configuration. Used to distinguish configurations in the main menu."
218
- )
192
+ create_tool_tip (label , "Name of the configuration. Used to distinguish configurations in the main menu." )
219
193
220
194
description = tk .Entry (canvas )
221
195
description .grid (row = 2 , column = 2 , sticky = "ew" )
@@ -235,8 +209,7 @@ def show_details_screen(self, wizard, main_screen_obj):
235
209
executable_args .insert (tk .END , self .value_dict ["executable_arguments" ])
236
210
create_tool_tip (
237
211
executable_args ,
238
- "Specify arguments which shall be forwarded to the call of the created executable for the "
239
- "profiling." ,
212
+ "Specify arguments which shall be forwarded to the call of the created executable for the " "profiling." ,
240
213
)
241
214
242
215
make_flags = tk .Entry (canvas )
@@ -250,28 +223,23 @@ def show_details_screen(self, wizard, main_screen_obj):
250
223
project_path = tk .Entry (canvas )
251
224
project_path .grid (row = 6 , column = 2 , sticky = "ew" )
252
225
project_path .insert (tk .END , self .value_dict ["project_path" ])
253
- create_tool_tip (
254
- project_path , "Path to the project which shall be analyzed for potential parallelism."
255
- )
226
+ create_tool_tip (project_path , "Path to the project which shall be analyzed for potential parallelism." )
256
227
257
228
def overwrite_with_selection (target : tk .Entry ):
258
229
prompt_result = tk .filedialog .askdirectory ()
259
230
if len (prompt_result ) != 0 :
260
231
target .delete (0 , tk .END )
261
232
target .insert (0 , prompt_result )
262
233
263
- project_path_selector = tk .Button (
264
- canvas , text = "Select" , command = lambda : overwrite_with_selection (project_path )
265
- )
234
+ project_path_selector = tk .Button (canvas , text = "Select" , command = lambda : overwrite_with_selection (project_path ))
266
235
project_path_selector .grid (row = 6 , column = 3 )
267
236
268
237
project_linker_flags = tk .Entry (canvas )
269
238
project_linker_flags .grid (row = 7 , column = 2 , sticky = "ew" )
270
239
project_linker_flags .insert (tk .END , self .value_dict ["linker_flags" ])
271
240
create_tool_tip (
272
241
project_linker_flags ,
273
- "Linker flags which need to be passed to the build system in order to create a valid "
274
- "executable." ,
242
+ "Linker flags which need to be passed to the build system in order to create a valid " "executable." ,
275
243
)
276
244
277
245
make_target = tk .Entry (canvas )
@@ -281,9 +249,7 @@ def overwrite_with_selection(target: tk.Entry):
281
249
282
250
mpsfp_var = tk .IntVar ()
283
251
mpsfp_var .set (self .value_dict ["memory_profiling_skip_function_parameters" ])
284
- memory_profiling_skip_function_parameters = tk .Checkbutton (
285
- canvas , onvalue = 1 , offvalue = 0 , variable = mpsfp_var
286
- )
252
+ memory_profiling_skip_function_parameters = tk .Checkbutton (canvas , onvalue = 1 , offvalue = 0 , variable = mpsfp_var )
287
253
memory_profiling_skip_function_parameters .grid (row = 10 , column = 2 , sticky = "w" )
288
254
create_tool_tip (
289
255
memory_profiling_skip_function_parameters ,
@@ -415,9 +381,7 @@ def save_changes(
415
381
self .value_dict ["working_copy_path" ] = self .value_dict ["project_path" ] + "/.discopop"
416
382
self .value_dict ["linker_flags" ] = project_linker_flags .get ()
417
383
self .value_dict ["make_target" ] = make_target .get ()
418
- self .value_dict [
419
- "memory_profiling_skip_function_parameters"
420
- ] = memory_profiling_skip_function_parameters .get ()
384
+ self .value_dict ["memory_profiling_skip_function_parameters" ] = memory_profiling_skip_function_parameters .get ()
421
385
self .value_dict ["tags" ] = tags .get ()
422
386
self .value_dict ["notes" ] = additional_notes .get ("1.0" , tk .END )
423
387
@@ -491,12 +455,8 @@ def execute_configuration(
491
455
# create execution view and update results frame
492
456
ExecutionView (self , wizard , main_screen_obj .results_frame )
493
457
# set results tab state based on result existence
494
- main_screen_obj .notebook .tab (
495
- main_screen_obj .results_frame , state = self .__button_state_from_result_existence ()
496
- )
497
- main_screen_obj .notebook .tab (
498
- main_screen_obj .optimizer_frame , state = self .__button_state_from_result_existence ()
499
- )
458
+ main_screen_obj .notebook .tab (main_screen_obj .results_frame , state = self .__button_state_from_result_existence ())
459
+ main_screen_obj .notebook .tab (main_screen_obj .optimizer_frame , state = self .__button_state_from_result_existence ())
500
460
501
461
# show results tab
502
462
main_screen_obj .notebook .select (main_screen_obj .results_frame )
0 commit comments