Add window icon

This commit is contained in:
No Time To Play 2022-12-08 14:30:52 +00:00
parent 5c208c00d1
commit 360faced41
2 changed files with 12 additions and 0 deletions

BIN
scrunch.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 199 B

View File

@ -159,6 +159,17 @@ top.option_add('*tearOff', FALSE)
top["padx"] = 4
#top["pady"] = 4
icon_data = """
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAADFBMVEUAAAD/AACAgID///8+Fw++
AAAABHRSTlP/AP//07BylAAAAGZJREFUOMvN01EKwCAMA9Ca3v/OcxsD20azjwnLr09sKFoTsRfA
F5EAN7AhEoABR08/u0LBmXx5CyBdpgD8idqlzpAm+RY4ULugbDN1YSB0oWCcZAd4usxB3OyfgUOB
sM2GRfTvPgAY2wicuMw+DAAAAABJRU5ErkJggg==
"""
app_icon = PhotoImage(data=icon_data)
if sys.version_info.major >= 3:
top.iconphoto("", app_icon)
toolbar = ttk.Frame(top)
workspace = ttk.PanedWindow(top, orient=HORIZONTAL)
@ -855,6 +866,7 @@ top.bind("<Control-f>", lambda e: handle_find())
top.bind("<Control-g>", lambda e: find_again())
editor.bind("<Command-y>", lambda e: editor.edit_redo())
editor.bind("<Command-v>", lambda e: paste_content())
editor.bind("<Command-a>", lambda e: select_all(editor))
top.bind("<Command-f>", lambda e: handle_find())
top.bind("<Command-g>", lambda e: find_again())