:right-sidebar: True CellRendererAccel =================================================================== .. currentmodule:: gi.repository.Gtk .. deprecated:: 4.10 Applications editing keyboard accelerators should provide their own implementation according to platform design guidelines .. class:: CellRendererAccel(**properties: ~typing.Any) :no-contents-entry: Superclasses: :class:`~gi.repository.Gtk.CellRendererText`, :class:`~gi.repository.Gtk.CellRenderer`, :class:`~gi.repository.GObject.InitiallyUnowned`, :class:`~gi.repository.GObject.Object` Renders a keyboard accelerator in a cell ``GtkCellRendererAccel`` displays a keyboard accelerator (i.e. a key combination like `Control + a`). If the cell renderer is editable, the accelerator can be changed by simply typing the new combination. Constructors ------------ .. rst-class:: interim-class .. class:: CellRendererAccel :no-index: .. classmethod:: new() -> ~gi.repository.Gtk.CellRenderer Creates a new ``GtkCellRendererAccel``. .. deprecated:: 4.10 Please do not use it in newly written code Properties ---------- .. rst-class:: interim-class .. class:: CellRendererAccel :no-index: .. attribute:: props.accel_key :type: int The keyval of the accelerator. .. attribute:: props.accel_mode :type: ~gi.repository.Gtk.CellRendererAccelMode Determines if the edited accelerators are GTK accelerators. If they are, consumed modifiers are suppressed, only accelerators accepted by GTK are allowed, and the accelerators are rendered in the same way as they are in menus. .. attribute:: props.accel_mods :type: ~gi.repository.Gdk.ModifierType The modifier mask of the accelerator. .. attribute:: props.keycode :type: int The hardware keycode of the accelerator. Note that the hardware keycode is only relevant if the key does not have a keyval. Normally, the keyboard configuration should assign keyvals to all keys. Signals ------- .. rst-class:: interim-class .. class:: CellRendererAccel.signals :no-index: .. method:: accel_cleared(path_string: str) -> None Gets emitted when the user has removed the accelerator. :param path_string: the path identifying the row of the edited cell .. method:: accel_edited(path_string: str, accel_key: int, accel_mods: ~gi.repository.Gdk.ModifierType, hardware_keycode: int) -> None Gets emitted when the user has selected a new accelerator. :param path_string: the path identifying the row of the edited cell :param accel_key: the new accelerator keyval :param accel_mods: the new accelerator modifier mask :param hardware_keycode: the keycode of the new accelerator