IBinaryRibbonKeyTipControl
Implemented by a control that does something of its own when its key tip is typed – a button clicks, a tab selects itself, a menu opens.
public interface IBinaryRibbonKeyTipControl
Remarks
When the user types the letters of a control's key tip (BinaryKeyTip.SetAccessKey),
the key tips call IBinaryRibbonKeyTipControl.PerformKeyTipExecute on it. A control that does not implement this
interface gets a default: a CheckBox is ticked or cleared, a ComboBox
drops down, a TextBox takes the focus with its text selected, and anything else
focusable takes the focus. Every ribbon control implements it already; implement it on a control of
your own to give its key tip an action.
Examples
public class ColourSwatch : Control, IBinaryRibbonKeyTipControl
{
public event EventHandler Picked;
void IBinaryRibbonKeyTipControl.PerformKeyTipExecute()
{
Picked?.Invoke(this, EventArgs.Empty);
}
}See also
Members at a glance
| Methods | |
|---|---|
PerformKeyTipExecute | Does what the control's key tip stands for, as though the user had clicked it. |
Methods
PerformKeyTipExecute
Does what the control's key tip stands for, as though the user had clicked it.
Remarks
Called after the key tips have been taken down. If the control's
BinaryKeyTip.SetDeferOrDisable is on, the key tips of the elements inside it are shown
next, so a tab can select itself here and have its commands' key tips follow.