ZZufyUI文档首页DocumentationДокументацияDokumentationDocumentationDocumentación

正在准备文档Preparing your docsПодготовка документацииDokumentation wird geladenPréparation de la documentationPreparando la documentación

Language

API reference / v1.29.1

Accessibility & Debug Channel

UIA + SetDebugEnabled (v1.17.0)

Download Markdown

Accessibility (UIA)

  • The provider comes from ZufyUIWindowTool.h; element APIs are in the "Element base" chapter.
  • Window APIs: SetAccessibilityEnabled(bool) (on by default), FocusElement, GetFocused/Hovered/PressedElement.

Pitfall

  • the library stores no history and does no file I/O; the provider reflects only the current frame. WM_GETOBJECT is handled only when enabled.

Debug / automation channel

inline void SetDebugEnabled(bool);   inline bool IsDebugEnabled();
  • Off by default. When on, the target window handles WM_COPYDATA (dwData = command id; reply 0x5A554631) and returns current-frame info only (no file I/O).
Cmd Action Cmd Action
1 Ping 12 ClearHighlight
2 ListWindows 13 GetErrors (unified log E/W/I/D, ≤500)
3 GetFrameStats 14 ClearErrors
4 GetElementTree 15/16/17 TopN repaint/layout/cache (all = all)
5 ForceRepaint 18 TopN draw
6 SetElementText("id\ttext") 19 ResetCounters
7 InvokeElement 20 SetVisible("id\t0/1")
8 FocusElement 21 SetMargin("id\tx\ty")
9 GetElementInfo 22 SetHighlightColor("RRGGBB")
10 GetElementAt("x,y" screen→AutomationId)
11 Highlight(id) 23 GetTheme (theme name + AARRGGBB per role)
  • Unified log: detail::Log(level, tag, msg) / LogWarning/LogInfo/DebugLog / RecordError (→ E level + fires UIZSignals::Error).

Pitfall

  • send commands with a timeout (SendMessageTimeout without SMTO_BLOCK), or the debugger hangs when the target is busy. ZUFYUI_DEBUG is a compile-time switch (logging); SetDebugEnabled is a runtime switch (channel/stats) — do not conflate.
View sourcedocs/src/API.en.md