Re: python coding contest

2005-12-27 Thread py pan
When you guys say 127~150 characters, did you guys mean usinging test_vectors.py in some way? Or there's no import at all?
-- 
http://mail.python.org/mailman/listinfo/python-list

Re: python coding contest

2005-12-27 Thread py pan
On 12/27/05, Christian Tismer <[EMAIL PROTECTED]> wrote:
And we are of course implementing algorithms with a twisted goal-setin mind: How to express this the shortest way, not elegantly,just how to shave off one or even two bytes, re-iterating thepossible algorithms again and again, just to find a version that is
lexically shorter? To what a silly, autistic crowd of insane peopledo I belong? But it caught me, again!I personally think that it's a good practice. The experiences gatheredmight be useful in other applications in the future. That's where the
excitement of learning new things is about. Actually, I don't see so much applications
for the given problem, Something like this:http://j.domaindlx.com/elements28/wxpython/LEDCtrl.htmlconvinced me that there are application of this problem. 

-- 
http://mail.python.org/mailman/listinfo/python-list

Re: Display of JPEG images from Python

2006-01-08 Thread py pan
I remember seeing somewhere saying that the "wx.StaticBitmap" is only for small image (64x64?), is that true?On 6 Jan 2006 07:01:24 -0800, 
[EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
You can f.i. use wxPython (www.wxPython.org). Here is a compact andugly, but (almost) minimal, example of a python script that shows animage file:import wxa = wx.PySimpleApp
()wximg = wx.Image('img.jpg',wx.BITMAP_TYPE_JPEG)wxbmp=wximg.ConvertToBitmap()f = wx.Frame(None, -1, "Show JPEG demo")f.SetSize( wxbmp.GetSize() )wx.StaticBitmap(f,-1,wxbmp,(0,0))f.Show(True)
def callback(evt,a=a,f=f):# Closes the window upon any keypressf.Close()a.ExitMainLoop()wx.EVT_CHAR(f,callback)a.MainLoop()-svein--
http://mail.python.org/mailman/listinfo/python-list
-- 
http://mail.python.org/mailman/listinfo/python-list