Skip to content

Commit f801cc4

Browse files
authored
Merge pull request #2467 from damabe/1235779
Content fixes for VS extensibility articles
2 parents c81981d + 7109422 commit f801cc4

21 files changed

+359
-347
lines changed

docs/extensibility/about-file-name-extensions.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,23 +15,23 @@ manager: douge
1515
ms.workload:
1616
- "vssdk"
1717
---
18-
# About File Name Extensions
18+
# About file name extensions
1919
When you register a file extension of a VSPackage, you associate it with a version of [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)]. This is important if more than one version of [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)] is installed on a computer.
2020

21-
File extensions for VSPackages are registered under HKEY_CLASSES_ROOT key with a default value that points to the associated programmatic identifier (ProgID).
21+
File extensions for VSPackages are registered under **HKEY_CLASSES_ROOT** key with a default value that points to the associated programmatic identifier (ProgID).
2222

23-
The following is an example of the registration information for the .vcproj file extension:
23+
The following example shows registration information for the *.vcproj* file extension:
2424

2525
```
2626
HKEY_CLASSES_ROOT\
2727
.vcproj\
2828
(default)=" VisualStudio.vcproj.8.0"
2929
```
3030

31-
Files associated with [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)] must have a versioned ProgID, such as `VisualStudio.vcproj.8.0`, to allow side-by-side installations of the product to maintain file extension associations among product versions. A version-specific ProgID also allows you to use standard verbs, such as open, edit, and so on, without the concern of overwriting or being overwritten by other applications or versions of [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)].
31+
Files associated with [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)] must have a versioned ProgID, such as `VisualStudio.vcproj.8.0`. A versioned ProgID allows side-by-side installations of the product to maintain file extension associations among product versions. A version-specific ProgID also allows you to use standard verbs, such as open, edit, and so on, without the concern of overwriting or being overwritten by other applications or versions of [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)].
3232

33-
In certain cases, the ProgID associated with a file extension should not be changed. For example, the ProgID for the .htm file extension (progid = htmlfile) is hard coded in a number of places in the operating system, and is widely known and used in association with .htm and .html files.
33+
In certain cases, the ProgID associated with a file extension should not be changed. For example, the ProgID for the *.htm* file extension (progid = htmlfile) is hard-coded in a number of places in the operating system, and is widely known and used in association with *.htm* and *.html* files.
3434

35-
## See Also
36-
[Registering File Name Extensions for Side-By-Side Deployments](../extensibility/registering-file-name-extensions-for-side-by-side-deployments.md)
37-
[Specifying File Handlers for File Name Extensions](../extensibility/specifying-file-handlers-for-file-name-extensions.md)
35+
## See also
36+
[Register file name extensions for side-by-side deployments](../extensibility/registering-file-name-extensions-for-side-by-side-deployments.md)
37+
[Specify file handlers for file name extensions](../extensibility/specifying-file-handlers-for-file-name-extensions.md)

docs/extensibility/accessing-stored-font-and-color-settings.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ manager: douge
1616
ms.workload:
1717
- "vssdk"
1818
---
19-
# Accessing Stored Font and Color Settings
19+
# Access stored font and color settings
2020
The [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)] integrated development environment (IDE) stores modified settings for fonts and colors in the registry. You can use the <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage> interface to access these settings.
2121

22-
## To Initiate State Persistence of Fonts and Colors
22+
## To initiate state persistence of fonts and colors
2323
Font and color information is stored by category in the following registry location: [HKCU\SOFTWARE\Microsoft \Visual Studio\\*\<Visual Studio version>*\FontAndColors\\*\<CategoryGUID>*], where *\<CategoryGUID>* is the category GUID.
2424

2525
Therefore, to initiate persistence, a VSPackage must:
@@ -40,7 +40,7 @@ The [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)] integrated develop
4040

4141
- The format of color values that are used.
4242

43-
## To Use State Persistence of Fonts and Colors
43+
## To use state persistence of fonts and colors
4444
Persisting fonts and colors involves:
4545

4646
- Synchronizing the IDE settings with settings stored in the registry.
@@ -58,7 +58,7 @@ The [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)] integrated develop
5858
> [!NOTE]
5959
> Modifications through the **Font and Color** property page generate events independent of <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage>. You can use the <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorCacheManager> interface to determine whether an update of cached font and color settings is needed before calling the methods of the <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage> class.
6060
61-
### Storing and Retrieving Information
61+
### Store and retrieve information
6262
To obtain or configure information that a user can modify for a named display item in an open category, VSPackages call the <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage.GetItem%2A> and <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage.SetItem%2A> methods.
6363

