问题
I have a file foo.plist
inside of an Xcode project. The plist is long. I hit command-F and enter "bar" into the search box. Xcode duly finds the text "bar" for me. I need to change it to "fubar". But no matter what I do next, I can't start typing into that field. If I click on my search result, Xcode scrolls to the top. If I delete the search text, Xcode also jumps to the top.
Is there any way to tell it to keep the focus at the search result and let me do something with it?
The only thing I'm aware of is to edit the plist as source code. That does work, but it's clunky. I'd much rather edit it as a plist.
回答1:
I've also seen this behavior, and I don't think Apple intends for Xcode to do this. Here's the workaround I do:
- Press ⌘F to begin a new search, then type your query in the search field.
- Click anywhere in the body of the .plist file. Ignore the fact that Xcode will not select what you clicked, but will instead select the first row (the
Root
dictionary) and scroll to it. - Press ⌘G to quickly return to the first instance of the search text. Xcode will behave normally until you perform a new search.
来源:https://stackoverflow.com/questions/14690497/xcode-plist-automatically-jumps-to-the-top-after-a-search