[PyKDE] current file line

Paul Giannaros ceruleanblaze at gmail.com
Thu Feb 22 19:01:05 GMT 2007


On Thursday 22 February 2007 18:53, Juan Fernando Estrada wrote:
> hello
>
> how i can get current file line in the same form of __name__ ....
> __line__ ???
>

sys._getframe().f_lineno

The nice thing about getframe is that you can also peek further back and get 
more information about the point from which your function was called (locals 
that reside there, the name of the function, the line on which you were 
called).

>
> _______________________________________________
> PyKDE mailing list    PyKDE at mats.imk.fraunhofer.de
> http://mats.imk.fraunhofer.de/mailman/listinfo/pykde




More information about the PyQt mailing list