Skip to content

Commit

Permalink
Addition of the execute_editor code but not used at this point.
Browse files Browse the repository at this point in the history
  • Loading branch information
PySimpleGUI committed Feb 27, 2021
1 parent 0856ce3 commit 4706935
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions DemoPrograms/Demo_Demo_Programs_Browser.py
Original file line number Diff line number Diff line change
Expand Up @@ -529,27 +529,6 @@ def execute_command_subprocess(command, *args, wait=False, cwd=None):
if err:
print(err.decode("utf-8"))

try:
execute_editor = sg.execute_editor
except:
def execute_editor(file_to_edit, line_number=None):
editor_program = pysimplegui_user_settings.get('-editor program-', None)
if editor_program is not None:
format_string = pysimplegui_user_settings.get('-editor format string-', None)
# if no format string, then just launch the editor with the filename
if not format_string or line_number is None:
execute_command_subprocess(editor_program, file_to_edit)
else:
command = _create_full_editor_command(editor_program, file_to_edit, line_number, format_string)
print('final command line = ', command)
execute_command_subprocess(editor_program, command)

else:
print('No editor has been configured')
return




if __name__ == '__main__':
# https://www.vecteezy.com/free-vector/idea-bulb is where I got the icon
Expand Down

0 comments on commit 4706935

Please sign in to comment.