10 sec poll - please reply!
Michael Herrmann
michael.herrmann at getautoma.com
Sun Nov 25 08:41:56 EST 2012
On Sunday, November 25, 2012 12:23:13 AM UTC+1, Dennis Lee Bieber wrote:
> ...
> Pardon? In ASCII (and encodings that share the first 128 positions),
>
> a TAB is x09.
>
>
>
> >>> def show(c):
>
> ... print "%r is 0x%2.2X" % (c, ord(c))
>
> ...
>
> >>> show(raw_input()[0])
>
> i
>
> 'i' is 0x69
>
> >>> show(raw_input()[0])
>
>
>
> '\t' is 0x09
>
> >>>
>
>
>
> My "input" for the second was <ctrl-i>
>
>
>
> Typically, keyboard/console interfaces generate
>
> <ord-lowercase-letter> - 0x60 when the control key is held down.
>
> Lowercase "i" is 0x69; minuse 0x60 give 0x09, which is the TAB
>
> character.
>
>
>
> A GUI interface, however, may capture the combination for some other
>
> usage.
Thanks! I did not know that.
Michael
More information about the Python-list
mailing list