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

Allow consant Error Line #102

Open
alexge233 opened this issue Mar 18, 2021 · 3 comments
Open

Allow consant Error Line #102

alexge233 opened this issue Mar 18, 2021 · 3 comments

Comments

@alexge233
Copy link

First of all, thanks for the plugin, it really is awesome and very useful.
There's one thing I'd like to change, because it is driving me nuts.
When there's no errors, all is fine, when there is an error, it jumps, resizes my left border line and keeps creating a movement/animation due to the resizing which is extremely annoying. Now, I can remove the error symbol, but that defeats the purpose of using Semsi, so I wonder if there is an option to allow that vertical border line to be constantly present so that the E> mark does not keep resizing the entire window and thus creating that animation? Point me to the direction if you can and I'll open a PR. Many thanks!

@miezebieze
Copy link

i would be content with an option to disable the error column so only the red block remains
even semshi waiting for me to exit insert mode before it starts throwing red at me would be fine

i investigated the issue but wasn't able to solve the problem but compiled my findings so my efforts aren't in vain
they might help someone else (future me included)

  • removing the text of the errorcolumn by adding to my ~/.config/nvim/init.vim something like
    sign define semshiError text= texthl=semshiErrorSign
    this is the wrong approach because the Nvim documentation explicitly states that signs have to be 1 or 2 characters

  • poking the source
    the code that uses `semshiError' begins at line 224 in semshi/handler.py
    commenting out the responsible calls (self._unplace_sign... and self._place_sign... ) made semshi do nothing at all
    playing around with these two methods and the vim.command calls broke semshi every time for reasons beyond me

  • what i would try if i had more time/concentration
    find out how semshi does the coloration of things and add something that paints errors red

  • defining and placing my own sign to keep the text from jiggling around

    sign define nya text=no
    sign place 31313 0 nya
endfunction
autocmd FileType python call Stf ()```
doesn't work; i'm tired

@miezebieze
Copy link

i'm unable to edit the comment
the last block obviously should be:

function Stf ()
    sign define nya text=FU texthl=semshiSelf
    sign place 31313 1 nya
endfunction
autocmd FileType python call Stf ()

doesn't work; i'm tired

@alexge233
Copy link
Author

Wow, thank you so much for the work you've put in this!
I might have a poke at it if I can find the free time.

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

No branches or pull requests

2 participants