Docs Developer

VSCodeTools

VS Code integration: open externalized scripts, sync files and generate TouchDesigner type stubs.

⌨ Developer Toolbar button

Where it appears

Read off the registry hosts in the component, so this is where the tool puts itself in a default install; every one of these can be reordered or hidden from Hub.

Shortcuts

Global: they fire anywhere in TouchDesigner. Shortcuts scoped to a single panel are a local control scheme and stay off this list.

  • Ctrl+Shift+E / Ctrl+Shift+Alt+E

VSCode Tools

Youtube Breakdown

VSCodeTools helps creating/opening/managing VSCode workspaces and synced (externalized) scripts or tables. The file extension is detected from the DAT's declared language or content (.py, .vert, .frag, .tsv, plus .json, .yaml, .xml, .html and others). The only requirement is code.exe set up as the default text editor in TD Preferences.

The component is a button with the following interactions (and more, check the parameters below to get a full picture of what it does!!!)

  • LeftClick: Open VSCode workspace (if set up, see below)
  • RightClick: Set up VSCode workspace
  • Shift+LeftClick: Sync to file selected script
  • Alt+LeftClick: Clear Sync of selected
  • Ctrl+Shift+Alt+LeftClick: Force sync to file dialog

The component's own controls are listed under Parameters below, straight from the tool itself. What follows is the reasoning the parameter tooltips do not have room for.

Sync settings

If a to-be-synced script is an Extension script the default folder will include a subfolder with the parent's name (the extension belongs to)

You can also use Ctrl+Shift+Alt+E to force the rename dialog and save to another path or under another name.

Clearing a sync before you ship

If you ship your project file with synced files in your project, but without supplying the files, you will have a bad time.

The Clear page is how you avoid that: it drops the sync and this tool's tags so the content lives in the .toe again, at whatever scope you pick.

Stubs

This is an integration of AlphaMoonbaseBerlin's Stubser and typings <3

Python typing stubs can be deployed for selected DATs and COMPs containing extensions as well as built-in TD python typings.

The Stubs page deploys them: for your own extensions, and for TouchDesigner's own built-in typings.

Parameters

Its Registry page comes from FNS_ConfigRegistry and FNS_ToolbarRegistry.

Custom

ControlType / defaultWhat it does
Code.exeCodeexe file pathempty Path to your editor's executable (code.exe, or Cursor). Auto-detect fills it from TouchDesigner's Preferences text-editor setting, so you usually never touch it.
WorkspaceWorkspace file pathempty Path to the .code-workspace file this project opens. Auto-detect names it after the project file.
Auto-detectAutodetect on / offoff Fill Code.exe and Workspace automatically: the editor from TouchDesigner's Preferences, the workspace from the project's name. On by default; turn it off to pin either by hand.
Auto-openStartup on / offoff Open the workspace in your editor as soon as the project starts.
OpenOpen button Open the workspace now. If none exists yet, one is created in the project root and opened.
Sync settings
Script Sync Base FolderFolder folder pathempty Where synced scripts are written, relative to the project root. An extension script also gets a subfolder named after the COMP it belongs to.
Use Ctrl+Shift+E ShortcutShortcutactive on / offoff Enable the sync shortcut: it externalizes the selected DAT into the folder above, named after the operator. Add Alt to force the dialog and choose another name or path.
Sync File SelectedExternalizeselected button Sync the selected DAT to a file now, the same action as the shortcut.

Clear

ControlType / defaultWhat it does
TagsTagsread-only textempty Read-only. The tags this tool puts on every DAT it syncs, and looks for when clearing: an operator must carry all of them to count as synced.
Clear Synced Scripts... (undoable)
selected DATsClearselected button Drop the sync and this tool's tags from the selected DATs, so their content lives in the project file again.
in current paneClearcomp button Drop the sync and tags from every DAT in the current pane, not descending into children.
in current pane and all childrenClearcompchildren button Drop the sync and tags from every DAT in the current pane and all of its children.
all in projectClearall button Drop the sync and tags from every synced DAT in the project. Do this before shipping a .toe without its script files. Otherwise it opens looking for files that are not there.

Stubs

ControlType / defaultWhat it does
Stubs TagsTags2read-only textTDExtension FNS_externalized Read-only. The tags that mark an operator as stub-bearing, the same way the Clear tab's tags mark a synced DAT.
PrivatePrivate on / offoff Include methods and attributes whose names start with '_' in the generated stubs.
UnpromotedUnpromoted on / offon Include unpromoted members, the lowercase ones that are not reachable straight off the COMP, in the generated stubs.
Deploy StubsDeploystubs button Generate Python typing stubs for the selected DATs, or for the selected COMPs' extensions, so your editor can autocomplete them.
TD Typings
InstallInstall button Install TouchDesigner's own built-in Python typings, so td module members autocomplete in your editor.
ForceForce button Install the built-in typings even when they are already there, overwriting them. Use it after a TouchDesigner upgrade.

About

ControlType / defaultWhat it does
READMEOpen2 button Open this tool's README.

Edit this page on GitHub →