windowCount
Returns the number of on-screen windows the front app has.
Keyboard Maestro: WINDOWCOUNT
Details #
windowCount() takes no arguments and returns a whole number: how many ordinary windows the front app has on screen. Only ordinary windows are counted, front one first; tiny windows and non-standard layers such as the menu bar are left out.
Parameters #
Takes 0 arguments.
{{ windowCount() }}
Examples #
windowCount()→
0windowCount() > 0→
falseGotchas #
Calling it with an argument is an error:
windowCount() takes 0 arguments, got 1.Only windows currently on screen are counted, so minimized and hidden windows are left out.
With nothing real to read, the answer is 0.