繁体   English   中英

tkinter / customtkinter 中的自定义任务栏图标

[英]custom taskbar icon in tkinter / customtkinter

我正在尝试在tkintercustomtkinter中获取自定义任务栏图标,但找不到方法请帮忙

我试过了:

# importing customtkinter as ctk
import customtkinter as ctk

# creating the root window
root = ctk.CTk()

# creating the root's title
root.title('test')

# seting window icon
root.iconbitmap('C\MyDirecory\MyFolder\favicon.ico')

# how to set taskbar icon?

我尝试了 PyCharm 给我的所有建议,都没有用

不幸的是,这不是一种选择。 如果你想要一个任务栏图标,你必须将你的 .py 文件导出到一个带有你想要的图标的 .exe 文件。 然后它会在您的任务栏上显示正确的图标。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM