DocumentAutomationPeer 類別
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
將 Document 控制項類型公開至使用者介面自動化。
public ref class DocumentAutomationPeer : System::Windows::Automation::Peers::ContentTextAutomationPeer
public class DocumentAutomationPeer : System.Windows.Automation.Peers.ContentTextAutomationPeer
type DocumentAutomationPeer = class
inherit ContentTextAutomationPeer
Public Class DocumentAutomationPeer
Inherits ContentTextAutomationPeer
- 繼承
備註
DocumentAutomationPeer表示檔和支援 TextPattern 。 或 之類的 FixedDocumentFlowDocument 物件可以包含内嵌物件,例如影像和超連結。 一開始,當您嘗試取得檔的子項目時, DocumentAutomationPeer.GetChildrenCore 不會傳回内嵌物件。 若要取得內嵌專案,請從 TextPattern 取得 TextPatternRange ,並呼叫 TextPatternRange.GetChildren 。 呼叫 之後 TextPatternRange.GetChildren ,所傳 DocumentAutomationPeer.GetChildrenCore 回的任何 專案 TextPatternRange 。
注意
除非您知道檔是 FlowDocument ,否則您不應該在 屬性上 TextPattern.DocumentRange 呼叫 GetChildren 。 如果檔是從網路位置載入,請在整個檔上呼叫 GetChildren 會耗用大量資源。 相反地,您應該使用其中 TextPattern 一個方法,傳回 TextPatternRange 代表檔的一部分。
建構函式
DocumentAutomationPeer(FrameworkContentElement) |
初始化 DocumentAutomationPeer 類別的新執行個體。 |
屬性
Dispatcher |
取得與這個 Dispatcher 關聯的 DispatcherObject。 (繼承來源 DispatcherObject) |
EventsSource |
取得或設定 AutomationPeer,其報告至自動化用戶端,作為所有來自此 AutomationPeer 的事件來源。 (繼承來源 AutomationPeer) |
IsHwndHost |
取得值,這個值表示是否與 WPF Windows Presentation Foundation (中這個 AutomationPeer 主機 |
Owner |
取得與 ContentElementAutomationPeer 相關聯的 ContentElement。 (繼承來源 ContentElementAutomationPeer) |
方法
適用於
另請參閱
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應