Skip to content

Commit

Permalink
Removed icon from title bar
Browse files Browse the repository at this point in the history
  • Loading branch information
HuyHung1408 committed May 29, 2022
1 parent 70ca8d9 commit 9d5a404
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,18 @@
import darkdetect
import sv_ttk
import ntkutils

import tempfile
import calculations as c

ICON = (b'\x00\x00\x01\x00\x01\x00\x10\x10\x00\x00\x01\x00\x08\x00h\x05\x00\x00'
b'\x16\x00\x00\x00(\x00\x00\x00\x10\x00\x00\x00 \x00\x00\x00\x01\x00'
b'\x08\x00\x00\x00\x00\x00@\x05\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
b'\x00\x01\x00\x00\x00\x01') + b'\x00'*1282 + b'\xff'*64

_, ICON_PATH = tempfile.mkstemp()
with open(ICON_PATH, 'wb') as icon_file:
icon_file.write(ICON)

def aot():
if always_on_top.get() == 1:
root.attributes('-topmost', True)
Expand Down Expand Up @@ -40,7 +49,7 @@ def btnEqualsInput(event=None):
root.resizable(False, False)
root.geometry('318x480')
root.title('')
root.iconbitmap(r'icon.ico')
root.iconbitmap(default=ICON_PATH)
ntkutils.placeappincenter(root)

if darkdetect.theme() == "Dark":
Expand Down

0 comments on commit 9d5a404

Please sign in to comment.