[PyKDE] Trivial improvement in the autocompletion of Eric3

Phil Thompson phil at riverbankcomputing.co.uk
Sat Jun 26 16:04:01 BST 2004

On Saturday 26 June 2004 10:41 pm, Maurizio Colucci wrote:
> On Saturday 26 June 2004 04:41, Phil Thompson wrote:

> > In one situation...
> >
> > I need to type 4 characters of an 8 letter word in order to make that
> > word current in the list.
> >
> > ...or in another...
> >
> > I can type 1 character, look at the list (the order of which may be
> > different each time it is displayed depending on where I am in the file)
> > and see that I only need to hit a cursor key twice to make the word
> > current.
> >
> > Personally I'm always going to do the first.
> You mean, you prefer typing 4 characters than typing one and scanning the
> list? Yes, of course: you developed this habit because, if you typed only
> one character, you would have to scan a list that is too long. But IF the
> list was sorted by distance, I bet you would have developed the opposite
> habit: type one character and scan the list. Because the scan would NOT be
> long in that case.

No I wouldn't. For me, scanning the list is relatively time consuming. When 
I'm typing I'm thinking about what I want to type next, not about what I'm 
currently typing. To scan the list means that I have to stop thinking about 
that, start thinking about what I'm currently typing, read and navigate the 
list, then switch back to what I was originally thinking about. At my age 
these are non-trivial operations.

If the contents of the list are predictable I can start taking it for granted 
by using without having to think about it too much - ie. without those 
expensive context switches.

> > It's one extra keystroke, but
> > it is relatively predictable. If I'm typing the same word many times I
> > will quickly get into the habit of typing the 4 characters and selecting
> > the current item without even bothering to look at the list.
> I believe typing one character is much more costly than pressing the down
> arrow to search in the completion list. So I don't agree that you should
> judge based on the number of keystrokes required.

I'm saying that the point is to save time.

> > Even though the second situation is one less keystroke (but maybe more
> > depending on the context) it will be much slower because I have to read
> > through the list - particulary if the list might need to be scrolled up
> > or down to find what I'm looking for.
> The point is: you are not using the list in order to save typing letters.
> You don't mind typing very much.
> My way of thinking, instead, is this: if I know I have typed a word very
> recently, I type only the first two letters, then I scan the list until I
> find it.

Like I said, I'm too busy thinking about the next sentence.

Obviously it's a very personal issue. If people generally think it's a good 
idea then I can add it. (It's a QScintilla thing, rather than an eric thing.)


More information about the PyQt mailing list