Skip to content

Add next mistake and previous mistake buttons#132

Open
Chewt wants to merge 3 commits into
rooklift:mainfrom
Chewt:next-prev-mistake
Open

Add next mistake and previous mistake buttons#132
Chewt wants to merge 3 commits into
rooklift:mainfrom
Chewt:next-prev-mistake

Conversation

@Chewt

@Chewt Chewt commented Jan 23, 2025

Copy link
Copy Markdown

The next mistake button will jump to the next move that drops in score by at least 3 points. This is a feature inspired by a similar feature in katrain, however I like the interface of ogatak more and would like to start using it instead. The previous mistake button does the same thing but goes backwards in the tree.

I set the keybinds as CTRL+SHIFT+N for next mistake and CTRL+SHIFT+P for previous mistake, but I'm open to discussing alternatives. I personally think CTRL+UP/DOWN arrows would be better, but the code that prevents scrolling makes it difficult to bind anything else to Up/Down arrows.

I also think having some kind of customization for the mistake threshold would be a good idea, I am just unsure of where that should live. For now it is hardcoded as a loss of 3 or more points.

The next mistake button will jump to the next move that drops in score
by at least 3 points. This is a feature inspired by katrain. The
previous mistake button does the same thing but goes backwards in the
tree.
@Chewt

Chewt commented Jan 23, 2025

Copy link
Copy Markdown
Author

Here is a screenshot of the added menu buttons:
image

@rooklift rooklift added the enhancement New feature or request label Jan 23, 2025
Chewt added 2 commits January 25, 2025 09:54
The order of the buttons has been changed to be more consistent with the
rest of the menu options in the Tree menu. They have also been moved to
below the Forward and Backward buttons as I think it makes more sense
this way.
@Chewt

Chewt commented Jan 25, 2025

Copy link
Copy Markdown
Author

I swapped the order of the previous/next mistake buttons to be more consistent with the other buttons in the Tree menu. I also moved them down to below the forward/backward buttons as I think it makes a little bit more sense
image

Additionally I added the mistake threshold as an option in config.json as I believe having that customizable is useful.

Hopefully these changes add a little bit more polish to this PR. Let me know if there are any changes you would like, or if you have any hesitations about this feature!

@rooklift

Copy link
Copy Markdown
Owner

It's fine as a PR, I might not actually accept it since everything is already too complicated for the user. I myself tend to find mistakes just by looking at the graph.

@Chewt

Chewt commented Jan 26, 2025

Copy link
Copy Markdown
Author

Fair enough. It's a useful feature for me so I'll keep on using it. I figure if I add something to software for myself, I might as well open a PR in case others want to use it too.

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

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants