Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to hide iOS simulator Tool Bar?

Seems like the iOS simulator added a new ToolBar, which I am unable to hide.

enter image description here

Is there any shortcut to hide it?

like image 721
Sandesh B Suvarna Avatar asked Mar 27 '20 15:03

Sandesh B Suvarna


People also ask

How do you hide the keyboard on iPhone simulator?

Tap in a text field. Tap the "hide keyboard" button in bottom-right corner. Tap to another text field.

How do you show touches on iPhone simulator?

You can show touch indicators in the iOS simulator by opening Terminal and running defaults write com. apple. iphonesimulator ShowSingleTouches 1 . You can turn this setting off again by running defaults write com.

How do you tap in iOS simulator?

When in the simulator, hold the option key down and click - this will simulate a two-finger tap!


2 Answers

Assuming you want a nice screenshot with the device the following worked for me, from Swany's answer on this Apple forum thread :

In a terminal, disable shadows on Screenshots with the following command:

defaults write com.apple.screencapture disable-shadow -bool TRUE; killall SystemUIServer 

Take a screenshot with Screencapture, either by selecting a region without the Toolbar, or of the whole Simulator window and crop the Toolbar.

You can still add shadow on the image wherever you use it.

The following command reverses the change to the screencapture app :

defaults write com.apple.screencapture disable-shadow -bool FALSE; killall SystemUIServer 
like image 131
user2870968 Avatar answered Sep 27 '22 18:09

user2870968


While you won't be able to hide the toolbar, I discovered a solution that worked very well for me and doesn't involve changing user defaults (which didn't work for me).

With the Simulator window open, open up the Screenshot application. On the floating utility bar, there will be an option for "Capture Selected Window".

Click on this, and it will turn your mouse cursor into a camera. Hover over the widow you want to take a screenshot of (Simulator in this case) and alt + click.

This will save a screenshot with no drop shadow, which you can easily crop in Preview or any other imaging editing software in order to remove the bar at the top.

It will have a transparent background so it will be very easy to work with.

like image 44
Michael M. Avatar answered Sep 27 '22 17:09

Michael M.