Table of Contents

Method Add

Namespace
Terminal.Gui
Assembly
Terminal.Gui.dll

Add(Key, View?, params Command[])

Adds a new key combination that will trigger the commands in commands on the View specified by target.

If the key is already bound to a different array of Commands it will be rebound commands.

public void Add(Key key, View? target, params Command[] commands)

Parameters

key Key

The key to check.

target View

The View the commands will be invoked on. If null, the key will be bound to Application.

commands Command[]

The command to invoked on the when key is pressed. When multiple commands are provided,they will be applied in sequence. The bound key strike will be consumed if any took effect.