6464
Information about font attributes for a particular category is obtained by using the <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage.GetFont%2A> and <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage.SetFont%2A> methods.
@@ -73,8 +73,8 @@ The [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)] integrated develop
7373
7474
The settings of all **Display Items** in a particular **Category** can be obtained by using the methods of the <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorDefaults> interface.
7575

76-
## See Also
76+
## See also
7777

7878
- <xref:Microsoft.VisualStudio.Shell.Interop.IVsFontAndColorStorage>
7979
- <xref:Microsoft.VisualStudio.Shell.Interop.__FCSTORAGEFLAGS>
80-
- [Implementing Custom Categories and Display Items](../extensibility/implementing-custom-categories-and-display-items.md)
80+
- [Implement custom categories and display items](../extensibility/implementing-custom-categories-and-display-items.md)

docs/extensibility/accessing-text-layers-by-using-the-legacy-api.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ manager: douge
1414
ms.workload:
1515
- "vssdk"
1616
---
17-
# Accessing Text Layers by Using the Legacy API
17+
# Access text layers by using the legacy API
1818
A text layer typically encapsulates some aspect of text layout. For example, a "function-at-a-time" layer hides text before and after a function containing the caret (text insertion point).
1919

2020
A text layer resides between a buffer and a view, and it modifies the way the view sees the buffer's contents.
2121

22-
## Text Layer Information
22+
## Text layer information
2323
The following list describes how text layers work in [!INCLUDE[vsprvs](../code-quality/includes/vsprvs_md.md)]:
2424

2525
- The text in a text layer can be adorned with syntax coloring and markers.
@@ -32,7 +32,7 @@ A text layer typically encapsulates some aspect of text layout. For example, a "
3232

3333
- A layer can affect only layers that are below it. It cannot affect the layers above it beyond originating standard events.
3434

35-
- In the editor, hidden text, synthetic text, and word wrap are implemented as layers. You can implement hidden and synthetic text without interacting directly with the layers. For more information, see [Outlining in a Legacy Language Service](../extensibility/internals/outlining-in-a-legacy-language-service.md) and <xref:Microsoft.VisualStudio.TextManager.Interop.IVsSyntheticTextSession>.
35+
- In the editor, hidden text, synthetic text, and word wrap are implemented as layers. You can implement hidden and synthetic text without interacting directly with the layers. For more information, see [Outlining in a legacy language service](../extensibility/internals/outlining-in-a-legacy-language-service.md) and <xref:Microsoft.VisualStudio.TextManager.Interop.IVsSyntheticTextSession>.
3636

3737
- Each text layer has its own local coordinate system that is exposed through the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextLayer> interface. The line-wrap layer, for example, might contain two lines while the underlying text buffer might contain only one line.
3838

@@ -42,7 +42,7 @@ A text layer typically encapsulates some aspect of text layout. For example, a "
4242

4343
- Besides <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextLayer>, a text layer must implement <xref:Microsoft.VisualStudio.OLE.Interop.IConnectionPointContainer> and fire the events in the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextLinesEvents> interface.
4444

45-
## See Also
46-
[Syntax Coloring in Custom Editors](../extensibility/syntax-coloring-in-custom-editors.md)
47-
[Using Text Markers with the Legacy API](../extensibility/using-text-markers-with-the-legacy-api.md)
48-
[Customizing Editor Controls and Menus by Using the Legacy API](../extensibility/customizing-editor-controls-and-menus-by-using-the-legacy-api.md)
45+
## See also
46+
[Syntax coloring in custom editors](../extensibility/syntax-coloring-in-custom-editors.md)
47+
[Use text markers with the legacy API](../extensibility/using-text-markers-with-the-legacy-api.md)
48+
[Customize editor controls and menus by using the legacy API](../extensibility/customizing-editor-controls-and-menus-by-using-the-legacy-api.md)

docs/extensibility/accessing-the-text-buffer-by-using-the-legacy-api.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ manager: douge
1414
ms.workload:
1515
- "vssdk"
1616
---
17-
# Accessing the Text Buffer by Using the Legacy API
17+
# Access the text buffer by using the legacy API
1818
The text is responsible for managing text streams and file persistence. Although the buffer can read or write other formats, all ordinary communication with the buffer is performed by using Unicode. In the legacy APIs, the text buffer can use either a one- or a two-dimensional coordinate system to identify character locations in the buffer.
1919

