Is it possible to set touch bar in F1-F12 mode for a specific app? I am happy with touch bar in general, but when I am working I want F1-F12 keys when editor is open. Is there a way to make touch bar go in function keys mode when editor becomes active?
Yes:

System Preferences -> Keyboard -> Shortcuts 

Select "Function Keys" and hit the plus sign.  

Select the app you want to have the function keys display for as default.