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

Highlight start of code block when selecting the end, and vice versa #21

Open
sstine opened this issue Aug 13, 2016 · 7 comments · May be fixed by #34
Open

Highlight start of code block when selecting the end, and vice versa #21

sstine opened this issue Aug 13, 2016 · 7 comments · May be fixed by #34

Comments

@sstine
Copy link

sstine commented Aug 13, 2016

It'd be nice if when selecting end in the code block below, def is highlighted, and vice versa. Currently VSCode just highlights other instances of end.

def myfunc do
  # stuff
end
@mat-mcloughlin
Copy link
Collaborator

worryingly when I searched google for how/if this is possible this issue came up. I'm not sure if this is achievable with the VSCode extensions at the moment but I will look into it

@fahrradflucht
Copy link
Contributor

fahrradflucht commented Aug 23, 2016

I think the Ruby extension does this. I already tried finding the code that does this but got tired.

@plamb
Copy link

plamb commented Oct 10, 2016

It may be a completely separate thing but matching/highlighting in eex templates would be a welcome addition too. Specifically on opening/closing element tags, i.e.

, and opening closing < >. If you switch the language over to the stock html one it does this already. It looks like for eex it is highlighting all instances of a given tag.

@timmhirsens
Copy link
Owner

https://github.com/rubyide/vscode-ruby/blob/master/ruby.js#L11

This is how the ruby plugin does it (see the following lines)
I will try to implement this here, if noone else wants to take a look?

@timmhirsens timmhirsens reopened this Dec 8, 2016
@timmhirsens timmhirsens self-assigned this Dec 8, 2016
timmhirsens added a commit that referenced this issue Dec 8, 2016
Beginning working on highlighting code blocks.
@timmhirsens timmhirsens linked a pull request Dec 8, 2016 that will close this issue
@richjdsmith
Copy link

richjdsmith commented Oct 24, 2017

Did this end up getting updated? @fr1zle

@timmhirsens
Copy link
Owner

@richjdsmith Sadly, no. I tried doing this in #34 but there are many edge cases not covered. Feel free to look into it, though!

@TimFung93
Copy link

I can try and take a look at this

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

Successfully merging a pull request may close this issue.

7 participants