textwidget.tag_bind("name", "", self.donothing) not working
Hi all, For some reason this bind is calling the donothing function, like it should, but is then allowing the text to be inserted into the Text widget. Here is the code: self.framebody.tag_config("name", underline=1) self.framebody.tag_bind("name", "", self.donothing) line = '\t%s' % ('sometext') self.framebody.insert(END, line, "name") def donothing(self): return 'break' This donothing function should keep the tcl bind from inserting the text...at least so I thought. This bind does work on the text widget as a whole, but on a individual tag, it does not. Can anyone help me out with this? Thanks in advance, Shannon -- http://mail.python.org/mailman/listinfo/python-list
Re: textwidget.tag_bind("name", "", self.donothing) not working
No I haven't, but I will give it a try. Thanks for your reply! -- http://mail.python.org/mailman/listinfo/python-list
Re: textwidget.tag_bind("name", "", self.donothing) not working
I don't know if Tk supports this or not. I guess it just made since to me that it should. If you can bind events to a tag then why not a tag inside a text widget. The actual bind itself works. donothing() is called, the problem is that after donothing() is called and I return "break", Tk continues to insert the text entered. I am just try to lock down one particular part of a text line while leaving the rest of the line, which has a different tag, alone. -- http://mail.python.org/mailman/listinfo/python-list
Re: textwidget.tag_bind("name", "", self.donothing) not working
Thanks for your help and the link. From the link it sounds like no one is sure how this is supposed to act. I will dig around in the tcl forum and see what I can find. -- http://mail.python.org/mailman/listinfo/python-list
mod_python.dll not compatible with python23.dll
Title: mod_python.dll not compatible with python23.dll I just installed mod_python-3.1.3.win32-py2.3.exe which should set me up to use mod_python with python23 on apache2, windows xp. When I try the standard hello world test program, I get the _apache not found in the apache module. After searching on the web a bit, I discovered that the mod_python.dll needs to by copied into my python23/dll directory. I did this and I get an error telling me it can't locate ApacheCore.dll, so I add that...I then get cannot locate python20.dll. Why is it looking for 20? and why wouldn't the correct mod_python.dll be installed in the installation program mentioned above? More importantly, where can I get the proper mod_python.dll. If I am doing something wrong here could someone please help. I am guessing that I may not need the mod_python.dll file at all because the .so file is already in the apache modules directory...and that is supposed to be a dll. Also...(sorry for such a long note)...why do some web sites say that I should have LoadModule python_module modules/mod_python.dll in my apache config file? Apache always fails on start up when I have this. Thank you very much, Shannon -- http://mail.python.org/mailman/listinfo/python-list
mod_python.dll not compatible with python23.dll PART 2
Title: mod_python.dll not compatible with python23.dll PART 2 I have figured out what my problem was...and for all of you complete new people to python I will write what happened in case you come across the same problem. First and foremost. Make sure you can get "hello world" example to mod_python is working before you move on. I was using a copy and pasted web site for a newer one and had problems just jumping in and working. This is probably common knowledge, but put your mptest.py code in your apache folder. My biggest problem was that I was in a completely different folder trying to get this thing to work. Next thing, the mod_python-3.1.3.win32-py2.3.exe is perfectly fine, like most of the setups. If there is a problem, assume an experienced python programmer has already noticed it. Don't go out downloading other dlls or mod_python.so files and start copying them into strange places. Don't move any of the files except the mod_python.so file over to apache modules. If you are having a problem, its not because of something being in the wrong place, this was another stupid thing that i did that caused all sorts of problem. You WILL get _apache not found when trying to import mod_python from the command line. Its normal. Debug with tracebacks from the web...not something like Wing IDE. Maybe you can use it, but I don't know how. Sorry to all of you that read my first post. Newbie python guy over here. Thanks -- http://mail.python.org/mailman/listinfo/python-list
Hashlib py26
This feels a bit silly, but I am trying to encrypt some simple text with the new hashlib library and then decrypt it back into text. I can do this with M2Crypto RC4, but not the new hashlib. Could someone give me a quick example. Thank you. -- http://mail.python.org/mailman/listinfo/python-list