button.clickButton element

getButton(id).click() (since PennController 1.2)

Simulates a click on the button.

Example:

newKey(" ")
    .settings.callback(
        getButton("continue")
            .click()
    )
,
newButton("continue", "Continue")
    .print()
    .wait()

Creates a Key element associated with the spacebar which, whenever pressed, will simulate a click on the continue button added below it, then will wait until the button is clicked (or thus until the spacebar is pressed) before proceeding.