Window#

class pixel_forge.Window(name: str)#

Platform-agnostic window abstraction.

Windows can be used as a capture target for the Capture class.

property name: str#

The window name.

property valid: bool#

True if the window is still valid (i.e., open), else False.

pixel_forge.foreground_window() Window#

Get the current foreground window.

Returns:

The foreground window.

Raises:

RuntimeError – No foreground window was found.

pixel_forge.enumerate_windows() list[Window]#

Create a list of all windows that are currently available.

Returns:

The list of all windows.

Raises:

RuntimeError – If the window enumeration fails.