Skip to content
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added images/user-interface-for-rstudio-migration.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed images/user-interface.png
Binary file not shown.
106 changes: 52 additions & 54 deletions user-interface.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,79 +2,77 @@
title: "User Interface"
---

## User interface

Positron's interface is designed to provide a flexible and efficient environment for data science. By organizing various tools and outputs into distinct, customizable panes, you can tailor your development environment to suit your workflows in Python, R, and more.
The Positron interface provides a flexible environment for data science that can be tailored to your needs. You can organize tools and outputs into distinct, customizable panes. This lets you tailor your workspace to your workflows in Python, R, and other languages.

## Basic overview

> This section outlines the core layout elements of Positron’s interface. Each pane plays a distinct role in supporting coding, data exploration, and model development, giving you full control over your data science environment.
This section outlines the core layout elements of Positron’s interface. Each section plays a distinct role in writing code, running code, and understanding your results, giving you full control over your data science environment.

+ ![Interface of the Positron development environment showing Title Bar, Top Bar, Activity Bar, Primary Sidebar, Workspace, Secondary Sidebar, and Status Bar.](images/user-interface.png)
+ ![Interface of the Positron IDE showing Activity Bar, Primary Side Bar, Editor, Panel, and Secondary Side Bar.](images/user-interface-for-rstudio-migration.jpeg)

