Xcode, like many IDEs, gets autocomplete wrong. Compared to Visual Studio 2010, for example, autocomplete in Xcode is a frustrating experience. Here are some of the ways it is inadequate:
- It commits the cardinal sin of autocompletion by requiring that you press enter or tab to accept an autocompletion. It should accept the current selection with any key press that makes contextual sense – such as ], ;, =, or (, instead of only accepting the current selection when you press enter or tab.
This is a pretty subtle point, but it makes a world of difference in terms of usability. Here’s an example. Suppose you want to type
self.foo = bar;
In Xcode, i have to do the following:
for a total of 11 keypresses.
To get the same thing in VS 2010, using C#, you have to type the following
.. for a total of 6 keypresses – almost half as many as the Xcode version. And it even automatically inserts spaces around the = sign.
- As previously discussed, it does a horrible job of offering context-sensitive help when for constants or enums, populating the list with everything in the current scope, regardless of how irrelevant it is or how many compile errors using it would cause.
- It does not display the autocomplete list automatically when you press period. Or, for that matter, when sending a message with [foo . You have to either start typing (which isn’t very useful if you don’t know what you are looking for), or press Esc (which is a pain).
- When you use autocomplete to insert a function call such as CGRectMake(,,,), Xcode inserts the last ), but there seems to be no way to have it automatically insert the ; or move the cursor outside of the ). This means that you have to take your hands off the keyboard and use the arrow keys to manually move the cursor over just so you can type a stupid semicolon.
- Pressing PageUp or PageDown doesn’t scroll the autocomplete list, it hides the autocomplete list and scrolls the file you are editing.
It’s death by 1000 paper cuts, and it makes iOS development far more painful than it needs to be.
Anybody have any autocomplete frustrations that I missed?