Terry J. Reedy <tjre...@udel.edu> added the comment:

My first though was that the 'guy' had executed 'import math' and you had not.  
(See the IDLE doc at https://docs.python.org/3/library/idle.html or, within 
IDLE, Help => IDLE Help, "Editing and navigations" section, "completions' 
subsection, 2nd to last paragraph.)  Or maybe this was another 'Catalina' issue.

But I tried completion on my MacbookAir with Mohave 10.14.6? and 3.8.2 and 
3.7.5, in Shell at >>>, that don't need imports. 'i'<tab> should bring up a box 
with 'id' at the top.  'int.' should bring up a box with 'as_integer_ratio' at 
the top.  This works for me on Windows but not on the Mac.

For shortcuts, IDLE Preferences, Keys tab, has "force_open_completions    
<control-key-space>".  But the edit menu has "Show completions     ^S". 
Control-S is not Control-space.  Bug 1. In either case, neither work.  Nor does 
clicking the menu entry.  Bug 2.  Hitting ^S causes "Edit" on the main menu to 
flash blue (Mac only); ^space.  I believe this means that ^S invoked an item on 
the menu.  I repeated the above with IDLE started in Terminal ('python3 -m 
idlelib').  No errors messages appeared.

There are issues where shortcuts don't work, because they duplicate system 
binding, but menu items do.  This is different.

Is this a tkinter widget problem?  Similar Toplevel popups (calltips, squeezer 
tooltips) work.  Listbox is also used in config, config-key, and debugger 
dialogs, all of which at least appear.  

A debug print is autocomplete_w.py show_window reveals that it is called when 
it should be, including after both ^space and ^S, with what I believe are 
appropriate arguments.  Another print in winconfig_event, just before the 
geometry call to move the window into view, shows that x,y position looks good. 
 But two oddities: winconfig_event is called twice instead of once, and with 
^space and not ^S.  I have no idea how this could be.  Adding update() just 
before update_idletasks() prevents the 2nd winconfig_event call but does not 
make the popup appear.

I am out of ideas at the moment, except for this.  Other popups are withdrawn 
while created and filled in, and then deiconified, while this one is moved off 
screen to 10000,10000 and moved back. Wondering whether tk 8.6 does not like 
this movement, I disabled it.  The widget should then appear, but does not.

----------
components: +macOS
nosy: +ned.deily, ronaldoussoren, taleinat
title: IDLE Show completions/ autocomplete pop-up not working -> IDLE Show 
completions pop-up not working on macOS
versions: +Python 3.7, Python 3.9

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

Reply via email to