askmarkio / deregtext

Creating a simple text editor
0 stars 0 forks source link

Fix "About commands" menu option #5

Closed askmarkio closed 3 months ago

askmarkio commented 3 months ago

When you select the "About commands" menu option, the following error is thrown to the command line:

Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib64/python3.12/tkinter/__init__.py", line 1967, in __call__
    return self.func(*args)
           ^^^^^^^^^^^^^^^^
  File "/home/tirminyl/Development/texty/texteditor.py", line 124, in about_commands
    mb.showinfo(title="All commands", message=commands, width=60, height=40)
  File "/usr/lib64/python3.12/tkinter/messagebox.py", line 88, in showinfo
    return _show(title, message, INFO, OK, **options)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/tkinter/messagebox.py", line 76, in _show
    res = Message(**options).show()
          ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/tkinter/commondialog.py", line 45, in show
    s = master.tk.call(self.command, *master._options(self.options))
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_tkinter.TclError: bad option "-width": must be -default, -detail, -icon, -message, -parent, -title, or -type