junegunn / goyo.vim

:tulip: Distraction-free writing in Vim
MIT License
4.49k stars 115 forks source link

problem with airline and tabline extension #234

Open prankousky opened 3 years ago

prankousky commented 3 years ago

Hi everybody,

I am using airline and goyo and when I run :Goyo, I get the output below. My output is in German, so I tried to translate it to English best as I could. Can anybody tell me what's wrong and how to fix this? I cannot use Goyo like t his at all.

Error executing "function airline#extension#tabline#get":
Line 14:
E216: no such group or event: airline BufAdd * call <sid>update_tabline(0)
Confirm via RETURN or enter command
# then I press enter
Error executing "function airline#extension#tabline#get":
Line 17:
E216: no such group or event: airline SessionLoadPost * call <sid>update_tabline(1)
Confirm via RETURN or enter command
# then I press enter

After this, depending on the contents, it will display Goyo, or throw more errors. If it does display Goyo (for example, I just tried when .config/nvim/init.vim was in the current buffer), it works fine. However, if there are more errors previously, the visible Goyo space is not centered anymore, but set off to the right (when I just opened an empty buffer with no file extension, wrote some text, ran the Goyo command).

Little update

While writing this, I took a look at my airline related configuration. When I comment out these lines, it seems like Goyo works fine:

" Airline smarte Tabline
let g:airline#extensions#tabline#enabled = 1
let g:airline#extensions#tabline#left_alt_sep = '|'

Does anybody know what to change in order to keep these lines in my config and still not have issues with Goyo and airline?

Thank you for your help :)