•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Python section within the Software Development category of DaniWeb, a massive community of 391,555 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,620 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Python advertiser:
Views: 1227 | Replies: 4 | Solved
![]() |
•
•
Join Date: Oct 2006
Location: New York City
Posts: 2,553
Reputation:
Rep Power: 7
Solved Threads: 1
I have two questions regarding Tkinter GUIs:
Thank-you in advance for any help\direction offered,
Matty
- I have three buttons in a GUI; at times it seems that the buttons "stick". By this I mean when the mouse is clicked on one it may activate or it may not. They all work correctly in regards to there function(s) but it sometimes takes 2-3 clicks to actually get it to fully respond; I figure that this may have to do with my system, memory resources, or something of that nature. The way in which they tend to not resond sometimes is completely random it seems. Has anyone had this issue before and if so, is their a technique to fix this via code optimization?
- Is there a way to change the color\theme of the border of a frame such as the silver border in the GUI pictured below? This is just a small detail but I would like to be able to have this choice if possible for graphic design reasons. I believe I have read that the color\theme of such a GUI element is system dependent, in this case, Windows XP (the same silver color\theme as my system) Is this indeed true that Tkinter does not allow adjustment of said GUI elements?
Thank-you in advance for any help\direction offered,
Matty
Last edited by mattyd : Feb 8th, 2007 at 2:50 am.
Hi mattyd,
Does that image represent a pygame game wrapped inside a Tkinter widget? Is that what you're trying to do?
Running pygame and Tkinter together can be tricky, as both open new threads that listen for user input, and threading bugs are always the hardest to squash. Without seeing the code, I can't tell you exactly what's wrong; my suggestion would be to try decoupling the pygame module from the Tkinter module and see if the problem persists (in other words, comment out the entire game loop and pygame initialization code, put `print "FLAG"; return` commands in the beginning of each button function, and see if "stickiness" is still an issue). Of course, if you're not mixing pygame and Tkinter please say so and I will reconsider the problem.
Hope that helps.
Does that image represent a pygame game wrapped inside a Tkinter widget? Is that what you're trying to do?
Running pygame and Tkinter together can be tricky, as both open new threads that listen for user input, and threading bugs are always the hardest to squash. Without seeing the code, I can't tell you exactly what's wrong; my suggestion would be to try decoupling the pygame module from the Tkinter module and see if the problem persists (in other words, comment out the entire game loop and pygame initialization code, put `print "FLAG"; return` commands in the beginning of each button function, and see if "stickiness" is still an issue). Of course, if you're not mixing pygame and Tkinter please say so and I will reconsider the problem.
Hope that helps.
Vi veri veniversum vivus vici
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
•
•
•
•
DaniWeb Python Marketplace
- Tkinter, GUI's, Logic... (Python)
- Tkinter Label Access (Python)
- Tkinter Text tags (Python)
- Tkinter: protecting text in the Entry widget (Python)
- advice on a gui app builder (Python)
Other Threads in the Python Forum
- Previous Thread: Picture Won't show up on the Screen
- Next Thread: Horizontal Buttom Placement




Linear Mode