-
Notifications
You must be signed in to change notification settings - Fork 28
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
Implement highlighting of evaluated code #21
Implement highlighting of evaluated code #21
Conversation
The sluggishness could be that the Something like:
|
@blacksound thanks that's definitely better! |
Maybe it would be good to add a version detect for this, so that we keep compatibility with Vim < 8.0? A quick look at the vim source code also suggests that the "timers" attribute is set if the version is compiled with timers, so you could try an alternative check with |
@blacksound Thanks, much appreciated! |
ftplugin/supercollider.vim
Outdated
redraw | ||
sleep 150m | ||
|
||
" timers were introdiced in vim-8.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small typo 'introduced'
If possible, i.e. if vim was built with timers support (>=0.8)
@blacksound Fixed! |
Anyone tested that one? I find it pretty useful, even if it's a bit laggy.. I'd love to know if that works on osx. |
Hi @gusano, I gave it a try on MacOS Sierra/iTerm2/homebrew vim 8 (had to think about how to get that PR into my setup first ;). Solved it with doing in .vim/bundle/scvim:
) With light testing I can say it seems to work well in my setup. Thanks! |
@blacksound bump =) |
Sorry for the delay. Merging now. |
It works great! Thanks a lot for small - yet very important improvement. |
@K0F welcome = ) |
This is the first time I try to write vimscript ever so please bear with me if I did something stupid : )
This implements highlighting of evaluated code (line or block) (
term=reverse cterm=reverse
so everyone is happy! ;)It has to be enabled with
let g:scFlash = 1
in your.vimrc
.It works but it looks like there's a small delay between code evaluation and highlighting..
Could it be because of vim redrawing?
Any hints or suggestions are more than welcome!
Please test it!
ps: the changed files have mixed indention styles so I tried my best to not mess it up, but new code uses spaces, sorry :)
Fix #12
Fix sbl/scvim#42