ButtonMap
from panda3d.core import ButtonMap
- class ButtonMap
- Bases: - TypedReferenceCount- This class represents a map containing all of the buttons of a (keyboard) device, though it can also be used as a generic mapping between ButtonHandles. It maps an underlying ‘raw’ button to a ‘virtual’ button, which may optionally be associated with an appropriate platform-specific name for the button. - Inheritance diagram - __init__(*args, **kwargs)
 - getClassType()
- C++ Interface: get_class_type() 
 - getMappedButton()
- C++ Interface: get_mapped_button(ButtonMap self, ButtonHandle raw) get_mapped_button(ButtonMap self, str raw_name) get_mapped_button(ButtonMap self, int i) - /**
- Returns the nth mapped button, meaning the button that the nth raw button 
- is mapped to. 
 - */ 
- /**
- Returns the button that the given button is mapped to, or 
- ButtonHandle::none() if this map does not specify a mapped button for the 
- given raw button. 
 - */ 
- /**
- Returns the button that the given button is mapped to, or 
- ButtonHandle::none() if this map does not specify a mapped button for the 
- given raw button. 
 - */ 
 
 - getMappedButtonLabel()
- C++ Interface: get_mapped_button_label(ButtonMap self, ButtonHandle raw) get_mapped_button_label(ButtonMap self, str raw_name) get_mapped_button_label(ButtonMap self, int i) - /**
- Returns the label associated with the nth mapped button, meaning the button 
- that the nth raw button is mapped to. 
 - */ 
- /**
- If the button map specifies a special name for the button (eg. if the 
- operating system or keyboard device has a localized name describing the 
- key), returns it, or the empty string otherwise. 
- Note that this is not the same as get_mapped_button().get_name(), which 
- returns the name of the Panda event associated with the button. 
 - */ 
- /**
- If the button map specifies a special name for the button (eg. if the 
- operating system or keyboard device has a localized name describing the 
- key), returns it, or the empty string otherwise. 
- Note that this is not the same as get_mapped_button().get_name(), which 
- returns the name of the Panda event associated with the button. 
 - */ 
 
 - getNumButtons()
- C++ Interface: get_num_buttons(ButtonMap self) - /**
- Returns the number of buttons that this button mapping specifies. 
 - */ 
 
 - getRawButton()
- C++ Interface: get_raw_button(ButtonMap self, int i) - /**
- Returns the underlying raw button associated with the nth button. 
 - */ 
 
 - get_class_type()
- C++ Interface: get_class_type() 
 - get_mapped_button()
- C++ Interface: get_mapped_button(ButtonMap self, ButtonHandle raw) get_mapped_button(ButtonMap self, str raw_name) get_mapped_button(ButtonMap self, int i) - /**
- Returns the nth mapped button, meaning the button that the nth raw button 
- is mapped to. 
 - */ 
- /**
- Returns the button that the given button is mapped to, or 
- ButtonHandle::none() if this map does not specify a mapped button for the 
- given raw button. 
 - */ 
- /**
- Returns the button that the given button is mapped to, or 
- ButtonHandle::none() if this map does not specify a mapped button for the 
- given raw button. 
 - */ 
 
 - get_mapped_button_label()
- C++ Interface: get_mapped_button_label(ButtonMap self, ButtonHandle raw) get_mapped_button_label(ButtonMap self, str raw_name) get_mapped_button_label(ButtonMap self, int i) - /**
- Returns the label associated with the nth mapped button, meaning the button 
- that the nth raw button is mapped to. 
 - */ 
- /**
- If the button map specifies a special name for the button (eg. if the 
- operating system or keyboard device has a localized name describing the 
- key), returns it, or the empty string otherwise. 
- Note that this is not the same as get_mapped_button().get_name(), which 
- returns the name of the Panda event associated with the button. 
 - */ 
- /**
- If the button map specifies a special name for the button (eg. if the 
- operating system or keyboard device has a localized name describing the 
- key), returns it, or the empty string otherwise. 
- Note that this is not the same as get_mapped_button().get_name(), which 
- returns the name of the Panda event associated with the button. 
 - */ 
 
 - get_num_buttons()
- C++ Interface: get_num_buttons(ButtonMap self) - /**
- Returns the number of buttons that this button mapping specifies. 
 - */ 
 
 
