junegunn / goyo.vim

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

After using goyo, tabnew creates a nomodifiable buffer. #5

Closed itchyny closed 10 years ago

itchyny commented 10 years ago

To reproduce:

:Goyo
:Goyo
:tabnew

Problem: The new buffer is nomodifiable.

To fix: Use setlocal in the two set statement in the function setup_pad.

I don't read the whle code well so I don't get why this function is called on tabnew.

junegunn commented 10 years ago

Whoa, you're right, setlocal fixes the problem. Thanks (The function is not called though as autocommand groups are properly cleared when Goyo tab is closed.)