Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/stofte/tree-sitter-demo
tree-sitter demonstration project
https://github.com/stofte/tree-sitter-demo
demo tree-sitter
Last synced: 17 days ago
JSON representation
tree-sitter demonstration project
- Host: GitHub
- URL: https://github.com/stofte/tree-sitter-demo
- Owner: stofte
- Created: 2024-09-26T21:28:51.000Z (4 months ago)
- Default Branch: master
- Last Pushed: 2024-11-19T17:23:05.000Z (3 months ago)
- Last Synced: 2024-11-19T18:33:23.042Z (3 months ago)
- Topics: demo, tree-sitter
- Language: C
- Homepage:
- Size: 2.33 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# TreeSitter Demo Editor
This repository contains a simple [tree-sitter](https://tree-sitter.github.io/tree-sitter/) wrapper library written in C,
and a C# based WinForms based editor, which integrates to it using P/Invoke,
which demonstrates the basic ideas required for hosting and utilizing
tree-sitter to perform syntax-highlighting.This has been tested on Windows 11, using VS2022.
![image](test-editor.png)
## Build
- Initialize the git submodules (`git submodule init` and `git submodule update`)
- Run `build.bat` in the Developer Command Prompt for VS 2022 (careful to use the 64bit version of `CL.EXE`)
- Open `test-editor.sln` and press F5
- Dart ffi example can be running `dart run main.dart` in the `dart` folder## Notes
- Editor performance is quite poor, since it "just" builds on the RichTextBox control.