20-
## One- and Two-Dimension Coordinate Systems
20+
## One- and two-dimension coordinate systems
2121
A one-dimensional coordinate position is based on a character's position from the first character in the buffer, such as 147. You use the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextStream> interface to access a one-dimensional location in the buffer. A two-dimensional coordinate system is based on line and index pairs. For example, a character in the buffer at 43, 5 would be on line 43, five characters to the right of the first character in that line. You access a two-dimensional location in the buffer using the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextLines> interface. Both the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextLines> and the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextStream> interfaces are implemented by the text buffer object (<xref:Microsoft.VisualStudio.TextManager.Interop.VsTextBuffer>) and can be accessed from each other by using `QueryInterface`. The following diagram shows these and other key interfaces on <xref:Microsoft.VisualStudio.TextManager.Interop.VsTextBuffer>.
2222

2323
![Text Buffer Object](../extensibility/media/vstextbuffer.gif "vsTextBuffer")
@@ -27,12 +27,12 @@ Text buffer object
2727

2828
The text buffer's second responsibility is file persistence. To do this, the text buffer object implements <xref:Microsoft.VisualStudio.Shell.Interop.IVsPersistDocData2> and acts as the document data object component for project items and other environment components involved in persistence. For more information, see [Opening and Saving Project Items](../extensibility/internals/opening-and-saving-project-items.md).
2929

30-
## In This Section
31-
[Changing View Settings by Using the Legacy API](../extensibility/changing-view-settings-by-using-the-legacy-api.md)
30+
## In this section
31+
[Change view settings by using the legacy API](../extensibility/changing-view-settings-by-using-the-legacy-api.md)
3232
Explains how to change view settings using the legacy API.
3333

34-
[Using the Text Manager to Monitor Global Settings](../extensibility/using-the-text-manager-to-monitor-global-settings.md)
35-
Explains how to use the text manager to monitor global settings..
34+
[Use the text manager to monitor global settings](../extensibility/using-the-text-manager-to-monitor-global-settings.md)
35+
Explains how to use the text manager to monitor global settings.
3636

37-
## See Also
38-
[Inside the Core Editor](../extensibility/inside-the-core-editor.md)
37+
## See also
38+
[Inside the core editor](../extensibility/inside-the-core-editor.md)

docs/extensibility/accessing-thetext-view-by-using-the-legacy-api.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ manager: douge
1414
ms.workload:
1515
- "vssdk"
1616
---
17-
# Accessing theText View by Using the Legacy API
17+
# Access the text view by using the legacy API
1818
A text view is a presentation of the text that is stored in a text buffer. You can access the text view by using the legacy API as shown in the following section.
1919

20-
## Text View Object
20+
## Text view object
2121
Each view is associated with its own text buffer, and the view is a window on the data in the buffer. The following diagram shows the key interfaces of the text view object, which is represented by <xref:Microsoft.VisualStudio.TextManager.Interop.VsTextView>.
2222

2323
![Visual Studio Text View Object](../extensibility/media/vstextview.gif "vstextview")
@@ -27,14 +27,14 @@ Text view object
2727

2828
A view enables other services or processes to intercept incoming commands and act on them before the view acts on them. The most common service to do this is a language service. A language service might need, for example, to intercept the command for the ENTER key to provide custom indenting behavior or tool tips.
2929

30-
## Adding Functionality to the Text View
30+
## Add functionality to the text view
3131
You can customize text view behavior by handling specific keystrokes. To intercept the keystrokes, you implement <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextViewFilter> on your object, and provide a command target (<xref:Microsoft.VisualStudio.OLE.Interop.IOleCommandTarget>) to monitor and intercept commands.
3232

3333
The text view uses sequential architecture for command filters. New command filters (<xref:Microsoft.VisualStudio.OLE.Interop.IOleCommandTarget> objects) are added to the sequence by calling the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextView.AddCommandFilter%2A> method.
3434

3535
Event notification for the text view is provided by using the <xref:Microsoft.VisualStudio.TextManager.Interop.IVsTextViewEvents> interface. Implement this interface on your client object to receive notification of changes to the text view. Expose this interface to the text view by using the <xref:Microsoft.VisualStudio.OLE.Interop.IConnectionPointContainer> interface on the text view to receive notification of changes from the view.
3636

37-
## See Also
37+
## See also
3838

39-
- [Changing View Settings by Using the Legacy API](../extensibility/changing-view-settings-by-using-the-legacy-api.md)
40-
- [Using the Text Manager to Monitor Global Settings](../extensibility/using-the-text-manager-to-monitor-global-settings.md)
39+
- [Change view settings by using the legacy API](../extensibility/changing-view-settings-by-using-the-legacy-api.md)
40+
- [Use the text manager to monitor global settings](../extensibility/using-the-text-manager-to-monitor-global-settings.md)

0 commit comments

Comments
 (0)