This repository was archived by the owner on Apr 16, 2024. It is now read-only.
feat: add very basic syntax highlighting#60
Open
MaartenS11 wants to merge 4 commits intoMouwrice:mainfrom
Open
feat: add very basic syntax highlighting#60MaartenS11 wants to merge 4 commits intoMouwrice:mainfrom
MaartenS11 wants to merge 4 commits intoMouwrice:mainfrom
Conversation
Currently just splits the string in 2 so the arguments have a different colour than the opcode but this does mean that things like commas are also highlighted in a colour.
Owner
|
@MaartenS11 I haven't jet written any docs but we use ktlint. I recommend you install the intellij plugin, and there is a pre-commit hook that you can install that will automatically format any staged files. (Not sure if it gets automatically installed on gradle sync) Suggestion: split the instruction string on spaces and then color all elements that are not the first element. |
This file contains hidden or 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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently just splits the string in 2 so the arguments have a different colour than the opcode but this does mean that things like commas are also highlighted.
Result:

Or in light mode(carefully placed in a spoiler):
Or dark mode with the seedColor=Color.Green