hs.uielement
A generalized framework for working with OSX UI elements
Submodules
API Overview
- Functions - API calls offered directly by the extension
- Methods - API calls which can only be made on an object returned by a constructor
API Documentation
Functions
focusedElement
| Signature | hs.uielement.focusedElement() -> element or nil |
|---|---|
| Type | Function |
| Description |
Gets the currently focused UI element |
| Parameters |
|
| Returns |
|
| Source | extensions/uielement/libuielement.m line 12 |
Methods
isApplication
| Signature | hs.uielement:isApplication() -> bool |
|---|---|
| Type | Method |
| Description |
Returns whether the UI element represents an application. |
| Parameters |
|
| Returns |
|
| Source | extensions/uielement/uielement.lua line 14 |
isWindow
| Signature | hs.uielement:isWindow() -> bool |
|---|---|
| Type | Method |
| Description |
Returns whether the UI element represents a window. |
| Parameters |
|
| Returns |
|
| Source | extensions/uielement/libuielement.m line 29 |
newWatcher
| Signature | hs.uielement:newWatcher(handler[, userData]) -> hs.uielement.watcher or nil |
|---|---|
| Type | Method |
| Description |
Creates a new watcher |
| Parameters |
|
| Returns |
|
| Source | extensions/uielement/libuielement.m line 86 |
role
| Signature | hs.uielement:role() -> string |
|---|---|
| Type | Method |
| Description |
Returns the role of the element. |
| Parameters |
|
| Returns |
|
| Source | extensions/uielement/libuielement.m line 47 |
selectedText
| Signature | hs.uielement:selectedText() -> string or nil |
|---|---|
| Type | Method |
| Description |
Returns the selected text in the element |
| Parameters |
|
| Returns |
|
| Notes |
|
| Source | extensions/uielement/libuielement.m line 65 |
© 2014–2017 Hammerspoon contributors
Licensed under the MIT License.
https://www.hammerspoon.org/docs/hs.uielement.html