How to reset Xcode 4 shortcut keys - xcode4

How do I reset Xcode 4 shortcuts keys as default?
Xcode -> Performance -> Key binding
I found I set something wrong, but cannot find a way to reset as original.
How do I do? Reinstall Xcode 4?

Just click "+" to add a new Command Set and select Default (not Duplicate Default), then delete your old set.

Related

Any keyboard shortcut to display Xcode's "Show Find Options"?

Xcode offers several key codes to open the Find (CMD-F) or Find and Replace (CMD-OPT-F) editor toolbar, but how can I get the Find Options to show without having to move my mouse over the magnifying glass and clicking (which takes forever, I misclick, and then have to select the menu item - ugh)?
I have not found a single key to do this, but just discovered that after using
CMD-F
or
CMD-OPT-F
that the Find search field has focus, and by tapping the
down arrow key
twice followed by a
Return key, that it opened (do again to close)!
I added a key code sequence to Butler so I can use a single key to do this, so use your favorite Macro program to do likewise.
EDIT: Just discovered this still works in Xcode 7, you just need to do 2 down-arrows followed by a return.

Aptana go to last open editor command

I'm using Aptana Studio 3 and am looking for a command that will take me to the previous editor I was in (a la Netbeans ctrl-tab or Eclipse's ctrl-F6). I've tried several commands with promising sounding names but none of them seem to behave properly. Any thoughts?
Go to Windows->Preferences->General->Keys and have a look at the key binding you have set for the commands 'Next Editor' and 'Previous Editor'. Type those commands in the filter search box to save yourself having to scroll.
On Windows the shortcuts for next and previous editor are in fact Ctrl+F6 and Ctrl+Shift+F6 respectively, which also happen to be the defaults in Eclipse. So if your key bindings for those commands are not set then you can set them here.

Xcode4 target labelled as missing, but cannot delete it

I want to delete this red-marked target, but am unable to.
The "minus" button in the dialogue remains greyed-out, it doesn't respond to backspace or delete keys and right-clicking just brings up help options. I can drag the missing-red-marked target above or below the working black target, but it doesn't let me delete it.
This missing red target only seems to appear in this edit schemes dialogue.
In my main project/target window, I just have the one good target there.
Any ideas how to clean this up and delete this missing target?
What worked for me was to designate another executable (or none) in the existing scheme's various actions (run, test, etc.). It's the fact it's in use in the scheme's actions that prevents its deletion. I discovered this during my research for Mastering Xcode 4 (yes, shameless plug). :-)
Try creating a brand new scheme (via "New Scheme" or "Manage Schemes...") and start using that.
Once your new scheme is building properly and is set as a default, you should be able to delete the old scheme with the bogus "missing" target.
The real issue here is explained by Joar Wingfors in the Xcode-users mailing list (emphasis mine):
In the scheme sheet you cannot delete things from one tab that some
other tab depend on. In this case you probably have to delete the
target from the test tab before you can delete it from the build tab.
Or something along those lines.
I had the exact same problem. Solved by closing the xCode and externally editing the schema file to delete the bundlableResource section for the missing library. Not the safest of all methods but it works.
First delete all schemes and then generate the schemes again. Work for me .
What Joshua said, a bit tailored. Go through all various actions and change the missing executable to an existing one.
In your case, go to 'Profile' and switch to the new app. Same if you encounter this in 'Test' tab.

How to get Xcode 4's Documentation window to render based on an external stylesheet?

I used to be able to get Xcode 3's Documentation/Help window to render based on an external stylesheet by setting these:
defaults write com.apple.Xcode DVDocView.WebKitUserStyleSheetLocationPreferenceKey
"~/Library/Application Support/Firefox/Profiles/xxxxxxxx.default/chrome/userContent.css"
defaults write com.apple.Xcode DVDocView.WebKitUserStyleSheetEnabledPreferenceKey 1
The above doesn't work with Xcode 4 anymore? Any ideas?
The name of the plist file and the keys to use have changed. You should now use:
defaults write com.apple.dt.Xcode WebKitUserStyleSheetLocationPreferenceKey "/path/to/css"
defaults write com.apple.dt.Xcode WebKitUserStyleSheetEnabledPreferenceKey 1

Xcode 4 disable "fix-it" popup

I'm fine with Xcode 4 telling me that I have an error. But that pop-up pretty much always has the wrong solution. Is there any way I can get rid of it permanently?
From what I've seen, it looks like you may need to disable the various types of warnings one by one. A list is found here:
http://developer.apple.com/library/mac/#documentation/DeveloperTools/gcc-4.0.1/gcc/Warning-Options.html#Warning-Options
To change them:
Bring up the project navigator and choose your project. In the main window that appears, choose "All". Under the section "LLVM compiler 2.0 - Warnings", choose "Other Warning Flags". Add the flag "Wno-idiomatic-parentheses" for both "Debug" and "Release." Now clean and recompile ( from if(self = [super init]) - LLVM warning! How are you dealing with it?)
I noted in the apple dev link that the following option should inhibit all warnings:
-w Inhibit all warning messages.

Resources