Skip to content

Commit

Permalink
E-book viewer: Allow pressing the delete key to delete the currently …
Browse files Browse the repository at this point in the history
…selected highlight.
  • Loading branch information
kovidgoyal committed Mar 14, 2021
1 parent 264f6ef commit a164265
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/pyj/read_book/selection_bar.pyj
Original file line number Diff line number Diff line change
Expand Up @@ -566,6 +566,9 @@ class SelectionBar:
if ev.key is 'Escape':
self.clear_selection()
return
if ev.key is 'Delete':
self.remove_highlight()
return
if ev.key and ev.key.toLowerCase() is 'c' and ev.ctrlKey:
self.copy_to_clipboard()
return
Expand Down

0 comments on commit a164265

Please sign in to comment.