- **Title bar**: Located at the top, it shows the active file (_e.g.,_ `ui.rs`) and project (_e.g.,_ `ark`) along with window controls.
- **Top bar**: Provides global project tools such as file search, and lets you change interpreter versions (e.g., `Python`, `R`).
- **Activity bar**: Provides quick access to core views such as Explorer, Search, Source Control, and Extensions.
- **Primary sidebar**: Found on the left by default, this pane contains the File Explorer to navigate the project directory.
- **Workspace**: The main region for editing files. Supports syntax highlighting, inline diagnostics, code folding, and navigation tools.
- **Secondary sidebar**: The right panel, useful for interacting with runtimes. Contains tabs like `SESSION`, `CONNECTIONS`, `HELP`, `VIEWER`, `VARIABLES`, and `PLOTS`.
- **Status bar**: Displays project details like Git branch, language mode, and cursor position.
- The **Activity Bar** provides quick access to switch between core views such as Explorer, Search, [Source Control](git.qmd), and [Extensions](extensions.qmd).
- The **Primary Side Bar** is on the left by default and shows you different views depending on what you have chosen in the Activity Bar. When you choose the Explorer icon, this pane provides the file explorer to navigate your project directory and the outline. When you choose the Assistant icon, this pane provides access to [Positron Assistant](assistant.qmd)
- The **Editor** is in the upper central area by default, and is where you write your code. For editor controls, refer to [VS Code Editor Basics](https://code.visualstudio.com/docs/editing/codebasics).
- The **Panel** is below the editor by default and contains the [Console](#console) and the [Terminal](https://code.visualstudio.com/docs/terminal/basics). You can also access logs from [Output](troubleshooting.qmd#output-panel) channels in the Panel.
- The **Secondary Side Bar** is on the right by default. You can switch between the Session pane (where you can explore the variables you have defined and the plots you have created), the [Connections](connections-pane.qmd) pane, the [Help](help-pane.qmd) pane, and the Viewer pane.

Components mentioned above can be toggled in and out of view using commands such as **"View: Toggle Primary Side Bar Visibility"**, **"View: Toggle Status Bar Visibility"**, and others.
The **Title Bar** at the very top of the window shows the active file and project, along with window controls. Below it, the **Top Bar** provides global project tools such as file search, the project switcher, and the interpreter selector with the ability to start, stop, and switch interpreters. The **Status Bar** at the botton of the window displays details such as your git branch, language mode, and cursor position.

## Editor pane
You can toggle most of these components in and out of view using commands such as _View: Toggle Primary Side Bar Visibility_, _View: Toggle Status Bar Visibility_, and others.

In the upper central area by default, the editor is where you write, debug, and refine your code. Whether in Python or R, the editor delivers a full-featured IDE experience tailored to data science workflows.
## Console

- Write and edit scripts, notebooks, and apps with responsive syntax-aware features.
- Built on Code OSS, the same foundation as VS Code, for a familiar and extensible experience.
- For layout controls, refer to [VS Code Editor Basics](https://code.visualstudio.com/docs/editing/codebasics).
You can run your Python or R code in the fully interative, integrated Console. The Console supports running [multiple Python and/or R sessions](managing-interpreters.qmd) at one time.

### Key features
- **Syntax Highlighting**
Intelligent color schemes for quick visual parsing of R, Python, SQL, YAML, and more.
- **Auto completion & Intellisense**
Language server support for live suggestions, signature help, and hover tooltips.
- **Inline Diagnostics**
Errors, warnings, and linter messages appear in context as you type.
- **Multi-language and Multi-format Support**
Work seamlessly across Python or R in source files, Quarto documents or Jupyter notebooks, and markdown files. No additional configuration needed.
- **Live Document Preview**
Render Jupyter notebooks, Quarto documents, Shiny apps, and more next to your code for immediate feedback.
- **Tabs and Split View**
Organize workspaces with multiple tabs or horizontal/vertical splits to suit your workflow.
- **Version Control Integration**
View diffs, stage changes, and commit directly within the editor.
## Layout customization

## Panel pane
Positron offers flexible layout options to suit a variety of development workflows. Almost every component can be rearranged by dragging; for example, try moving the Help pane into the Session pane.

The panel below the editor offers contextual tools essential for development and debugging.
### Layout presets

### Terminal
Positron provides layout presets specifically designed for data science work:

- Fully integrated shell for script execution, CLI tools, and environment management.
- Multiple terminals supported and session-specific tabs available.
- **Stacked** (default): Editor above with Console and Terminal below, and the Variables and Plots panes to the right. Designed for interactive workflows with regular scripts or literate programming documents such as Quarto.
- **Side-by-side**: Useful for wide-screen users or those who prefer their editor and console next to each other.
- **Notebook**: Emphasizes the editor workspace for full focus on a Jupyter Notebook or source file, minimizing other panes.

### Console
- Native console displays Python/R runtime input and output along with the current working directory.
- Multiple Python or R console sessions are supported.
- UI elements support starting a new console, renaming, restarting, or closing an existing console, and opening detailed console information.
Use the command _Customize Layout..._ for more specific layout choices. You can also reset the whole UI back to defaults by clicking on the {{<fa rotate-left >}} icon at the top right of the layout quickpick.

### Other panel tabs
## Command palette

- **Output**: Logs from builds, publishing, or package management.
- **Problems**: Lists code issues with quick navigation.
- **Ports**: Manage forwarded ports for interactive apps like Shiny or Flask.
- **Debug console**: Evaluate expressions and view debugging info in real time.
Positron inherits the Command Palette from VS Code. The Command Palette is a fast and powerful way to interact with Positron without taking your hands off the keyboard. Think of it as a search bar for functionality. Rather than navigating menus, you can quickly find and run commands from a single interface.

## Layout customization
For additional documentation on the Command Palette, see the [VS Code Command Palette documentation](https://code.visualstudio.com/docs/getstarted/userinterface#_command-palette).

Positron offers flexible layout options to suit a variety of development workflows. Almost every component can be rearranged by simply dragging any pane (for example, move `Help` into the `Session` pane) to build your ideal workspace!
### Command access and execution

### Layout presets
The Command Palette provides access to all Positron commands. You can execute any command without using menus or remembering keyboard shortcuts.

To open the Command Palette, press {{< kbd mac=Command-Shift-P win=Ctrl-Shift-P linux=Ctrl-Shift-P >}}. Start typing a keyword or the name of a command. The Command Palette shows a list of matching actions. Use the arrow keys to select a command, then press {{< kbd Enter >}} to run it.

For example, you can:

- type "interpreter" to view interpreter session management commands.
- type "git" to view version control commands.

### File access and navigation

The Command Palette makes it easy to open files without using the file explorer. This is especially useful in large projects with many files.

Press {{< kbd mac=Command-P win=Ctrl-P linux=Ctrl-P >}} to open the file picker. Start typing part of a file name to see matching files. Use the arrow keys to select a file, then press {{< kbd Enter >}} to open the selected file.

You can also use:

| Key | Action |
| --- | ------ |
| {{< kbd \> >}} | Switch to command mode |
| {{< kbd @ >}} | Search for symbols in the current file |
| {{< kbd # >}} | Search for symbols across the workspace |
| {{< kbd : >}} followed by a line number | Jump to that line |

- **Stacked** (default): Editor above, with Console, Terminal, Output, Problems, Ports, and Debug Console below. Designed for traditional script-based workflows.
- **Side-by-side**: Useful for wide-screen users or those who prefer horizontal splitting.
- **Notebook style**: Emphasizes the editor workspace for full focus on a Jupyter Notebook or source file, minimizing other panes.
### Tips for effective use

To customize layout options, you may use the command **"Customize Layout..."**, which also enables you to reset back to default by clicking on the return button within the `Customize Layout...` command panel.
- **Use partial matches:** You do not need to type the full command or file name. The Command Palette uses fuzzy matching to find what you need.
- **Learn common prefixes:** Commands are grouped by category (for example, "View:" for layout commands, "Git:" for version control).
- **Browse available commands:** Open the Command Palette and scroll through the list to discover new functionality.
- **Use recent commands:** The Command Palette shows recently used commands first, making it faster to repeat common tasks.