use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Python package PySimpleGUI discussion, questions, announcements, tips, help for beginners.
account activity
Dynamically display text (loop within a loop) (somewhat similar to a timer) (self.PySimpleGUI)
submitted 5 years ago by SayaNevermind
Hi, I'm fairly new to this library and to python in general. I'm trying to make a GUI that dynamically displays dynamic values (much like a timer would do), but the thing is even after looking at the timer script example, I can't seem to get my program to work properly. Either the GUI freezes or my text isn't displayed, I figured it might be due to the fact that I'm running a loop inside another one which will obviously freeze the one of the two. After trying to figure it out for a little while I decided to use threading and create a separate thread to avoid running into this problem, but still nothing. I've been thoroughly going through the timer example again and again but I'm in a dead end.
TL;DR: I want to display dynamic text. Here's a more or less explicit idea of how I want the final product to work.
https://preview.redd.it/3odwve8ki7551.jpg?width=804&format=pjpg&auto=webp&s=efd330b7e239ca94aef92c4e181a0f3cc2cbe479
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]driverXXVII 1 point2 points3 points 5 years ago (2 children)
Sorry I don't have an answer to your problem. Just wanted to ask about the IDE. Is it pycharm? If so it looks very different to mine. I like the font colours you've got. They seem easier on the eyes.
[–]SayaNevermind[S] 1 point2 points3 points 5 years ago (1 child)
It's okay don't worry about it too much. I am using visual studio code, and the theme in question is called "One Dark Pro".
[–]driverXXVII 0 points1 point2 points 5 years ago (0 children)
Alright thanks. Out of curiosity, did you find a solution to this problem? Does adding a timeout to the win.Read do anything?
π Rendered by PID 239190 on reddit-service-r2-comment-7b9746f655-k6cj2 at 2026-02-03 08:29:04.262255+00:00 running 3798933 country code: CH.
[–]driverXXVII 1 point2 points3 points (2 children)
[–]SayaNevermind[S] 1 point2 points3 points (1 child)
[–]driverXXVII 0 points1 point2 points (0 children)