Note that there are some explanatory texts on larger screens.

plurals
  1. POVim pumvisible() call putting in random text
    primarykey
    data
    text
    <p>I'm using the spf13 package for Vim. However, whenever I enter some text and press escape, some weird characters get appended to it.</p> <p>For example, if I type this and press escape,</p> <pre><code>hello </code></pre> <p>I get this:</p> <pre><code>hellopumvisible() ? "\" : "\ </code></pre> <p>There is a mapping on my .vimrc file that reads like this, which I think might be responsible:</p> <pre><code>" some convenient mappings inoremap &lt;expr&gt; &lt;Esc&gt; pumvisible() ? "\&lt;C-e&gt;" : "\&lt;Esc&gt;" inoremap &lt;expr&gt; &lt;CR&gt; pumvisible() ? "\&lt;C-y&gt;" : "\&lt;CR&gt;" inoremap &lt;expr&gt; &lt;Down&gt; pumvisible() ? "\&lt;C-n&gt;" : "\&lt;Down&gt;" inoremap &lt;expr&gt; &lt;Up&gt; pumvisible() ? "\&lt;C-p&gt;" : "\&lt;Up&gt;" inoremap &lt;expr&gt; &lt;C-d&gt; pumvisible() ? "\&lt;PageDown&gt;\&lt;C-p&gt;\&lt;C-n&gt;" : "\&lt;C-d&gt;" inoremap &lt;expr&gt; &lt;C-u&gt; pumvisible() ? "\&lt;PageUp&gt;\&lt;C-p&gt;\&lt;C-n&gt;" : "\&lt;C-u&gt;" </code></pre> <p>I guess it's taken from <a href="http://vim.wikia.com/wiki/Improve_completion_popup_menu" rel="nofollow">http://vim.wikia.com/wiki/Improve_completion_popup_menu</a>. But for some reason, this is giving me odd behavior. Any advice?</p> <p><strong>EDIT:</strong> Here's the output of <code>:inoremap &lt;esc&gt;</code></p> <p><code>i &lt;Esc&gt; *@pumvisible() ? '&lt;C-E&gt;' : '&lt;C-R&gt;=&lt;SNR&gt;32_FlushBuffer()&lt;CR&gt;pumvisible() ? "\&lt;C-E&gt;" : "\&lt;Esc&gt;"'</code></p> <p><code>i &lt;Esc&gt; * pumvisible() ? "\&lt;C-E&gt;" : "\&lt;Esc&gt;"</code></p> <p>And I'm using Vim 7.3 on Windows 8.</p> <h2>Solution</h2> <p>The autoclose plugin is interfering with mapping. I've written the steps to remove it here: <a href="http://crossplatform.net/dev/vim-spf13-writes-random-characters-when-pressing-escape.html" rel="nofollow">http://crossplatform.net/dev/vim-spf13-writes-random-characters-when-pressing-escape.html</a>. It works fine now.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload