vote up 1 vote down
star

I like typing the first characters of a function name in XCode and pressing escape to get a list of functions w/ similar names. Sometimes I have functions that I don't want to appear in the list. How can I prevent certain functions, variables etc from appearing in the XCode auto-complete menu?

flag

3 Answers

vote up 2 vote down
check

Xcode learns its auto-completion list from the header files which are included.

If you don't want certain functions or methods to show up in the auto-completion list, you simply don't declare them in the header files.

This will of course lead to warnings when you invoke such a function or method. This can be circumvented (if invoked in the same file that its implemented) by implementing the function at the top of the file.

In case of objects, you can simply implement a method in the top of the class implementation (above the code where you invoke that method).

It basically hides the method, but you can still invoke it from anywhere. The warning you get when invoking it from outside of your implementation file won't stop it from working. Auto-complete won't show it though.

link|flag
vote up 2 vote down

Go to xCode menu.

Select Preferences.

Switch to code sense tab.

Remove check marks for

-> Show Arguments in pop up list. -> Insert argument placeholders for completion.

You will get what you want.

link|flag
vote up 2 vote down

This is a question better asked at StackOverflow.com, since it's not really a gaming question. The short answer is that you'd have to modify some templates that define the shortcuts...

link|flag

Your Answer

Get an OpenID
or

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