IVsLanguageTextOps.GetWordExtent Yöntem

Tanım

Nokta üzerinde veya yakınında bir sözcüğün veya belirtecin kapsamını döndürür.

public:
 int GetWordExtent(Microsoft::VisualStudio::TextManager::Interop::IVsTextLayer ^ pTextLayer, Microsoft::VisualStudio::TextManager::Interop::TextAddress ta, Microsoft::VisualStudio::TextManager::Interop::WORDEXTFLAGS flags, cli::array <Microsoft::VisualStudio::TextManager::Interop::TextSpan> ^ pts);
public:
 int GetWordExtent(Microsoft::VisualStudio::TextManager::Interop::IVsTextLayer ^ pTextLayer, Microsoft::VisualStudio::TextManager::Interop::TextAddress ta, Microsoft::VisualStudio::TextManager::Interop::WORDEXTFLAGS flags, Platform::Array <Microsoft::VisualStudio::TextManager::Interop::TextSpan> ^ pts);
int GetWordExtent(Microsoft::VisualStudio::TextManager::Interop::IVsTextLayer const & pTextLayer, Microsoft::VisualStudio::TextManager::Interop::TextAddress ta, Microsoft::VisualStudio::TextManager::Interop::WORDEXTFLAGS flags, std::Array <Microsoft::VisualStudio::TextManager::Interop::TextSpan> const & pts);
public int GetWordExtent (Microsoft.VisualStudio.TextManager.Interop.IVsTextLayer pTextLayer, Microsoft.VisualStudio.TextManager.Interop.TextAddress ta, Microsoft.VisualStudio.TextManager.Interop.WORDEXTFLAGS flags, Microsoft.VisualStudio.TextManager.Interop.TextSpan[] pts);
abstract member GetWordExtent : Microsoft.VisualStudio.TextManager.Interop.IVsTextLayer * Microsoft.VisualStudio.TextManager.Interop.TextAddress * Microsoft.VisualStudio.TextManager.Interop.WORDEXTFLAGS * Microsoft.VisualStudio.TextManager.Interop.TextSpan[] -> int
Public Function GetWordExtent (pTextLayer As IVsTextLayer, ta As TextAddress, flags As WORDEXTFLAGS, pts As TextSpan()) As Integer

Parametreler

pTextLayer
IVsTextLayer

'ndaki IVsTextLayer Metin dosyasını temsil eden nesne.

ta
TextAddress

'ndaki Sözcük kapsamını belirleyen karakterlerin metin adresini belirtir. Metin adresi metin katmanındaki metnin konumuyla ilişkilidir. Daha fazla bilgi için bkz. TextAddress.

flags
WORDEXTFLAGS

'ndaki Bir sözcüğün kapsamını belirlemek için seçenekleri belirtir. Daha fazla bilgi için bkz. WORDEXTFLAGS.

pts
TextSpan[]

dışı Sözcüğün tamamını tanımlayan metnin aralığını döndürür. Daha fazla bilgi için bkz. TextSpan.

Döndürülenler

Int32

Yöntem başarılı olursa, döndürür S_OK . Başarısız olursa, bir hata kodu döndürür.

Açıklamalar

COM Imzası

Textmgr. IDL dosyasından:

HRESULT IVsLanguageTextOps::GetWordExtent(  
   [in] IVsTextLayer *pTextLayer,   
   [in] TextAddress ta,   
   [in] WORDEXTFLAGS flags,   
   [out, retval] TextSpan *pts  
);  

Bu yöntem için, ortam bir metin katmanında geçirilir ve sözcüğün nasıl belirlenmesi gerektiğini tanımlayan bir karakter konumunu ve bayrakları tanımlayan bir metin adresidir. Dil hizmetiniz, bu bilgilere göre sözcüğün kapsamına karar verir ve bu bilgileri bir metin yayma yapısında () ortama geri geçirebilirsiniz pts .

Şunlara uygulanır