[Tutor] Motion
Adam Vardy
Adam Vardy <anvardy@roadrunner.nf.net>
Fri Dec 20 16:00:42 2002
Thursday, December 19, 2002, 7:45:21 PM, you wrote:
>> At 17:40 2002-12-19 -03-30, Adam Vardy wrote:
>>Suppose I'd like to start off with something simple like moving a
>>letter around the screen, pretend he's your man, and you move him
>>around by some control, mouse or something. How do you start with
>>that? How do you place the letter anywhere on screen?
>> What makes you think this is simple? :)
>> Let's just say it varies...
>> Performing calculations and logical tricks is one thing, but when
>> we move objects on the screen, everything depends on how the
>> operating system interfaces with the screen. There is unfortunately
>> no standard for that. (If there ever could be--user interfaces can
>> be very different.)
Well, ah...
this is what you'd do on a 1984 C64.
POKE 1024+Y*40+X,MAN
OR call the kernal plot routine
SYS Plot, y,x,0: PRINT MAN;
[Man = some Letter of interest]
>> This means that you must decide what kind of environment you use.
>> The first thing to consider is probably whether you want a graphical
>> user interface of a text based user interface.
>> Surprisingly, the task you mention might be easier to do with a
>> complex graphical user interface, than with a plain simple text
>> based interface. At least in Windows, and certainly if you want it
>> to be cross platform.
>> The most common Python GUI toolkits, such as Tkinter and wxPython
>> works the same (well, close at least) in Windows, Linux and some
>> more operating systems.
Only thing is, here we go with novelletes that read to me like..."
Isn't there a serious problem hidden in here: what happens when the __init__ function returns and the frame variable goes out of scope?
Just relax; there's actually no need to keep a reference to the widget instance.
"
This must be some Martian trying to chat me up from a Fredrick Pohl
novel.
Then there's the link at...
"example is adapted from the "hello world" program in Matt Conway's A
Tkinter Life Preserver ."
Apparently the Life Preserver is Error 404: File Not Found
Tossed out in a cold Martian sea, glug glug...
Relaxing, as your muscle fibres decompose.
--
Adam Vardy