# ButtonRegistry

from pandac.PandaModules import ButtonRegistry

Class : ButtonRegistry
Description : The ButtonRegistry class maintains all the assigned ButtonHandles in a given system. There should be only one ButtonRegistry class during the lifetime of the application.

## Inheritance:

ButtonRegistry:

## Methods of ButtonRegistry:

findAsciiButton
getButton
ptr
write

findAsciiButton ButtonHandle ButtonRegistry::find_ascii_button(char ascii_equivalent) const; Description: Finds a ButtonHandle in the registry matching the indicated ASCII equivalent character. If there is no such ButtonHandle, returns ButtonHandle::none().

getButton ButtonHandle ButtonRegistry::get_button(string const &name); Description: Finds a ButtonHandle in the registry matching the indicated name. If there is no such ButtonHandle, registers a new one and returns it.

ptr static ButtonRegistry *ButtonRegistry::ptr(void); ptr() returns the pointer to the global ButtonRegistry object. Description: Returns the pointer to the global ButtonRegistry object.

write void ButtonRegistry::write(ostream &out) const; Description: