dariogoetz / keyboard_layout_optimizer

A keyboard layout optimizer supporting multiple layers. Implemented in Rust.
https://dariogoetz.github.io/keyboard_layout_optimizer/
GNU General Public License v3.0
92 stars 18 forks source link

Improve newline filtering #26

Closed Glitchy-Tozier closed 2 years ago

Glitchy-Tozier commented 2 years ago

Same idea as the "." / "," pull request.

We only want to filter n-grams that envelop a pause, keeping the ones, that contain a pause but do not follow up with letters after that.

The previous implementation was almost perfect. The only issue I fixed in this PR is that patterns like "\n \n \n" or "{letter} \n \n" used to get filtered and now don't, because they don't contain anything after the beginning of the pause.

I also updated some comments.