-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Keyboard shortcut for Find not working in Mac #15437
Comments
Hi @mpeters2, I was unable to reproduce your issue, are you using the shortcut once the find replace widget is opened? |
@ steff456 Yes, I'm using it once the widget is opened. After playing around with it some more, I can get it to work the first time I type something in the "find" box. Having said that, it: if there are three or more matches, pressing the short cut will highlight the second match, but will not highlight the next matches. After finding the first match, it simply doesn't seem to work any more (see screen shot below where it is stuck on the second match of "def"; the "search" menu is open to confirm that command-G has been mapped to "find next", but this result was produced by using the keyboard shortcut). On the other hand, the "find next" down-arrow in the find widget works just fine, as does "Find Next" in the pull-down menu, so it seems to be a mapping from the keyboard to the behavior that is wonky. |
I think this is caused because the focus changes from find/replace widget (where you introduce the text to search for) to the editor. Could you check that? |
if I click in the text editor, the word in the search box (e.g. "def") is highlighted in gray in the source code, but command-G doesn't do anything. If I click in the search box, then one of the search terms is highlighted in light blue and the rest in gray (as in the picture post above), but command-G still doesn't do anything. Clicking on the up and down arrow (find next and find previous) works just fine. I even tried command-G after click the arrows, and it still doesn't work. |
While I cannot reproduce the OP, I'm having an issue that may be related. |
I think
This is weird. |
Okay, that makes sense. |
Okay, looks like all is good. As @ccordoba12 mentioned, the "run cell" and "run cell and advance" actions are also global (they reside in the Run menu). When changing these shortcuts in Spyder preferences, it is insufficient to Apply the changes or exit the preference pane; Spyder must be restarted for the Run menu to update. I modified "run cell" so as not to conflict with the IPython Console newline behavior and after restart all shortcuts work as expected, including @mpeters2, after modifying the "Find next" shortcut, did you try restarting Spyder? It worked for me without restarting Spyder, but maybe that would fix it for you. |
Sorry for the 11-month reply, but I still have this issue on one of my computers: an Intel iMac running Spyder 5.3. My M1 MacBook running Spyder 5.15 does not have the keyboard mapping issue. |
update: Since it is the same machine, but different versions of Spyder, that was giving me grief, I had a hunch that it was a corrupted preferences that was affecting each version of Spyder. So I reset the keymappings to their default, and then redid the keymappings. Now everything seems to work. |
Great news @mpeters2! Closing this issue then. |
I take it back: that fix only worked for a short while. I came back to my computer the next morning and command-G no longer worked. I had to reset the keyboard mappings and remap command-G for Find Again. I've got a great idea: instead of using Windows bindings, why not use Mac-native bindings? You already use it for Find and Replace, you just need to hard-wire it for Find Again. |
Ok, that's a good idea. We'll take a look at it for our next release (5.3.2). |
@mrclary, could you take a look at this one? |
Issue Report Checklist
conda update spyder
(orpip
, if not using Anaconda)jupyter qtconsole
(if console-related)spyder --reset
Problem Description
Tried to change keyboard shortcut for "Find Next" from F3 to command-G. Preferences shows that the change has been made, but pressing command-G has no effect. I can't test to see if F3 works, as F3 is mapped to another function on my computer.
What steps reproduce the problem?
What is the expected output? What do you see instead?
I expect to see the next matching item highlighted in the text editor
Paste Traceback/Error Below (if applicable)
Versions
Dependencies
Mandatory:
applaunchservices >=0.1.7 : 0.2.1 (OK)
atomicwrites >=1.2.0 : 1.4.0 (OK)
chardet >=2.0.0 : 4.0.0 (OK)
cloudpickle >=0.5.0 : 1.6.0 (OK)
cookiecutter >=1.6.0 : 1.7.2 (OK)
diff_match_patch >=20181111 : 20200713 (OK)
intervaltree >=3.0.2 : 3.1.0 (OK)
IPython >=7.6.0 : 7.22.0 (OK)
jedi =0.17.2 : 0.17.2 (OK)
jsonschema >=3.2.0 : 3.2.0 (OK)
keyring >=17.0.0 : 22.3.0 (OK)
nbconvert >=4.0 : 6.0.7 (OK)
numpydoc >=0.6.0 : 1.1.0 (OK)
parso =0.7.0 : 0.7.0 (OK)
pexpect >=4.4.0 : 4.8.0 (OK)
pickleshare >=0.4 : 0.7.5 (OK)
psutil >=5.3 : 5.8.0 (OK)
pygments >=2.0 : 2.8.1 (OK)
pylint >=1.0 : 2.7.4 (OK)
pyls >=0.36.2;<1.0.0 : 0.36.2 (OK)
pyls_black >=0.4.6 : 0.4.6 (OK)
pyls_spyder >=0.3.2 : 0.3.2 (OK)
qdarkstyle =3.0.2 : 3.0.2 (OK)
qstylizer >=0.1.10 : 0.1.10 (OK)
qtawesome >=0.5.7 : 1.0.2 (OK)
qtconsole >=5.0.3 : 5.0.3 (OK)
qtpy >=1.5.0 : 1.9.0 (OK)
rtree >=0.8.3 : 0.9.7 (OK)
setuptools >=39.0.0 : 52.0.0.post20210125 (OK)
sphinx >=0.6.6 : 3.5.3 (OK)
spyder_kernels >=2.0.1;<2.1.0 : 2.0.1 (OK)
textdistance >=4.2.0 : 4.2.1 (OK)
three_merge >=0.1.1 : 0.1.1 (OK)
watchdog >=0.10.3;<2.0.0 : 1.0.2 (OK)
zmq >=17 : 20.0.0 (OK)
Optional:
cython >=0.21 : 0.29.23 (OK)
matplotlib >=2.0.0 : 3.3.4 (OK)
numpy >=1.7 : 1.18.1 (OK)
pandas >=1.1.1 : 1.2.4 (OK)
scipy >=0.17.0 : 1.6.2 (OK)
sympy >=0.7.3 : 1.8 (OK)
The text was updated successfully, but these errors were encountered: