当相应 IContentType 的一个或多个 ITextBuffer 对象连接到 ITextView 时调用。
命名空间: Microsoft.VisualStudio.Text.Editor
程序集: Microsoft.VisualStudio.Text.UI.Wpf(在 Microsoft.VisualStudio.Text.UI.Wpf.dll 中)
语法
声明
Sub SubjectBuffersConnected ( _
textView As IWpfTextView, _
reason As ConnectionReason, _
subjectBuffers As Collection(Of ITextBuffer) _
)
void SubjectBuffersConnected(
IWpfTextView textView,
ConnectionReason reason,
Collection<ITextBuffer> subjectBuffers
)
void SubjectBuffersConnected(
IWpfTextView^ textView,
ConnectionReason reason,
Collection<ITextBuffer^>^ subjectBuffers
)
abstract SubjectBuffersConnected :
textView:IWpfTextView *
reason:ConnectionReason *
subjectBuffers:Collection<ITextBuffer> -> unit
function SubjectBuffersConnected(
textView : IWpfTextView,
reason : ConnectionReason,
subjectBuffers : Collection<ITextBuffer>
)
参数
textView
类型:Microsoft.VisualStudio.Text.Editor.IWpfTextView主题缓冲区要连接到的 IWpfTextView。
reason
类型:Microsoft.VisualStudio.Text.Editor.ConnectionReason连接的原因。
subjectBuffers
类型:Collection<ITextBuffer>具有匹配内容类型的 ITextBuffer 对象的非空列表。
备注
连接可能发生一致三次:
当首次创建视图
当缓冲区容纳 IBufferGraph 的成员视图中
当缓冲区的 IContentType 更改
.NET Framework 安全性
- 对直接调用方的完全信任。此成员不能由部分信任的代码使用。有关详细信息,请参阅通过部分受信任的代码使用库。