Skip to content
Open
Show file tree
Hide file tree
Changes from all 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 removed images/ui/tool_window/find.png
Binary file not shown.
Binary file removed images/ui/tool_window/git.png
Binary file not shown.
Binary file removed images/ui/tool_window/pull_requests.png
Binary file not shown.
Binary file removed images/ui/tool_window/tool_window_example.png
Binary file not shown.
Binary file removed images/ui/tool_window/tool_window_structure.png
Binary file not shown.
Binary file added images/ui/tool_window/toolwindow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_badge.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_badge_dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_horizontal.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_more_correct.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_name.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_name_dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_name_stripes.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_structure.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/ui/tool_window/toolwindow_tabs.png
Binary file added images/ui/tool_window/toolwindow_tabs_dark.png
Binary file added images/ui/tool_window/toolwindow_vertical.png
108 changes: 86 additions & 22 deletions topics/ui/components/tool_window.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,50 +6,114 @@

A tool window is a pane inside the main IDE window. For information about tool windows, see [IntelliJ IDEA Web Help](https://www.jetbrains.com/help/idea/tool-windows.html). For information about implementing tool windows, see [](tool_windows.md).

![](tool_window_example.png){width=960}
![](toolwindow.png){width=706}

## When to use

Use the tool window to show a large amount of information that the user needs while working side-by-side with the editor or other tool windows. For example, viewing the project structure, running and debugging an application, and viewing git log.
Tool windows provide access to information, tools, and services that support coding. They let users manage the project, run and debug applications, view git changes, and work with external systems — all without leaving the main workspace.

If the amount of information is small, show it in the editor, main toolbar, status bar or popup. For example, show version control changes on the editor gutter, breadcrumbs in the main toolbar, current branch and file details in the status bar, quick doc in a popup.
<!-- Use the tool window to show a large amount of information that the user needs while working side-by-side with the editor or other tool windows. For example, viewing the project structure, running and debugging an application, and viewing git log.
If the user does not need the information from the main window to complete an operation, show the content in the popup or dialog window. For example, Search Everywhere popup, Settings dialog.
## When not to use
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For me, it feels like the examples in this paragraph are too specific. I don’t think all these things are shown in the editor only because they contain a small amount of information. The same goes for Settings and SE. Maybe we could rephrase the “When to use” part and remove this section completely?
I tried to make an example:
Tool windows provide access to information, tools, and services that support coding. They let users manage the project, run and debug applications, track changes, and work with external systems — all without leaving the main workspace.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kinda agree with you. We also wanted to write an article about what kind of layout (tw, popup, or dialog) to use in which case, so we can add a link to it later here

## Tool window structure
### Small amount of information
![](tool_window_structure.png){width=483}
If the amount of information is small, show it in the editor, main toolbar, status bar, or popup. For example, show version control changes in the editor gutter, breadcrumbs in the main toolbar, current branch and file details in the status bar, quick doc in a popup.
## How to use
For more information about choosing the correct placement for content, read [UI guidelines on placing content](content_placement.md). //TODO: Write a guideline on placing content in IDE.
### Main window content is not needed
If the user does not need the information from the main window to complete an operation, show the content in the popup or dialog window. For example, the <control>Search Everywhere</control> popup, <control>Settings</control> dialog.
-->

## Tool window structure
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, maybe it makes sense to add information about speed search. How it works in the tool window, or, if we have a separate article, include a link to it. What do you think?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll see what I can do. The Search field guideline is also on me right now. When we publish it, I'll add a link somewhere here


![](toolwindow_structure.png){width=706}

Give the tool window a name:
### Tool window name

* The name should be [short and descriptive](writing_short.md), preferably not longer than two words.
* Use title-case capitalization.
* Provide an abbreviation if a common one exists when tool window names are shown in the stripes. For example, <code>Pull Requests</code> becomes <code>PR</code>.

<table border="false" style="none">
<tr>
<td width="378"><img src="toolwindow_name.png" alt=""/></td>
<td width="378"><img src="toolwindow_name_stripes.png" alt=""/></td>
</tr>
</table>

<!--Show the tool window name in the tool window button and header. If there are tabs in the tool window header, add a colon after the tool window name. Otherwise, do not add it.-->

### Icon

Add an icon for the tool window button. The icon should be created in two sizes: 20×20px and 16×16px, grey, and monochromatic. See how to create icons in the [icons guidelines](icons_style.md).

<!--### Icon
Follow [tool window icons guidelines](icons_style#NNN.md) to create correct icons for tool windows.
// TODO: publish this chapter when the guideline about icons is public too
-->

#### Icon badge for feedback

Show the tool window name in the tool window button and header. If there are tabs in the tool window header, add a colon after the tool window name. Otherwise, do not add it.
Show a colored badge above the icon if the tool window content changes and can contain different types of feedback, for example, new updates or errors.

![](pull_requests.png){width=308}
Do not change the icon for the tool window button when the content changes.

Add an icon for the tool window. The icon is 13px x 13px, grey and monochromatic. See how to create icons in the [icons guidelines](icons_style.md).
![](toolwindow_badge.png){width=706}

<!--**Exception:** <control>Problems</control> and <control>Event Log</control> icons change color and show the current status.-->

### Tabs
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it would be useful to add a link to the Tabs article (better check my new one) or the Group Controls article


Add [tabs](tabs.md) to group related content or create similar instances, like run sessions, history for files, find results. The tabs for similar entities should be closable.

![](toolwindow_tabs.png){width=706}

### Visibility
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest moving this section to How to use because it doesn't seem to be about structure


If a tool window has no content yet, show its button by default only if the window contains basic functionality that is likely to be used for all projects, for example, <control>Version Control</control> or <control>Problems</control>. Otherwise, hide the tool window button by default. Hidden tool windows are still available under <control>More tool windows</control> menu.

<table border="false" style="none">
<tr>
<td width="50%"><format color="Green" style="bold">Correct</format><img src="toolwindow_more_correct.png" alt=""/></td>
<td width="50%"><format color="red" style="bold">Incorrect</format><img src="toolwindow_more_incorrect.png" alt=""/></td>
</tr>
</table>

Don't show the tool window button if the tool window is not relevant to the current project configuration. For example, don't show the <control>Maven</control> tool window for a project without Maven configuration files.

### Toolbar

Add a toolbar for [frequently used actions and filters](toolbar.md#what-items-to-add-on-toolbar). For more details, see the [toolbar guidelines](toolbar.md).

<!--Put tool window viewing mode settings under the gear icon in the header. If there is no toolbar, put other options under the gear icon as well. For example, see the gear icon in the Project tool window.-->

## How to use

**Exception:** <control>Problems</control> and <control>Event Log</control> icons change color and show the current status.
### Orientation

Select the tool window orientation depending on the content. Vertical tool windows work better for trees, for example, Project, Structure, or Maven tool windows. Horizontal tool windows work better for tables, wide content or master-detail panels, for example, Git Log, Terminal, or Problems.
#### Vertical window

Do **not** show the tool window button if the tool window is not relevant to the current project configuration. For example, do not show the Maven tool window for a project without Maven configuration files.
Vertical tool windows work better for trees, for example, Project, Structure, or Maven tool windows.

If a tool window has no content yet, show its button by default only if the window contains basic functionality that is likely to be used for all projects, for example, Version Control or Problems. Otherwise, do not show the tool window button by default.
![](toolwindow_vertical.png){width=706}

Add a toolbar for [frequently used actions and filters](toolbar.md#what-items-to-add-on-toolbar). Use a horizontal toolbar for vertical tool windows and a vertical toolbar for horizontal tool windows. For more details, see the [toolbar guidelines](toolbar.md).
#### Horizontal window

Put tool window viewing mode settings under the gear icon in the header. If there is no toolbar, put other options under the gear icon as well. For example, see the gear icon in the Project tool window.
Horizontal tool windows work better for tables, wide content, or master-detail panels, for example, Git Log, Terminal, or Problems.

Add tabs if all the information does not fit in one tab or refers to similar instances, like run sessions, history for files, find results. The tabs for entities should be closable.
![](toolwindow_horizontal.png){width=706}

![](git.png){width=308 style=block}
*Separate tabs are added for each file history.*
### Empty state

![](find.png){width=448 style=block}
*Separate tabs are added for different search queries.*
If a tool window has no content yet, show [empty state](empty_state.md) to help users start working with the tool window.

<table border="false" style="none">
<tr>
<td width="50%"><format color="Green" style="bold">Correct</format><img src="toolwindow_empty_state_correct.png" alt=""/></td>
<td width="50%"><format color="red" style="bold">Incorrect</format><img src="toolwindow_empty_state_incorrect.png" alt=""/></td>
</tr>
</table>