Skip to content

fix(behaviors): Deactivate caps_word after modified numerics#2731

Closed
matthewtodd wants to merge 1 commit intozmkfirmware:mainfrom
matthewtodd:caps-word-deactivate-by-numeric-with-modifiers
Closed

fix(behaviors): Deactivate caps_word after modified numerics#2731
matthewtodd wants to merge 1 commit intozmkfirmware:mainfrom
matthewtodd:caps-word-deactivate-by-numeric-with-modifiers

Conversation

@matthewtodd
Copy link
Copy Markdown

@matthewtodd matthewtodd commented Dec 22, 2024

Fixes #2723.

The caps_word behavior now strictly honors [A-Za-z0-9_] as the default continuation characters. (Previously !@#$%^&*() were mistakenly also honored.)

I discovered this by trying to use caps_word for comment markers like FIXME(mt): and finding that the opening left parenthesis didn't deactivate caps_word.

PR check-list

  • Branch has a clean commit history
  • Additional tests are included, if changing behaviors/core code that is testable.
  • Proper Copyright + License headers added to applicable files (Generally, we stick to "The ZMK Contributors" for copyrights to help avoid churn when files get edited)
  • Pre-commit used to check formatting of files, commit messages, etc.
  • Includes any necessary documentation changes.

Fixes zmkfirmware#2723.

The caps_word behavior now strictly honors `[A-Za-z0-9_]` as the default
continuation characters. (Previously `!@#$%^&*()` were mistakenly also
honored.)

I discovered this by trying to use caps_word for comment markers like
`FIXME(mt):` and finding that the opening left parenthesis didn't
deactivate caps_word.
@matthewtodd matthewtodd requested a review from a team as a code owner December 22, 2024 17:44
@matthewtodd
Copy link
Copy Markdown
Author

After asking in Discord, it seems like the path forward is to build something on top of #1742 instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

caps_word_is_numeric may need to honor ev->implicit_modifiers

1 participant