Skip to main content
Filter by
Sorted by
Tagged with
1 vote
0 answers
82 views

I have a couple different projects that I am using pystray for, and these icons are grouping together when moving them in the system tray. I've found that this is the case for anything using the ...
phpjunkie's user avatar
  • 475
1 vote
0 answers
126 views

My Python code works fine normally, but after compiling it with PyInstaller, pystray doesn't work. I'm getting the following error: Traceback (most recent call last): File "pystray/_xorg.py&...
YahyaMert's user avatar
0 votes
1 answer
86 views

I've been trying to implement some Windows native functionality using tkinter, pystray and threading and some extra needed libraries unsuccessfully. I'm trying to achieve this functionality: The ...
SirLouen's user avatar
  • 141
1 vote
0 answers
176 views

I have a very simple pystray icon with a menu. (Basicaly the normal example code) Its also working so far. An Icon apears and if I right click it the menu apears. But so far I couldn't find a way to ...
Phillip's user avatar
  • 837
1 vote
1 answer
317 views

Description: So I am using customtkinter library instead of tkinter, the issue I am facing is that I want my tkinter app to be withdrawn when closed if the minimize window checkbox is checked in ...
AshhadDevLab's user avatar
2 votes
2 answers
1k views

Hey i am trying to make a application working in windows. It's basically adjusting your monitor brightness. There is a function provides minimize application. So i have issue about minimize. When ...
Zephyrus's user avatar
4 votes
5 answers
12k views

I am making a mouse jiggler and I can't get acces to the tray icon once the loop in the script is launched. I have asked another question but no one has answered yet, so I kept digging deeper into the ...
Impaler67's user avatar
0 votes
0 answers
125 views

minimal code import sys import threading from fastapi import FastAPI from fastapi.responses import FileResponse from tkinter import * from fastapi.staticfiles import StaticFiles from fastapi....
edwin_uestc's user avatar
3 votes
1 answer
1k views

I want to change the text for an item variably. to do this, i tried to update the menu using update_menu(). unfortunately, this didn't work and i couldn't find anything more detailed in the pystray ...
John332's user avatar
  • 41
6 votes
1 answer
1k views

I am trying to create a pystray menu separator, but I am having a hard time doing so. I have searched here on SO and in its documentation, which I find super confusing and unhelpful and I even tried ...
aurorathorn's user avatar
2 votes
0 answers
54 views

I created a python script that whenever is run creates a tray at the bottom right on Windows 11. some code ... image = PIL.Image.open(r"D:\payDisplay\images\pound_icon.png") icon = pystray....
yahnyshc's user avatar
0 votes
0 answers
120 views

from pystray import MenuItem as item import pystray from PIL import Image import tkinter as tk window = tk.Tk() #아이콘 트레이 행동 def quit_window(icon, item): icon.visible = False icon.stop() #...
Raen Lusa lat's user avatar
2 votes
1 answer
82 views

I have a tkinter app that hides itself in the system tray when closed (X) , and keeps running in the background, I can also bring back the app from hidden tray to the front if I want, and this code ...
Samin Jilani's user avatar
3 votes
1 answer
825 views

I am working on a side project which entails a main process that spawns an HTTP server that keeps listening for events and handles them within an infinite loop. This works as intended and I am now ...
fedmag's user avatar
  • 115
0 votes
0 answers
187 views

I'm trying to add an icon to every menu option in a systray library in Python, pystray. For that I'm using win32 functions, I can sucessfully load an icon with extension .ico using the LoadImage ...
digfish's user avatar
  • 317
0 votes
1 answer
353 views

I am trying to create a navigable tree of folders and subfolders using pystray. I am having trouble creating a recursive menu with pystray. I am getting an error "TypeError: MenuItem.__init__() ...
Collaxd's user avatar
  • 587
2 votes
0 answers
192 views

I have tkinter app which I am trying to add pystary icon. I just implemented it successfully. But I want to call "show window" method from another class not only from the menu item of ...
Gadirli Works's user avatar
-1 votes
1 answer
718 views

I've been trying to complete this simple program and turn it into an exe, but every time I run the exe I receive the following error: Traceback (most recent call last): File "webtest.py", ...
batesburgers's user avatar
5 votes
1 answer
2k views

I want the tray icon to change according to the value of p_out. Specifically depending on its value, I want it to get a different color. Here's the code import pystray import ping3 while True: ...
Douglas Silva's user avatar
-1 votes
1 answer
352 views

I'm using auto-py-to-exe which is based on pyinstaller, trying to make an executable with --onefile, using pystray to make a tray app, but after compiling I get an error that the icon file cannot be ...
Collaxd's user avatar
  • 191
0 votes
0 answers
173 views

I'm new in python/tkinter/pystray. Used following code sample for my test application, run it on Windows 10: # Import the required libraries from tkinter import * from pystray import MenuItem as item ...
Andrey K's user avatar
9 votes
1 answer
3k views

I am working on creating a tkinter window when the pystray icon is pressed so I can make my own Menu in the tray. But I have no idea how to get if the tray icon is pressed. Any help is appreciated! ...
vSteppY's user avatar
  • 91
