Quantcast
Channel: Active questions tagged visual-studio-code - Stack Overflow
Viewing all articles
Browse latest Browse all 98772

How do I look up the current context in VSCode?

$
0
0

Let's say I'm in VSCode (e.g. in the screenshot below in a Python interactive window), I'd like to define keybindings that only apply to a specific window type (e.g. Window 1, 2 or 3 in the screenshot below, which are window types for Python interactive development)

How can I look up the current context when the cursor is focused on any of them, so that I can use that in a when clause in my keybindings.json?

enter image description here

Note that in the example above, these are Python-extension-specific window types, namely:

  • Python interactive window
  • Plot Viewer
  • Variable explorer and data viewer
  • etc

Viewing all articles
Browse latest Browse all 98772

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>