# Keyboard shortcuts to switch between modeBarButtons

**URL:** https://community.plotly.com/t/keyboard-shortcuts-to-switch-between-modebarbuttons/73974
**Category:** 📊 Plotly Python
**Created:** [March 29, 2023, 4:17pm UTC](https://community.plotly.com/t/keyboard-shortcuts-to-switch-between-modebarbuttons/73974 "2023-03-29T16:17:57Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![robin1](https://avatars.discourse-cdn.com/v4/letter/r/ce73a5/32.png) [@robin1](https://community.plotly.com/u/robin1)
#### Post date: [March 29, 2023, 4:17pm UTC](https://community.plotly.com/t/keyboard-shortcuts-to-switch-between-modebarbuttons/73974/1 "2023-03-29T16:17:57Z")

</div>

I have a go.Candlestick chart where at the top right I have clickable buttons to zoom (default) and to draw lines (that I have added with “fig.show(config={‘modeBarButtonsToAdd’:[‘drawline’]})”).

Is there a way to configure keyboard shortcuts to quickly switch between e.g. the mode zoom and the mode drawline? Right now I have to click on the corresponding button each time I want to swtich mode, but would prefer a keyboard shortcut instead.

Thanks
