29

I have checked Preferences->Editor->Code completion. Basic code completion is turned on. Shortcut is ^Space. When I click [control]+[space], it is opening spotlight search instead of code completion. How to solve this problem?

6 Answers 6

32

You need to change the Mac OS X keyboard shortcuts (Preferences | Keyboard | Shortcuts | Spotlight) and either disable the "Show Spotlight search" shortcut or reassign it to a different key.

26

As an alternative to yole's answer: Since I did not want to modify my system's shortcuts to have them the same across my Macs, I just edited the shortcut in Android Studio (Android Studio -> Preferences -> Keymap and change Basic Completion).

I've used Option+Space which is not assigned to any global shortcut.

P.S.: This is indeed a nuisance coming from years of Windows usage.

1
  • 1
    After a year of using this, I can say I find it the same as using Ctrl+Space, and I've been using this on all of IntelliJ IDEs I use every day. I still suggest just editing the shortcut If you don't want to modify your default OSX shortcuts.
    – Lucas P.
    Jan 23, 2019 at 14:34
6

I'm running Android Studio on Windows 10. File -> Settings -> Editor -> General -> Code Completion

The default hotkeys for Auto-Complete are:

1) Control + Space + Spacebar

2) Control+ Spacebar

enter image description here

1

Click on Alt+Enter to make Auto Complete

0

The shortcut is different now but is still working, you just need to click

ctrl + space

. The ^ you see listed in your preferences is the symbol for ctrl on a mac.

0

On MacOS Ventura (13.0), Ctrl-Space is assigned to switching input sources.

This needs to be disabled or changed to some other keys in System Settings... Keyboard > Keyboard Shortcuts > Input Sources if you want to keep using the same short cut in Visual Studio.

Not the answer you're looking for? Browse other questions tagged or ask your own question.