Skip to content

Locator

Published version: thekevinscott.github.io/curtaincall/api/locator/

curtaincall.locator.Locator

Lazy locator that finds text on a terminal screen.

Created by Terminal.get_by_text(). Doesn't search until properties are accessed or the locator is passed to expect().

cells property

Find all matching cell positions on the screen.

is_visible()

Check if the text is currently visible on screen (no waiting).

click()

Left-click the first matched cell in the viewport.

Doesn't wait: assert expect(locator).to_be_visible() first if the text may not have rendered yet. Raises LookupError if no match is in the viewport (matches that have scrolled into scrollback can't be clicked).

text()

Return the matched text content.