我在运行iOS 5的iPhone模拟器中保存了一些截图,但我找不到它们。

我以前遇到过这个问题,我花了很长时间才在文件系统中找到它们。这是如此简单,我只是一个傻瓜,还是没有人使用这个功能或什么?

我知道我可以从我真正的手机上得到屏幕截图,但我不想要视网膜屏幕截图——我想要普通的屏幕截图。


当前回答

它看起来像最新的Xcode(我使用v4.2.1)有一个错误保存屏幕截图从iOS模拟器。即使按了文件>保存屏幕截图,我在桌面上也找不到任何图像文件。最近,我注意到一款很棒的iOS-Simulator Cropper软件。它允许您使用不同的设置从模拟器捕获图像。

其他回答

更换设备:硬件>设备>iPhone(Retina 4英寸)

按Command + S

屏幕截图会自动出现在你的桌面上

如果要更改存储模拟器屏幕截图的位置,可以使用以下命令。

defaults write com.apple.iphonesimulator "ScreenShotSaveLocation" -string "~/Pictures/Screenshots" 

其他相关命令可以在这里找到。

默认情况下,截图保存在桌面上。

对于那些没有保存到桌面的人来说,可以试试这个位置:

~ /图书馆/开发/ CoreSimulator /设备/

会有一个随机哈希列表,每一个都是一个模拟器。 按修改日期排序,然后输入最近的文件夹,然后转到:

数据/媒体/ DCIM / 100苹果

你的照片和截图应该在那里:)

我的例子:

If you create screenshots from within the simulator using File -> Save Screen Shot (Command-S), those files end up on the Desktop as something like: iOS Simulator Screen shot Apr 22, 2012.png. Under Xcode 6 & newer, device screenshots taken with the "Take Screenshot" button in the Xcode "Devices" menu will end up on the desktop. Look for a file named "Screen Shot 2014-MM-DD at HH.MM.SS.png" For Xcode 5 & older, if you create screenshots from within Xcode (Organizer), you'll find these in ~/Library/Application Support/Developer/Shared/Xcode/Screenshots. To take screenshots from the Xcode (Organizer) you need to have hardware device attached. The organizer does not appear to take screenshots from the simulator.

在Xcode之外:

If you create screenshots using the Finder (command-shift-3 or command-shift-4), these also end up on the Desktop as something like: "Screen Shot 2012-04-22 at _ AM.png" If you use the Grab application (found in /Application/Utilities), you can save those files anywhere you decide. :-) If you have saved a screenshot to the Photos library from within your app, for example with UIGetScreenImage and UIImageWriteToSavedPhotosAlbum, they end up at ~/Library/Application Support/iPhone Simulator/***version***/Media/DCIM/100APPLE