rime / librime

Rime Input Method Engine, the core library
https://rime.im
BSD 3-Clause "New" or "Revised" License
3.36k stars 550 forks source link

key_binder: add whences first_page, not_first_page, last_page, not_last_page #927

Open fxliang opened 1 month ago

fxliang commented 1 month ago

Pull request

Issue tracker

Fixes will automatically close the related issue

Fixes #

Feature

Describe feature of pull request add whences: first_page, not_first_page, last_page, not_last_page

it would be helpful when pattern like recognizer/patterns/money: '^/dx\d+(\.\d{0,2})?$' is set, when comma / period is binding to page up / page down.

    - { when: paging, accept: comma, send: Page_Up }
    - { when: not_last_page, accept: period, send: Page_Down }

Unit test

Manual test

Code Review

  1. Unit and manual test pass
  2. GitHub Action CI pass
  3. At least one contributor reviews and votes
  4. Can be merged clean without conflicts
  5. PR will be merged by rebase upstream base

Additional Info