Skip to end of metadata
Go to start of metadata

What this tutorial is about

You have already noticed that the PyCharm's editor - the main development space - is tab-based. PyCharm's facilities to work with the tabs are numerous. In this tutorial we'll have a brief outlook of the features, related to the editor tabs.

Active tab

Every time we open a file for editing, it opens in its own tab. The tab that currently has the focus is called the active tab.

Editor tab actions

Find the list of action on the main menu (Window → Editor Tabs):

or on the context menu of a tab:

Closing editor tabs

There are several ways to close editor tabs, and this behavior depends on the settings.

  • First, the tabs close automatically, when a certain limiting number is exceeded. For example, the Tab limit setting defines the number of tabs to be displayed at once. When any new tab opens, one of the opened tabs closes, according to the tab closing policy.
  • Second, it is possible to click on a tab:

The presence of on a tab is also configurable (option Show "close" button on editor tabs should be selected).

  • Third, press Ctrl+F4 to close the active editor tab.
  • Finally, use commands of the main menu (Window → Editor Tabs), or of the context menu of a tab.

Navigating between editor tabs

Here again, PyCharm provides more than one way to jump between the editor tabs:

  • Just use your mouse pointer. As soon as you click an editor tab, it becomes active.
  • Press Alt+Right to jump to the tab located to the right from the active one; press Alt+Left to jump to the tab to the left.
  • Use navigation commands Select Next Tab/Select Previous Tab on the context menu of a tab, or on the Window → Editor Tabs menu.

Splitting and unsplitting editor tabs

Why do we need splitting? For example, when working with a lengthy file, we can show different portions of a file simultaneously, or show different files in the various parts of a window. Another use case is creating the so-called groupes of tabs.

The split commands are available from the context menu of a tab: right-click a tab, and explore its context menu:

Note that in certain keymaps (for example, in the default keymap for Windows), split actions do not have associated keyboard shortcuts. Create your own shortcuts for these actions, as described in the Configuring keyboard schemes tutorial or the Configuring keyboard shortcuts help section.

The splits of an editor tab share the same clipboard, so that copy and paste operations between the splits are possible. It is also possible to drag-and drop files from one group to another:

Navigation between editor tabs works within a split, but it is also possble to jump between various splits. To do that, choose Window → Editor Tabs → Goto Next Splitter/Goro Previous Splitter.

Note that in certain keymaps (for example, in the default keymap for Windows), these actions do not have associated keyboard shortcuts. Create your own shortcuts for these actions, as described in the Configuring keyboard schemes tutorial or the Configuring keyboard shortcuts help section.

PyCharm allows changing the splitter orientation: for example, you've created a vertical split, and now want to see same groups located horizontally. No problem at all - just choose Change Splitter Orientation on the context menu of a tab, or on the Window → Editor Tabs menu.

When fed up with splitting, you can always unsplit a tab using the command Unsplit on the tab's context menu. or on the Window → Editor Tabs menu. So doing, unsplit applies to the selected group of tabs only, leaving the others intact. If you want to remove all splits, choose the command Unsplit All.

Configuring tabs appearance and behavior

The PyCharm's Settings dialog makes it possible to change every aspect of the tabs' appearance and behavior. Open the Editor Tabs page (click on the main toolbar to open the Settings dialog, or choose File→Settings on the main menu; then expand Editor, and click Editor Tabs), and change editor tab settings to your taste:

Learn more

To learn more about the tabs, refer to the section Managing editor tabs

Other topics of this tutorial


Your Rating: Results: BrokenPartially brokenWorksStableNo problems at all 5 rates

Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.