Guilherme Polo <ggp...@gmail.com> added the comment:

> Weeble added the comment:
>
> I *think* the primary reason for overriding the home key behaviour was
> not for the interactive shell, but to make it easier to edit code. Most
> programmer's editors that do automatic indentation also let you use home
> to move to the beginning of the text on a line, rather than the absolute
> beginning of the line.
>

Yes, but IDLE goes beyond that and adds some weird behaviour.
Suppose you have this line in IDLE:

>>> xxxx

Why would you want to go at the absolute beginning there ? That is
what happens when you press home twice.
Then there is the other case, the reason for the current home code:

   y, ...

Pressing home twice while on the second line toggles between the
absolute start of that line and one position before y, this is the
behaviour that I haven't seen used anywhere else (but it is not like I
have used many GUI shells). If it is used everywhere else I haven't
looked at then this might be good because people are accustomed to,
otherwise it is just a feature that IDLE has for no reason.

> I've proposed some changes to the ctrl-left, ctrl-right behaviour on
> idle-dev that would also require custom handling of selection behaviour.

I'm subscribed to idle-dev but I assume I don't read it at all.

> If it were to be decided that reimplementing the selection-handling was
> worthwhile I would be willing to work on such a patch to redo the
> selection-handling using only supported Tk features, but I get the
> impression I'd need lots of help to get it tested with every possible
> version of Tcl/Tk.
>

Before start writing new code I suggest to check how many IDLE forks
exist, and check if any of them has this fixed. It would be good to
start writing tests for idlelib too.
Testing with every possible version of Tcl/Tk is not going to work,
the minimal possible is 8.2 as it is what _tkinter supports. But I
suspect most people are using tk 8.4 (and then there are a lot of
minor releases), some tk 8.5 and very few using other versions.
The externally maintained tk versions are 8.4.12, 8.4.16, 8.4.18.1 and
8.5.2.0 so we could target these versions.

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue4676>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to