[Tutor] gotoxy

Alan Gauld alan.gauld at btinternet.com
Thu Aug 2 21:04:35 CEST 2007


"Robert William Hanks" <astroultraman at gmail.com> wrote

> hi folks, is there in python a gotoxy like in pascal so i can print 
> stuff
> in other parts of the screen?

Yes there is a port of the Borland Pascal conio library module 
available on
the Vaults of Parnassus.

Dunno how up to date it is though - it claims to work with Python 
2.2...

http://newcenturycomputers.net/projects/wconio.html.

> what about some thing like it for the gui in windows?

In a GUI go to X,Y is usually done in the context of a graphics
widget like a canvas. Most GUI toolkits offer such a method.

But in a GUI its less like the Pascal example in that you
normally go to a widget that has been created at a location.
The location may be specified as an X,Y location or more
commonly in a relative location using a layout manager.

HTH,


-- 
Alan Gauld
Author of the Learn to Program web site
http://www.freenetpages.co.uk/hp/alan.gauld 




More information about the Tutor mailing list