Tagged Questions
0
votes
0answers
4 views
Make a click event in python (tkinter)
I'm trying do do a very simple task: Make a button click in python using tkinter.
I have an array of buttons and when I finish an event I want to make a button click event in one of my buttons.
I ...
0
votes
0answers
15 views
Tkinter can't insert into Text Widgets with pack_forget()
My application can receive multiple jobs which it processes using threads. I've created Tabs which contain a Text Widget for each job, but I'm having trouble inserting text into the text widgets.
No ...
1
vote
1answer
24 views
Python - Can't Build Window With All The Items
I've tryied to build a Tkinter form in some universal method, but I got a problem.
First look at my Method's code..
def BuildWindow(title, args, icon):
Window = Tk()
Window.title(title)
...
1
vote
1answer
16 views
Tkinter Radiobutton Text
I have the following code:
class Test:
def __init__(self, master): # master is a Tk or Toplevel instance
self.master, self.typeFrame = master, tk.Frame(master)
self.typeVar = ...
0
votes
2answers
41 views
Trying to understand Python and all its moving parts - What is the difference between Tkinter and Django [closed]
I have a school project where my team needs to build a board game. We want to use Python based on all the good things we have heard. I have been researching MVC frameworks and came across Django (its ...
0
votes
1answer
36 views
Threading with Tkinter
I need to be able to send control c to the new thread that I start. How would I go about this. I can start the thread, but I need to stop like I do in the command line using control c.
from Tkinter ...
1
vote
2answers
45 views
Python tkinter bouncing balls - energy goes to infinity
I have written a Python script which creates a Ball class and then creates instances of it. The balls should bounce off the walls, and later (not implemented yet) off of each other. Note that, ...
0
votes
1answer
48 views
Finding indexes in python
I'm trying to find indexes in python when using tkinter and I keep getting this problem. I know that the line index starts from 1 and the column index starts from 0 but when I try to find the index ...
0
votes
1answer
12 views
bind() in tkinter does not return the expected value
I am trying to pass a variable with a tkinter bind() event on a spinbox. While debugging, I discovered that I failed in passing the variable to the spinbox bind() event handler function. Indeed, the ...
0
votes
1answer
36 views
Python tkinter trace method
I am trying to activate callback function as the user type in to the tkinter entry box. According to effbot.org,
You can use the trace method to attach “observer” callbacks to the
variable. The ...
1
vote
2answers
36 views
Remove command from a button
b1=Button(bla bla bla,command=run_something)
b1.configure (command='')
I want to remove the 'command' from a button so that if pressed nothing happens
how would I do this?
note:
I did not ...
1
vote
0answers
15 views
Tk.winfo() returns wrong screensize / python 2.7.5 on Windows 8
Why does tk.winfo return a screensize of 1280 x 800 ?
I want to run at my native resolution of 1920 x 1200
which I set in the control panel.
Can I change it somehow?
Thank you.
Python 2.7.5 running ...
0
votes
1answer
19 views
deleting text from an edit control in Python 2.7?
How can I program the example below to delete all contents from the Edit box? (this is example is taken from http://www.java2s.com/Code/Python/GUI-Tk/SimpleEditor.htm)
My guess is that one must ...
0
votes
2answers
27 views
tkinter binding event from controller
I am trying to work out an MVC structure for a tkinter program.
I have a view class with an event binding for mouse click as follows
class View():
def __init__(self, root)
self.canvas = ...
0
votes
1answer
21 views
Python 3 tkinter change label text
I am having trouble with using a key binding to change the value of a label or any parameter.
from tkinter import*
class MyGUI:
def __init__(self):
self.__mainWindow = Tk()
#self.fram1 = ...
0
votes
1answer
17 views
Tkinter Canvas must be initialized before its contents. Is it a feature or a bug?
I just came across a strange behavior of Tkinter when debugging my program. If a Frame object is created before a Canvas object and later inserted into that Canvas, it can't be displayed. However if ...
1
vote
1answer
38 views
How to test to see if a top-level window is open?
I'm feeling somewhat like Python programming may not be my thing....
I have created a tkinter GUI that uses a button callback to open another window (other searches say this window should be a ...
1
vote
0answers
17 views
quit function call before mainloop in tkinter multiprocessed script
The script below opens a video file and displays it in a tkinter label. The frame acquisition is made in another process.
My problem is that my quit_() function will succeed in closing the full ...
0
votes
0answers
18 views
Tkinter button image too small
I have a program with some buttons that I want to put images on but when I put the images on the buttons they appear so small that you can't even see them.
Any Ideas?,
Thanks.
0
votes
2answers
32 views
Create a python tkinter window with no X (close) button
I'm writing a 'wizard' type Python Tkinter GUI that collects information from the user and then performs several actions based on the user's entries: file copying, DB updates, etc. The processing ...
1
vote
1answer
35 views
Variable Number of Entry Fields in Tkinter
I'm trying to create a widget that contains an amount of entry fields based on the an aspect of a file that's loaded in.
I've been using
self.e = Entry(self.master);
self.e.pack();
...
0
votes
1answer
36 views
Python tkinter accessing object properties
I am a beginner in python & programming. I am trying to create a template empty windows look a like(sort of!) for my tkinter program.
I have 2 scripts. one is for main program and the other is ...
2
votes
1answer
34 views
Unittest Tkinter File Dialog
Question
Is there any way to automate a tkFileDialog selection to run it through unittest? The following is the only use of tkinter in my application:
root = Tkinter.Tk()
types = [('Comma Separated ...
1
vote
0answers
44 views
How can I print a screenshot in python 3.3
I have a small programm written in pyton 3.3 which opens a window (os = windows 7) with a couple of dynamic buttons. These buttons change color and buttontekst when the are pushed.
I want to put in ...
0
votes
1answer
25 views
pyhton 3 tkinter: check when an entry has the value of a string
I am pretty new to tkinter and I'm wondering if or how this is possible:
I would like to start a function as soon as the entry's value equals the 'target' string.
I currently have a simple window ...
2
votes
0answers
48 views
How do I use variables to assign constant arguments in Python? [duplicate]
I'm creating an application in Python using Tkinter where there will be a grid of buttons, and I'm creating the buttons using nested for loops. When clicked, each button has a callback function which ...
-1
votes
1answer
18 views
Bind method in Tkinter passes an argument when it shouldn't
I'm creating an interface in Python using Tkinter, which consists of a few text entry boxes and a button which has a callback function to process the data that has been entered. In order to improve ...
0
votes
1answer
22 views
if statement causes tkinter program to hang
Using Python 2.7.3, I created the following tkinter code. The code requires the user to input two values into the GUI, which are submitted and the GUI is closed. However I am having problems with ...
1
vote
2answers
71 views
Create reset button for number guessing game
I'm making a number guessing game for a tutorial in Python. I'm new to Python and using Python Shell and version 2.7.5. I've made all the functions besides this one.
I have to make a reset button and ...
0
votes
0answers
16 views
Multiprocessing pool alongside Tkinter GUI
I am looking for a way to keep my GUI alive while some multiprocessing job is running.
I built a programm with a GUI based on Tkinter and have to wait for results from time to time. I managed to run ...