-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Select Smaller/Larger/Next/Previous Syntax Nodes (#105)
* refactor: Remove duplication in tst_codedocument By moving the project setup into a macro we can save quite a few lines of code. * feat: Add TreeCursor to the treesitter wrapper * feat: Add "Select Smaller/Larger Syntax Node" This allows to navigate the code semantically. * refactor: Reduce code duplication in MainWindow Most functions were the same with only different function name and document type. We can replace those implementations with a macro. * feat: Allow navigating to sibling syntax nodes This patch adds functions to select the next/previous syntax node. Combined with the previously added functions to select the larger/smaller syntax node, this allows for very useful semantic code navigation. * chore(docs): Update CodeDocument docs * fix: Use LOG_AND_MERGE for syntax node movement This aggregates the counts, which improves the history a lot. * chore: Incorporate requested changes Use LOG_RETURN in the select*SyntaxNode methods. Add a warning if selectSmallerSyntaxNode doesn't find anything to select.
- Loading branch information
1 parent
5746b64
commit cd81b3b
Showing
14 changed files
with
580 additions
and
139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.