0 votes
0 answers
137 views

import pystray from PIL import Image from importlib import reload import os import webbrowser # Image for the tray image = Image.open("image.png") # Triggers for right click def stop(icon, ...
Neon Blade's user avatar
6 votes
1 answer
2k views

I have an issue with finding a way to change the pystray tray notification title. It appears that it's taking a default value of "Python" from somewhere. See the image below: In the ...
noszone's user avatar
  • 312
2 votes
1 answer
2k views

I am using PyInstaller to create a single file exe for my python application. I am also using Pystray to create a tray icon with a menu on it. When running the script directly it works, but when I use ...
Developer Gee's user avatar
2 votes
1 answer
645 views

I'm trying to open a Toplevel window with tkinter, from a system tray menu. from cmath import phase from tkinter import * from tkinter import messagebox, messagebox from tracemalloc import start from ...
nigel239's user avatar
  • 1,925
2 votes
2 answers
2k views

I need the program to be opened by double clicking on the tray icon. Like this: def show(icon, item): icon.stop() root.after(0, root.deiconify()) icon = pystray.Icon("name", ...
Pan's user avatar
  • 23
2 votes
2 answers
3k views

I'm trying to use pystray without blocking the main thread. Based on the pystray docs we can use the function run_detached() to start without blocking. I'm using pystray on windows so, apparently I ...
JonLord's user avatar
  • 195
1 vote
1 answer
718 views

I'm trying to pass extra arguments to a function that is called by an item in pystray menu. import pystray from pystray import MenuItem as item from PIL import Image, ImageTk def show_window(icon): ...
JonLord's user avatar
  • 195
0 votes
1 answer
2k views

Following this post, I've implemented to minimize the window of a app to system tray. However, i don't figured out how to restore the window by clicking in the system's tray icon. Only opening the ...
Andre Lucato's user avatar
1 vote
1 answer
1k views

I´ve built a simple GUI app, and I´m playing with pystray. Actually, my script starts as usual, the first thing you see is the GUI. If you klick on exit, the GUI minimize, and the tray Icon spawns. ...
iWischMob's user avatar
0 votes
1 answer
1k views

So after I compiled the program I wrote using pyinstaller in one-file mode, The program doesn't seem to function at all. When I try to execute it, I receive the following Exception in a Window: ...
Insertx2k_Dev's user avatar
2 votes
1 answer
1k views

I require a code, to launch tray icon and execute other parts of codes... So for that I tried below: from pystray import MenuItem as item import pystray from PIL import Image, ImageDraw import time ...
Rabe's user avatar
  • 87
1 vote
1 answer
1k views

Here is my sample code: image = Image.open("E:\\production\\Windows utility tool\\images\\icon.ico") menu = (item("Sign in", show_window), item("Change status", ...
Krunal Chauhan's user avatar
1 vote
0 answers
172 views

I have a basic python script, Its a speech recognition script to let me shutdown my pc through voice commands and some additional stuff to have a tray icon. I have provided all of the code entirely as ...
Alp Orgun's user avatar
2 votes
1 answer
2k views

I've written a program using tkinter which when the main window is closed is supposed to be minimized to the system tray. But when I try to exit the program clicking "Close" in the tray that ...
DGDays's user avatar
  • 76
0 votes
1 answer
159 views

I want to make tray icon with pystray. Howerer, it doesnt seem to work. I dont wonna make this question too long, so I gonna put error here. Code i'm using: ... import sys import pystray from pystray ...
MajliTech's user avatar
1 vote
0 answers
1k views

I'm writing a Python program which periodically scrapes a website for a single number, which is then displayed in the system tray via Pystray. I can make it do what I want using threading but would it ...
Jack Deeth's user avatar
  • 3,508
1 vote
0 answers
69 views

I am trying to make a small weather app. Everything going perfect with my codes, except when i used this code to have a systray icon: from pystray import MenuItem as item import pystray def ...
Crazy Mido's user avatar
4 votes
1 answer
212 views

Having issue with pyautogui and pystray. Using python Version 3.6.4. Simply importing both modules into the same script and calling any pyautogui function produces an error. Is there a fix to this or ...
Not Applicable's user avatar
3 votes
1 answer
791 views

I am running a PYSTRAY icon which starts a console program. When I try stopping it with this code def stop_rtd(): print("Stopping RTD") sys.exit() icon.stop() The system throws ...
Tej's user avatar
  • 31
3 votes
2 answers
2k views

from tkinter import* from tkinter import filedialog import tkinter.ttk as ttk import datetime import os import pystray from pystray import MenuItem as item import win32com.client import PIL.Image as ...
김유빈's user avatar
1 vote
1 answer
2k views

Using: Python (3.7.5) Pyinstaller (3.5) Pywin32 (223) Pystray (Current) I have a python program that uses Pystray to show an icon which allows me to make Tkinter window available. It took a while ...
Matthew Baker's user avatar
5 votes
1 answer
13k views

I want to use pystray module in Python to create a system tray app on Windows. Code Until now I managed to write this: import pystray from PIL import Image image = Image.open("image.gif") ...
Jakub Bláha's user avatar
  • 1,619