Tagged Questions
0
votes
0answers
10 views
regarding connecting GUI to app code for data aquisiton
Language used: python 2.7
GUI package: Tkinter
Goal: Create a GUI program that will interface with several different DAQ devices.
Right now I am trying to acheive this for only one device.
Current ...
0
votes
0answers
7 views
Python 3.3.2 tkinter ttk TreeView per-column sorting only sorts by last column?
I am trying to get a simplistic ttk TreeView table going with per-column sorting using the heading 'command' tag, but it doesn't seem to work right. I'm using the answer to this question for ...
-1
votes
2answers
17 views
Python Tkinter radiobutton program debugging
Essentially the program is a group of radio buttons and when the user clicks the submit button, the program should return the answer matching the string of choices made by the user. I've gotten it to ...
-1
votes
1answer
16 views
Need help adding a scrollbar to my dice button code
Can someone please give the code to add a scrollbar to my code. I have been searching on the internet for the code but can't find it. Also, is there anyway that I can make it look better. I have the ...
0
votes
1answer
12 views
Python Tkinter changing StringVar value to use it as a background indicator on a UI
I'm building a UI where the users have to select some dates. I've added a row called Date Indicator which shows a box with a color. The starting color (until the user selects both dates) is grey. This ...
0
votes
1answer
47 views
My Variable will not change out side the definition
I wrote my first py code. This code to create a lotto number generator.The problem is that my variable nums will not change. Please help me.
I understand this is not as good as it can be so please ...
-4
votes
0answers
40 views
Can someone please add a scrollbar to my program [on hold]
Can someone please add a scrollbar to my program. I have got the code working, but i want to add a scroll bar to navigate in the tkinter. Also, if there is any way that you can improve my code, would ...
-4
votes
0answers
27 views
After reading a file, how can I put those values on a tkinter window?
I have written two python code. One is to show the values in GUI format, which has 4 headers(i.e 4 Labels). The second code is also a python code. This code is to data mining and at the end its ...
0
votes
2answers
12 views
How can I call a “command” with tkinter.simpledialog?
So I'm trying to create a dialog box that asks the user for an input (a number) with python's built-in Tkinter library. In particular, I googled that this could be easily achieved with the method ...
1
vote
0answers
33 views
Convert Python Code to Use Buttons instead
I have tried but I am not sure how to make this code work using buttons instead of the canvas. Its for a calculator using tkinter. I need to make this work using Buttons but everything i have tried ...
0
votes
2answers
21 views
Image display on tkinter canvas not working
I am trying to write a simple paint program and I have fully functioning save and draw features, though in the open button's method, the msg.create_image function isnt showing the image. THere is no ...
0
votes
1answer
21 views
canvas.delete(ALL) not working
I'm currently making the graphical portion of a poker game in Tkinter with Python 2.7, but I'm having trouble with redrawing the canvas at the moment. For some reason self.canvas.delete(ALL) won't ...
0
votes
0answers
13 views
Dynamic memory allocation when using tkinter
I am having an issue with what seems to be a dynamic allocation of memory. (This will be a little difficult to explain so bear with me.)
Using tkinter, PythonWin and Python 2.6.
I have written a ...
0
votes
0answers
44 views
Python StringVar - get function returning nothing?
I'm making a GUI app using the tkinter module in Python (mainly just to improve my Python skills, we're using it in GCSE Computer Science), however I've hit an annoying issue that I cannot figure out.
...
-1
votes
2answers
32 views
How to pip or easy_install tkinter
My Idle is throwing errors that and says tkinter can't be imported.
Is there a simple way to install tkinter via pip or easy_install?
There seem to be a lot of package names flying around for ...
-5
votes
1answer
38 views
How to put output of python code in the gui format? [on hold]
Hello, this is my codes. the first one is the format in which i want my output to be for the 2nd code ..
sorry to post snapshot of my code ...the main reason is i was unable to upload my code itself ...
0
votes
1answer
28 views
python Tkinter, check if root has been destroyed?
I am writing an application using Tkinter along with threading.
The problem I got is, after closing the main app, some thread is still running, and I need a way to check whether the root windows has ...
0
votes
1answer
15 views
Can't move image with time delay
I'm trying to figure out how to make a scrolling image in python, but I got into some issues with delay. I need the image to move after the canvas has rendered, and I also need it to move with a time ...
0
votes
1answer
22 views
Python - TKinter - Destroying widgets not lowering frame height
I am having and issue where I have a frame in a game that displays the current progress of the game (let's call this frame; "results").
If the player chooses to start a new game all the widgets ...
0
votes
1answer
34 views
Cosinus graph drawing [duplicate]
I'd like to make a program which draws a cosinus graph in orderd range. But there is an error which I'm not able to repair. Error Message: "AttributeError: program instance has no attribute 'mp'" Here ...
0
votes
2answers
27 views
Python - TKinter - Editing Widgets
I need a widget in TKinter to be a global widget, however, I need the text displayed in it to be different every time. I'm quite new with TKinter and haven't yet successfully managed to edit an option ...
0
votes
1answer
22 views
TKinter math output to canvas.create_text
I am trying to calculate a formula and display its output as a table in TKinter. Since it is not working, I am just trying to get a simple result and print it to a canvas widget. When this gets ...
1
vote
0answers
19 views
Python Tkinter wrap widgets in frame if they reach the end of the screen
Is there something like pack to new line for Tk geometry manager? I am using pack to put widgets inside of a frame. On a high resolution screen, the widgets fit find side by side. However, if you put ...
1
vote
1answer
22 views
When I click the button, opening of new forms and writing something
I have a code like that,
#-*- coding: cp857 -*-
from tkinter import *
###########################################################
root=Tk()
root.title("MY FILMS v1")
root.resizable(False, False)
...
0
votes
1answer
19 views
'PolyCollection' object is not callable
So the error I'm getting is TypeError: 'PolyCollection' object is not callable. How do I fix this?
I am trying to create a dynamically updated histogram with Python and Matplotlib, displayed using ...
0
votes
1answer
25 views
Tkinter. How to display clock/hourglass using askopenfilename
I'm using Tkinter.askopenfilename to open a file that contains logon details for a peripheral device. My code takes those details and then logs into that device, navigates through a CLI and downloads ...
1
vote
1answer
35 views
tkinter button height and width
I am trying to create a button and change the height and width using the code below but the actual button doesn't show physically. However if you hover over the area it is supposed to be and click it ...
2
votes
2answers
50 views
How to change the labels of the choices in an option menu?
I have a Tkinter option menu like this:
import Tkinter as tk
choices = [1,2,3]
GUI = tk.Tk()
var2set = tk.IntVar(GUI)
tk.OptionMenu(GUI, var2set, *choices).grid(column=0, row=0)
GUI.mainloop()
Is ...
0
votes
1answer
25 views
Widgets and Commands created by loop
It is two weeks now that I full-time look for a solution to a relevant problem: How to create Commands within dynamic loops? The subject is simple (to image it I took food elements): to initiate the ...
2
votes
1answer
27 views
Display standard output in Tk widget
so when a user clicks a button the for a 4, 6 or 12 sided dice the program will pick a random number between 1 and the users input
i have this working to the T but how can i get the output to ...
2
votes
1answer
21 views
Tkinter StringVar error
Hi i get an error with this code that StringVar() is not defined, and its probably a small thing but i am not that experienced with tkinter and would like some help, thanks.
Here's my code:
import ...
0
votes
0answers
30 views
Can I hide the “Do you want to replace it?” warning when selecting a file with Python's tkFileDialog.asksaveasfilename()
When I select a file to save to using Python's tkFileDialog.asksaveasfilename() I get a warning window, telling me that this file will be replaced (Both the save dialog and the warning window seem to ...
2
votes
1answer
69 views
Collision detection algorithm in python
I am writing a small game, consisting of a labyrinth, a player character and a set number of enemies. Both the PC and the enemies belong to a given class, and they update their movement every several ...
0
votes
1answer
21 views
global variable issues with tkinter python
I am trying to create a simple interface to access the name array with first, last, previous and next functionality. But the global variable I am using as a position tracker is not working. I have ...
0
votes
1answer
18 views
How can I get the widget attribute in Python TK?
I create a button, and set it's callback, but how can I get the attribute of the button like fg?
from Tkinter import *
def callback(self):
# what should I do here?
# color = ?
...
1
vote
1answer
43 views
Unexpected behavior of Tkinter's grid embedded in a canvas with more than 280 elements
I want to display a lot of thumbnails and be able to do different operations on them, depending on the content of the thumbnail. For this I took the example from Adding a scrollbar to a grid of ...
0
votes
2answers
24 views
Exception handling in Tkinter
So, I wrote a small Tkinter program in python. The program executes good, but its easy for an exception to occur if theres a non-digit character entered into a field.
so, I tried to remedy it, but my ...
0
votes
0answers
23 views
Hide Python console when running Tkinter script from shell command
I have extended the file context menu in the Windows registry and added a shortcut to a Python script (which is a Tkinter window). It runs fine, but obviously with the Python console in the ...
-4
votes
0answers
32 views
chat, error when sending a message with sockets and threading python [closed]
error when sending a message with sockets and threading
program char using the library Tkinter
I'm using python 2.7.5
`
from Tkinter import *
import socket
import threading
sock = socket.socket()
...
1
vote
1answer
38 views
How to print Tkinter gui content into printer
I need to print the content of an app created by tkinter.. I mean print the inner window such as top level has a frame which has some entries into my printer on windows 7 or 8...is that possible ??
...
1
vote
1answer
23 views
Python / Tkinter getting text from Enter box
Apologies for the basic nature of the question. Tkinter has me totally stumped.
I'm trying to construct an application with a menu bar, one of the choices would pull up a dialog where the user ...
0
votes
1answer
71 views
How to set the Background image for window in Tkinter
I want to set a background image for a Tkinter window, I've created a root window
import Tkinter
root=Tkinter.Tk()
How to set the background image for "root" window ?
Can we set any type of image ...
2
votes
1answer
59 views
How to get radio button output in Tkinter?
Here is the code which i wrote to have radio button with its option and other widget to see on the gui face...but it is not running. i mean when there is radio button code its not showing on the gui ...
0
votes
3answers
40 views
tkinter 'NoneType' object has no attribute 'pack' (Still works?)
I'm fairly new to Python and have just started to play around with tkinter.
Running the below code I get an attribute error for but1.pack() (NoneType object has no attribute pack). But as far as I can ...
-2
votes
0answers
21 views
Recursive grid using tkinter in python [closed]
I want to make a grid using tkinter in python by using counted loops to make a grid that is a 9X9 sudoku template
0
votes
0answers
17 views
Different WMs and making windows topmost
I've implemented the code I found in another question, and I'm wondering why it works.
This is the code that makes a Tkinter window topmost in mac, and then doesn't when it's idle (if that makes ...
1
vote
1answer
15 views
validatecommand in Tkinter—loop validating?
This is what I have so far
vdcm = (self.register(self.checkForInt), '%S')
roundsNumTB = Entry(self, validate = 'key', validatecommand = vdcm)
Then the checkForInt() function is defined as so
def ...
0
votes
0answers
33 views
Printing two separate scripts to the same console window
I'm writing a large series of automated tests in python and I would like to use a single master script with a gui to call which particular test I want to run.
I'm using subprocess.call(path, ...
4
votes
2answers
66 views
Simple Image viewer
I am new to this site, and I am trying to create a simple image viewer in Python 2.7 using Tkinter, But when I try to load an image in it,it does not show anything!, I bet it is something ...
0
votes
1answer
36 views
Tkinter Add/Remove “windows” within current window
Basically below is what I have right now. The problem is that each of these buttons opens a new window and I would prefer that in the top right I have the current function such as add course shown and ...