[issue16198] IDLE - tabbing in a string always brings up file completion window

Roger Serwy report at bugs.python.org
Mon Oct 15 06:23:11 CEST 2012


Roger Serwy added the comment:

> I think that maybe tabs within strings should always do the same as within comments. Perhaps one way is enough. (I am guessing that other editors use <tab> for this, so I can see the desire to use it.) There needs to be a way to get tabbing within multiline strings. I did not see 'file completion' in Options/Configure/Keys. Is it there under a different name?
Tab completion for file names is a convenience feature in IDLE, since 
file I/O requires specifying file names in strings. The given patch 
restores tabbing within a multiline string.

There is no configuration option for file completion.

>
> I was puzzled by the example path d:/Biblioteca/Técnica/informática/Python from #14937 until I retried in 3.2.3. In 3.3.0, a / disables filename completion. I reopened this issue.
I can use either "/" or "\" for file completion under Windows 7 with 
3.3.0. Try "C:/" instead.
>
> If one types 'd:\' and there is no d:, <tab> inserts spaces and ^space is ignored. I do not like this kind of inconsistency (or magical behavior shift). If you ask for file names, better to bring up a blank box, or a one-line box [<no matches>].
I agree that it is inconsistent, but then again, file-completion in a 
string with Tab is a convenience feature. There is no good way to 
specify "ask for file names" unless you create a separate key binding 
just for that. Sometimes, a Tab is just a Tab.

The behavior introduced by the provided patch will only provide the file 
completion box (or automatic fill-in) if the given string already 
partially matches a file in the file system.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16198>
_______________________________________


More information about the Python-bugs-list mailing list