Skip to main content

Charcoal Editor 2 Documentation

Code Editor

The code editor (or code editor groups) is the area of Charcoal Editor 2 where scripts are created and executed. Multiple buffers can be open in a code editor group, each with its own tab in the tab bar. When a new buffer is created (File->New), or an existing file is opened (File->Open), a new tab is created and made active.

A script, or section of a script, can be executed directly from the editor. The following hotkeys can be used to execute code in the active buffer:

  • Ctrl+Enter - Execute selection (or execute all if nothing is selected)
  • Ctrl+Shift+Enter - Execute All
  • Ctrl+Alt+Enter - Execute Line

Tabs

Every buffer in a code editor group has a tab in its tab bar. Each tab has a name based on the file or interpreter type (temporary buffers). A tab name can be changed by selecting Rename... from the main menu (File->Rename...). Renaming a temporary buffer will only change the tab name. Renaming a file will change the name of the file on disk.

A tab can be reordered by dragging the tab left or right in the tab bar. Additionally, a tab can be moved to a different code view by dragging the tab into the other view.

The display and behavior of tabs in the the code editor can be modified in the Preferences dialog.