VirtualSnapshotPoint.TranslateTo 方法 (ITextSnapshot, PointTrackingMode)

将此点转换为指定的文本快照在指定的跟踪模式。

命名空间:  Microsoft.VisualStudio.Text
程序集:  Microsoft.VisualStudio.Text.Logic(在 Microsoft.VisualStudio.Text.Logic.dll 中)

语法

声明
Public Function TranslateTo ( _
    snapshot As ITextSnapshot, _
    trackingMode As PointTrackingMode _
) As VirtualSnapshotPoint
public VirtualSnapshotPoint TranslateTo(
    ITextSnapshot snapshot,
    PointTrackingMode trackingMode
)
public:
VirtualSnapshotPoint TranslateTo(
    ITextSnapshot^ snapshot, 
    PointTrackingMode trackingMode
)
member TranslateTo : 
        snapshot:ITextSnapshot * 
        trackingMode:PointTrackingMode -> VirtualSnapshotPoint
public function TranslateTo(
    snapshot : ITextSnapshot, 
    trackingMode : PointTrackingMode
) : VirtualSnapshotPoint

参数

返回值

类型:Microsoft.VisualStudio.Text.VirtualSnapshotPoint
snapshot 中对应的 VirtualSnapshotPoint

异常

异常 条件
ArgumentException

snapshot 为早期快照。

备注

" 跟踪模式是相对虚拟点,而不是快照点。 如果该点位于虚空格,它将正常运行,就象基础 (非虚拟) 点始终跟踪,就象,因为所有文本插入到点 (在行尾它打开) 在”虚拟之前要插入 “点。

.NET Framework 安全性

请参阅

参考

VirtualSnapshotPoint 结构

TranslateTo 重载

Microsoft.VisualStudio.Text 命名空间