Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add go plugin + Kanagawa theme (Light Mode, Dark Mode) #43

Merged
merged 11 commits into from
Mar 24, 2024

Conversation

zSnails
Copy link
Contributor

@zSnails zSnails commented Mar 23, 2024

Pretty much what the title says, let me know if I missed anything

Added highlights for all built in functions, datatypes and keywords.
This will also recognize the arguments of a function and add them to the
variables list.
@zSnails zSnails changed the title Add go plugin Add go plugin + Kanagawa theme (Light Mode, Dark Mode) Mar 23, 2024
@zSnails
Copy link
Contributor Author

zSnails commented Mar 23, 2024

I was going to add the plugin and both themes in their own pull request, but things happened, and I ended up uploading the dark theme to this branch as well, oh well

Copy link
Owner

@face-hh face-hh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"inteface" should be "interface" instead

@Symmettry
Copy link
Contributor

to_list function is useless. Just table.insert(table, match) instead of table[match] = match

@zSnails
Copy link
Contributor Author

zSnails commented Mar 24, 2024

@Symmettry I did that to avoid repeating function and variable names on the autocomplete menu

With the to_list workaround.
image

Without the to_list workaround
image

@Symmettry
Copy link
Contributor

Just check if the list doesn’t have it?

@zSnails
Copy link
Contributor Author

zSnails commented Mar 24, 2024

@Symmettry well you could do it that way, although that'd be a bit slow wouldn't it? :^), checking if the list doesn't have it will be O(n), with this method it's always O(1), and yes, I know that this is just a toy editor and that no one's using this for actual coding, just stating why I did it, I'll change it

@Symmettry
Copy link
Contributor

Or you could also ignore it anyway. I feel it might be better if GriddyCode itself dealt with repeats.

@zSnails
Copy link
Contributor Author

zSnails commented Mar 24, 2024

Yeah that'd be a lot better, but having the same name show up 7 times in the autocomplete menu is kinda whack, I could open an issue and discuss that.

Having LSP support would be the next logical step, but I can't help with that as I don't have that much free time to work on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants