Method GTK2.Label()->set_mnemonic_widget()
- Method
set_mnemonic_widget
GTK2.Label
set_mnemonic_widget(GTK2.Widget
widget
)- Description
If the label has been set so that it has a mnemonic key (using i.e. set_markup_with_mnemonic(), set_text_with_mnemonic(), or the "use_underline" property) the label can be associated with a widget that is the target of the mnemonic. When the label is inside a widget (like a GTK2.Button or GTK2.Notebook tab) it is automatically associated with the correct widget, but sometimes (i.e. when the target is a GTK2.Entry next to the label) you need to set it explicitly using this function.
The target widget will be accelerated by emitting "mnemonic_activate" on it. The default handler for this signal will activate the widget if there are no mnemonic collisions and toggle focus between the colliding widgets otherwise.