重置 Xcode 4 窗口位置
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/5297102/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Reset Xcode 4 window positions
提问by Enrico Detoma
I revive a previous question, but now for Xcode 4.
我恢复了以前的问题,但现在是 Xcode 4。
How can I reset window positions for a project in Xcode 4?
如何在 Xcode 4 中重置项目的窗口位置?
The old question was: Xcode window positions when switching from dual to single monitor
旧问题是: 从双显示器切换到单显示器时的 Xcode 窗口位置
I've tried to delete user data files as suggested in the other question, but it didn't reset the window positions.
我尝试按照另一个问题中的建议删除用户数据文件,但它没有重置窗口位置。
回答by Migrant Programmer
You need to delete the xcuserdata/username.xcuserdatad/UserInterfaceState.xcuserstatefile inside the workspace bundle. You can get to it via Finder "Show Package Contents" or via the Terminal.
您需要删除工作区包内的xcuserdata/ username.xcuserdatad/UserInterfaceState.xcuserstate文件。您可以通过 Finder“显示包裹内容”或通过终端访问它。
If you're not using a workspace, your xcodeproj will have a workspace file inside it that you can open up.
如果您不使用工作区,则您的 xcodeproj 将在其中包含一个您可以打开的工作区文件。
Delete the file and re-open the workspace and your window settings will be back to default.
删除文件并重新打开工作区,您的窗口设置将恢复为默认值。
BTW, this happens to me all the time when I accidentally leave a double-clicked file open and then close the main window.. it always comes back helpfully showing the single file with nothing else.
顺便说一句,当我不小心打开双击的文件然后关闭主窗口时,这种情况一直发生在我身上。
回答by Gary C
I assume you're referring to the user data files in the project package contents? You can try deleting User -> Library -> Preferences -> com.apple.dt.Xcode.plist. That should reset everything.
我假设您指的是项目包内容中的用户数据文件?您可以尝试删除 User -> Library -> Preferences -> com.apple.dt.Xcode.plist。那应该重置一切。