Hi Ted,
Thanks for the reply. I figured that you tried tell me that i confused the two copy-paste methods. You think that I highlight some text, and then ctrl+C (copy text in clipboard selection), then used middle-click in gvim. The random text is because the middle-click pass the text from primary selection (as I highlight other text somewhere else) rather than from clipboard selection.
However, this is not the case. I tried both "*p and "+p. "*p pasted the text from ctrl+C. But, "+p did not pasted anything which I highlighted, instead it shown some text like a latex template.
This situation occurs only when I edit a latex file. The middle-click or "+p/"*p works fine when I edit files with other suffixes.
Any idea?
Liang
On 23 Jul 2012, at 08:38, Ted Pavlic <te...@te...> wrote:
> Liang --
>
> Before continuing, are you sure there's no confusion about "primary"
> and "clipboard" selections in X11? Your trouble may come from being
> accustomed to using vim in a terminal (not an X virtual terminal) and
> then moving to using gvim alone (or, perhaps, vim in a virtual
> terminal in X11). What is getting pasted when you hit your middle
> button is not random; it is likely text you have highlighted (perhaps
> inadvertently) in another window.
>
> Here's a decent reference on primary and clipboard selections in X11
> (in this case, they refer to EMacs and XEmacs, but the general
> description of these different types of selections applies for Vim and
> Gvim as well):
>
> http://www.jwz.org/doc/x-cut-and-paste.html
>
> Your middle mouse button in an X11 application (like GVim) will access
> the "primary" (as opposed to "clipboard") selection. So if you've
> highlighted some text in one window and middle-click in GVim, you
> should expect that highlighted text to get pasted even if you didn't
> explicitly "copy" it anywhere.
>
> It sounds like you would prefer your middle mouse button to do the same thing as
>
> "+p
>
> but instead you're getting the result of
>
> "*p
>
> Is that correct? Can you try those two combinations and compare them
> to your mouse click?
>
> You may be interested in:
>
> :help clipboard
>
> and
>
> :help x11-selection
>
> Best --
> Ted
>
> On Fri, Jul 20, 2012 at 10:46 AM, Liang Guo (Gmail)
> <lia...@gm...> wrote:
>> Hi,
>>
>> I used to use vim-latex in vim-7.3, and I do not have any problem to use mouse middle button to paste text from elsewhere.
>>
>> And, now I try to edit my latex file in gvim-7.3, things getting bizarre. Every time I press middle button, random text is pasted. And this only occurred when I'm editing latex file, files with .tex as suffix. Therefore, I'm sure it is something related to vim-latex in gvim.
>>
>> Does anyone encounter the similar problem?
>>
>> Thank you,
>> Liang
>>
>>
>> ------------------------------------------------------------------------------
>> Live Security Virtual Conference
>> Exclusive live event will cover all the ways today's security and
>> threat landscape has changed and how IT managers can respond. Discussions
>> will include endpoint security, mobile security and the latest in malware
>> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>> _______________________________________________
>> Vim-latex-devel mailing list
>> Vim...@li...
>> https://lists.sourceforge.net/lists/listinfo/vim-latex-devel
>
>
>
> --
> Ted Pavlic <te...@te...>
|