Skip to content

Commit fdfb3e3

Browse files
authored
Merge pull request #4168 from mrlacey/patch-21
correctly refer to "using directives"
2 parents 60af8d2 + 25facde commit fdfb3e3

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

docs/extensibility/adding-a-tool-window.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ ms.workload:
1313
- "vssdk"
1414
---
1515
# Add a tool window
16+
1617
In this walkthrough you learn how to create a tool window and integrate it into Visual Studio in the following ways:
1718

1819
- Add a control to the tool window.
@@ -26,7 +27,8 @@ In this walkthrough you learn how to create a tool window and integrate it into
2627
- Set the default position for the tool window.
2728

2829
## Prerequisites
29-
Starting in Visual Studio 2015, you do not install the Visual Studio SDK from the download center. It is included as an optional feature in Visual Studio setup. You can also install the VS SDK later on. For more information, see [Install the Visual Studio SDK](../extensibility/installing-the-visual-studio-sdk.md).
30+
31+
The Visual Studio SDK is included as an optional feature in Visual Studio setup. For more information, see [Install the Visual Studio SDK](../extensibility/installing-the-visual-studio-sdk.md).
3032

3133
## Create a tool window
3234

@@ -84,7 +86,8 @@ By adding a toolbar in the following manner, you guarantee that its gradients an
8486
By setting the parent GUID and ID to the GUID and ID of the toolbar, you add the group to the toolbar.
8587

8688
## Add a command to the toolbar
87-
Add a command to the toolbar, which is displayed as a button.
89+
90+
Add a command to the toolbar, which is displayed as a button.
8891

8992
1. In the `<Symbols>` section, declare the following IDSymbol elements just after the toolbar and toolbar group declarations.
9093

@@ -132,7 +135,7 @@ public System.Windows.Controls.MediaElement MediaPlayer
132135
## Instantiate the tool window and toolbar
133136
Add a toolbar and a menu command that invokes the **Open File** dialog and plays the selected media file.
134137

135-
1. Open *FirstToolWindow.cs* and add the following `using` statements.
138+
1. Open *FirstToolWindow.cs* and add the following `using` directives:
136139

137140
```csharp
138141
using System.ComponentModel.Design;
@@ -161,7 +164,7 @@ Add a toolbar and a menu command that invokes the **Open File** dialog and plays
161164
this.ToolBarLocation = (int)VSTWT_LOCATION.VSTWT_TOP;
162165
```
163166

164-
5. At this point the FirstToolWindow constructor should look like this:
167+
5. At this point, the FirstToolWindow constructor should look like this:
165168

166169
```csharp
167170
public FirstToolWindow() : base(null)
@@ -177,7 +180,7 @@ Add a toolbar and a menu command that invokes the **Open File** dialog and plays
177180
}
178181
```
179182

180-
6. Add the menu command to the toolbar. In the FirstToolWindowCommand.cs class, add the following using statement
183+
6. Add the menu command to the toolbar. In the FirstToolWindowCommand.cs class, add the following using directive:
181184

182185
```csharp
183186
using System.Windows.Forms;
@@ -243,7 +246,8 @@ Add a toolbar and a menu command that invokes the **Open File** dialog and plays
243246
```
244247

245248
## Set the default position for the tool window
246-
Next, specify a default location in the IDE for the tool window. Configuration information for the tool window is in the *FirstToolWindowPackage.cs* file.
249+
250+
Next, specify a default location in the IDE for the tool window. Configuration information for the tool window is in the *FirstToolWindowPackage.cs* file.
247251

248252
1. In *FirstToolWindowPackage.cs*, find the <xref:Microsoft.VisualStudio.Shell.ProvideToolWindowAttribute> attribute on the `FirstToolWindowPackage` class, which passes the FirstToolWindow type to the constructor. To specify a default position, you must add more parameters to the constructor following example.
249253

0 commit comments

Comments
 (0)