Touch Bar Debug Preferences
The Touch Bar is an exciting addition to the new MacBook Pro lineup. Developers can add Touch Bar support to their apps using Xcode 8.1, which includes support for Touch Bar development and a Touch Bar simulator.
In the course of trying out the Touch Bar, I found a few debug preferences. Each of these can be activated using the defaults command in Terminal.
Show App Info
Adds a text overlay which tells you which application has control of each part of the Touch Bar.
defaults write com.apple.DFRAgent ShowAppInfo TRUE killall TouchBarAgent
Show App Frame
Adds a frame around each portion of the Touch Bar that is controlled by each application.
defaults write com.apple.DFRAgent ShowAppFrame TRUE killall TouchBarAgent
Show Touches
Causes touches to be shown on the screen when you click in the simulator. Useful for screen recordings. Note that this also demonstrates that the Touch Bar is not concerned with any vertical movement of your finger.
defaults write com.apple.DFRAgent ShowTouches TRUE killall TouchBarAgent
Reset Defaults
If you tried out any of the above preferences, you can run this to clear out the preferences.
defaults delete com.apple.DFRAgent killall TouchBarAgent