1,133 Topics
![]() | |
So I have to enter a lot of text for display by Tkinter, and I've been rather miffed that I can't seem to find a way to get Eclipse (PyDev) to do any kind of auto-wrapping. Wrapping the lines myself with [inlinecode]"string1" + \ "string2"[/inlinecode] is, of course, beyond annoying. … | |
How can I let the Tkinter Button command do more than one function? | |
Hi, I want to create a little Frame class that has two labels built in, the code snippet below is the class. [CODE=python] class DescriptionFrame(Frame): def __init__(self, master, title="", text=""): Frame.__init__(master) self.title = title self.text = text self.titleLabel = Label(self, text=self.title, font=("Times", 12, "underline"), fg="darkred") self.titleLabel.grid(row=0, column=0, sticky=W) self.mainLabel = … | |
hi all , I like to write a program which I input the dates and amounts of say 10 checks , and print out the total amount of checks and number of days thet are apart from each other on another entry widget . the code I have done sofar … | |
Hi, Im having trouble with the piece of code below, i want to have the image change every time you press the button. This code is from a larger project but this is the bit that i cant get to work. Any ideas? [code=python]import Tkinter import random import Image, ImageTk … | |
sigh... I need a way to make an image as a background for a window, and still be able to put buttons and other controls on top of it. I even tried using wxPython's wxPanel, but it proved a real pain because I found the documentation very sparce...:sad: (google didn't … | |
Thanks to mawe and Jeff for answering my first question. Next question: is there a way to get Tkinter to display the window without a title bar? I'm an experimental psychologist, and I don't want my participants to easily be able to exit my experiments... so hints on disabling alt-tab … | |
[code] from Tkinter import* Label(text=u'\u2208').pack() mainloop() [/code] i am trying to do that same in Wx, but i always get UnicodeError: [code] import wx okno = wx.App(0) frame=wx.Frame(None) wx.StaticBox(frame,label=u'\u2208') frame.Show(True) okno.MainLoop() [/code] and the eror is: [code] Traceback (most recent call last): File "C:\Documents and Settings\Blu\Plocha\aa.py", line 4, in -toplevel- … | |
hi , thanks for the code , I have changed it a little bit , I have also added two buttons (+,-) I have written the code for (+) but it does not work , can you tell me what the problem is , the last lines which are commented … | |
I've been having a lot of trouble with the [inlinecode]after[/inlinecode] method. What I want to do is show a series of images at the push of a button/press of a key -- each image should appear for 500ms, then be replaced by the next image, which should go on indefinitely … | |
I have an image being displayed in a Tkinter window. I need a way to add letters to the image in certain spots depending on what is done by the user. Example: if button 1 is pressed, the peoples names appear over their heads, but I can't just switch the … | |
Hi, I'm a noob Python/Tkinter user, and I'm finding that gathering information on the two is not as easy as I'd like... hopefully you guys will be able to help. My first question: I was just wondering if there's a way to tell Python, "take all the files in X … | |
How would one create a simple spreadsheet with Tkinter? | |
I am at the end of a build and am putting some minor touches on and testing; one area I suppose I took for granted (and have honestly not seen a need yet to fully deal with) is the Tkinter buttons. The buttons perform fine overall as to their function; … | |
Is there a way to preselect/highlight a listbox item with the Tkinter GUI toolkit at the startup of the program without clicking the mouse on it? | |
Hi. I've just registered, but I'm not exactly new to here (i've been lurking as a guest). I'm trying to make a countdown timer based on a class that I created, which accepts hours, minutes, and seconds as parameters and counts them down to zero, will displaying them in a … | |
I am searching for the syntax that will allow me to arrange widget buttons in a Tkinter GUI in a specific manner; currently I have three (3) buttons that are stacked[I] vertically[/I] on top of one another. I wish to arrange the buttons so that they form a row of … | |
[U][B]I have two questions regarding Tkinter GUIs[/B][/U]:[LIST=1] [*]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 [I]may not[/I]. They all work correctly in regards to there function(s) but … | |
hi everybody , I am new to python and interested in graphics . I like somebody to walk me thru monthly calendar using tkinter . I have already printed 07 calendar using python but I am stuck when it comes to use it with tkinter . it is no homework … | |
I keep reading threads here, some use the Tkinter GUI toolkit and others use the wxPython GUI toolkit. Why would one use one or the other? | |
I know wxpython is supposed to be better than tkinter, but I can't find any easy to understand tutorials on how to begin using wxpython. But anyway. How can I get tkinter to load up a jpg? | |
I want to make a Tkinter button respond to a left and right mouse click differently. How can I do this? | |
How can I make a Tkinter window take up all my display screen area? | |
My program won't read the listbox correctly. The output from the print statements are as follows: [QUOTE]Dronfield Sheffield 2.20 ('1',)[/QUOTE] I want the list item "B-line" to = 1, but due to the wierdness of the value, it reads it as ('1',) It is meant to read from the passinfo.txt … | |
My current GUI program, in part, will display a button which the user may choose to press (or not, in some cases): [code] btn1 = Button(root ,bg="Black", text="HIT", image=image01,command=show_image2) btn1.configure(state=NORMAL,background='red' ) btn1.pack() [/code] This is basic and works fine. The issue I am having is that after the button is … | |
How can I best center a Tkinter window on my display screen? | |
I have made a list of names and everytime i want to select a value in the listbox it should give me a result in the Entry box can someone please help me. This is my listbox values [code] musicfolder = [ ["CollegeRock/"], ['RnB/'], ['HipHop/'], ['Build/'], ['Buy/'], ['Techno/'], ['Jazz/'], ['Classic/'] … | |
Simply, I need to understand the basics of button binding. I have researched [URL="http://www.pythonware.com/library/tkinter/introduction/events-and-bindings.htm"]this[/URL] already and have decided just to ask for instruction. For example, one of the programs I am building currently will require, at a certain point, user input; I want to be able to know when a … | |
Hi all, I know there have been several threads about getting card images into a GUI, but I'm flustered trying to understand why some things work and some things don't. Here's the code: [php] import random from Tkinter import * import Image, ImageTk class Card(object): suits = ["C","D","H","S"] values = … | |
Hi all, In the never-ending quest to master Tkinter, I wrote a small version of Notepad. Here is my "SaveAs" function: [php] def save_as(): if not mainw.filename: mainw.filename = tkFileDialog.asksaveasfilename(title="Save As...", filetypes=[("All Files","*.*"),("Text Files","*.txt")]) if not mainw.filename: return f = open(mainw.filename, "w") s = mainw.frame.edit.get("1.0",END) f.write(s) f.close() [/php] As you … | |
I have been working on a GUI-based program using Tkinter; it is coming along nicely and I am very pleased with the results. I am at a point where I am trying to attempt a graphic manipulation of the GUI canvas. I have researched this but I am unsure what … | |
As you can see, I am playing around with the Tkinter GUI toolkit. How can I keep a number of widgets fixed in a location even when the user expands the window? | |
Is there a way to make a Tkinter GUI window that the user can not change the size of? | |
I have been working on a somewhat small Python GUI for a few weeks now primarily focusing on the GUI and not giving much in-depth thought to the logic of what is to be a simple card game. I assumed the logic to be in my head and in general … | |
I am writing a small tkinter-app involving user keyboard-input, and want to control the range of acceptable input-characters. I'm currently using an Entry-widget, but haven't been able to access the individual characters AS THEY ARE ENTERED. What I (think I:confused:) need is somthing like the 'command=' option (as in the … | |
sharky_machine Offline Posting Whiz in Training Join Date: Oct 2006 Location: New York City Posts: 253 Rep Power: Re: Starting Python Today, 1:41 pm | Add to sharky_machine's Reputation | Add Infraction | Flag Bad Post | IP | #86 -------------------------------------------------------------------------------- Vegaseat: I have been reviewing this code you had … | |
Hi, I tried to run following script of drawing a sin/cos curve using python 2.4 , there is error: [B][COLOR=red]Traceback (most recent call last): File "", line 6, in ? File "C:\Python24\Lib\lib-tk\Tkinter.py", line 1564, in __init__ baseName = os.path.basename(sys.argv[0]) AttributeError: 'module' object has no attribute 'argv'[/COLOR][/B] [B][COLOR=blue]Can anybody tell me … | |
When coding in Tkinter, you can make a button, then when the button is pressed, it refers to something that you defined, or whatever its called when you use the def statement. What I'm wondering, is if there is a way to do this in non Tkinter programing. I am … | |
Last night I took the advice of a DaniWeb member and looked at some posted Python code; this code was based around a card-type game and involved creating a GIF deck, shuffling, then displaying it. My original question had to do with using a Python dict for my GIF images. … | |
I have a directory with many subdirectories. Each subdirectory contains a small number of image files (.jpg). I would like to accumulate all these image files in a Tkinter listbox, sort them and be able to select blocks of files and send them to another listbox. Ultimately I would like … | |
I am a programmer but have just recently ventured into the realm of graphics programming using Python; what I have learned so far is fascinating. It is so thrilling to see a coded design appear on the screen in full color. But, I find, making an image appear is one … | |
Is it possible to use files such as GIF files as a value in a Python Dict; that is, is it possible to use GIF files in a Dict and access them directly, rendering them to the screen via Tkinter. I have a group of GIF files I plan to … | |
I have a data file with chemical names (one name per line) and want to load that into a Tkinter GUI listbox and then be able to select it by clicking on the line. Need some help. | |
I am experimenting (playing around) with the Python Tkinter Gui, and wondered if there is a way to play a sound like from a .wav or .au file? | |
Which Graphics User Interface (GUI) would you recommend for a beginner? I have seen some examples of Tkinter, wxPython and GTK. | |
So I wanted to write some code to provide a framework for math quizzes. Among other things, I wanted to be able to show LaTeX-like output on a canvas. But first, I just wanted to get the canvas showing simple text. Part of the code: [php] def get_level_string(self): return self.f1.level_text.get() … | |
How would I manipulate an entry widget so that it hides the entered characters behind asterisks? like this: Typed: PassWord Displayed as typing occurs: ******** I'm trying to make a dialog box module, for use in some future programs. I want the user to be the only one to know … | |
The attached program uses buttons to take you to a set of links. The links that the three buttons point to are here, gamefaqs and toontown. You can customise by altering the links and button names within the code, this is just practice. What do you think? | |
Greetings: I have been working with code examples (from the good people on this site) and I have been learning quite a bit about Python and becoming more comfortable with. The program I am working on is being done in pieces, the GUI being really the primary area of problems … | |
Hello again: I seek assistance on what I believed would be an easy problem to solve, but, after much searching, I have not yet discovered a valid answer: I have a canvas which consists of a background GIF upon which (when triggered) at least one new (smaller) GIF will appear, … |
The End.