Philip Rhoades | 31 Jul 09:40 2015
Picon

Re: Vim commands for copying to system clipboard but text does not show up in Clipman

Noah,

On 2015-07-31 17:08, Noah Petherbridge wrote:
> The yy command in vim isn't a system clipboard copy/paste... it only
> works within the vim session.

That is not supposed to be the case - "*" and "+" copy to the SYSTEM 
clipboard:

   http://vim.wikia.com/wiki/Accessing_the_system_clipboard

Phil.

> i.e. after doing the "+yy key combo, move the insertion cursor
> somewhere else and hit "p".. it will paste the line that you were on
> when you hit the copy shortcut.
> 
> On 07/30/2015 11:23 PM, Philip Rhoades wrote:
>> People,
>> 
>> In Vim, these commands are supposed to copy text to the system 
>> clipboard - but the text does not show up in Clipman:
>> 
>>   "+yy
>> 
>>   "*yy
>> 
>> - why doesn't this work?
>> 
>> In fact, rather than copying the current line as above, I want to copy 
(Continue reading)

Philip Rhoades | 31 Jul 08:56 2015
Picon

Vim commands for copying to system clipboard but text does not show system clipboard

People,

In Vim, these commands are supposed to copy text to the system clipboard 
- but the text does not show up in Clipman:

   "+yy

   "*yy

- why doesn't this work?

I thought maybe it was a problem with xfce4-clipman-plugin so I 
uninstalled it but I still can only paste into a browser if I use the 
mouse to mark a block of text . .

In fact, rather than copying the current line as above, I want to copy 
the text of a whole file which is not conveniently done by clicking and 
dragging the mouse . . but I can't even get it to work on one line . .

Thanks,

Phil.
--

-- 
Philip Rhoades

PO Box 896
Cowra  NSW  2794
Australia
E-mail:  phil <at> pricom.com.au

(Continue reading)

Ratan | 31 Jul 00:03 2015
Picon

Python load error

Here's the exact error I'm getting:

E887: Sorry, this command is disabled, the Python's site module could not be loaded.

Any ideas what might be causing this?

Thanks!

-- 
--

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe <at> googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
BPJ | 30 Jul 14:30 2015
Picon

Is there a repository of spell files for different languages?

Is there a repository of spell files for different languages?

Googling i found a link to 
<ftp://ftp.vim.org/pub/vim/runtime/spell/≥ but it seems to be dead.

Even though it turned out to be a piece of cake to build .spl 
files once you have gotten hold of an appropriate 
OpenOffice/LibreOffice 'dictionary' file maybe it would be a good 
idea to create a public repository somewhere.  I'm thinking GitHub 
because then people can contribute files they created themselves 
by doing a pull request.  I'd be willing to build .spl files from 
existing OO/LO 'dictionaries' and maintain the repository if the 
OO/LO licenses permit it and there is an interest.

/bpj

-- 
--

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe <at> googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Erik Christiansen | 30 Jul 12:30 2015
Picon

Flexible auto-insertion of date at end of file.

What I have so far is:

"Autoinsert date at end of file, _after_ reading modelines:

au BufWinEnter   ~/Data/rainfall/*/*  call Append_Date()

function! Append_Date()
   normal G
   :r !date '+\%d.\%m:    '   
   normal A
endfunction

Problem:
The "normal A" moves the cursor to the end of the inserted date, but
does not enter insert mode. (Stays in normal)
Appending a ^V^M to the second line doesn't help.
How should I hold my mouth for the "normal A" to take effect?

Desired Enhancement:
This is ambitious, but if I could make the date format a function
argument, then the one function could serve a multitude of autocommands,
each with an application-specific date format. But *function-argument*
in the help does not overflow with allowable syntax description. This
simple attempt:

au BufWinEnter   ~/Personal/rainfall/*/*  call Append_Date("'+\%d.\%m:    '")

function! Append_Date()
   normal G
   :r !date a:1
(Continue reading)

BPJ | 28 Jul 18:02 2015
Picon

match() to get the offsets of all matches of a pattern in a string

I have a string of rows of dashes alternating with spaces,
where the number of dashes/spaces is variable

     -----   ------- ---  ----

I want to get a List of the offsets of all the space sequences,
kind of a match() with /g (that's the best I can do to describe
it...) In the case above (ignoring the indent, I would get
[6, 16, 20].

It's the usual problem: I don't know the right :help keyword

/bpj

-- 
--

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe <at> googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Rudra Banerjee | 27 Jul 13:11 2015
Picon

Custom command completion

Hi,

I am trying to write a plugin, where the `b:Sdir` will take the directories with source code. I am trying to
achieve autocompletion as:

"MakeMake: Generate Makefile.gen
function! MakeMake()
  let b:Rdir = input("Project root folder: ", ".", 'file')
  exe ":lchdir ".b:Rdir

" More than 1 files can be choosed
  let b:Sdir = input("Choose source dir: ", ".", "customlist,CFile")
endfunction

function! CFile(A,L,P)
  return split(globpath(b:Rdir, a:A),"\n")
endfunction

But this is not working.
As normal, if I use  "split(globpath(b:Rdir, "*"),"\n")" in CFile, it will show ALL files in the directory
available, but not filter the files.

How can I achieve completion for this?

-- 
--

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

(Continue reading)

Melvin Simon | 27 Jul 13:05 2015
Picon

gvim search and replace

Hi,

I am new to gvim editor. Needed a small help regarding gvim search and replace.

I needed to search and replace as:-

AIO_P71_TSD0_CTRL with AIO_PRI_TSD0_CTRL
AIO_P71_TSD1_CTRL with AIO_PRI_TSD1_CTRL
AIO_P71_TSD2_CTRL with AIO_PRI_TSD2_CTRL

I tried the below:-

>s/AIO_P71_TSD\.*_CTRL/AIO_PRI_TSD\0_PRI_CTRL/g

i.e. I was guessing \0 would print the characters (here 0,1,2) matched by .* however looks like its matching
the entire word. Can some one tell me how to accomplish the above search and replace.

Thanks in advance 
Melvin

-- 
--

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe <at> googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
(Continue reading)

Gary Johnson | 27 Jul 07:59 2015

Buffer name resolution and simplification

When I open a file in the current working directory by specifying
just the relative file name, that short, relative file name appears
in the status line and in the buffer list.  When I open another file
in the same directory by specifying the full path name, that full
path name is used in the status line and in the buffer list.  Here
is an example using the Vim source directory.

    $ cd vim/src
    $ vim
    :e os_beos.c
    :e /usr/local/src/vim-7.4/vim/src/os_unix.c
    :ls
      1 #    "os_beos.c"                    line 1
      2 %a   "/usr/local/src/vim-7.4/vim/src/os_unix.c" line 1

If I then change the working directory, Vim resolves/simplifies both
file names to relative path names.

    :cd ..
    :ls
      1 #    "src/os_beos.c"                line 1
      2 %a   "src/os_unix.c"                line 1

Is there a way to force Vim to always display the file name as a
relative path name, if it can?

The reason I ask is that I open files by a variety of methods so
that the buffer list and the quickfix list wind up with a mixture of
relative and absolute path names.  It would make it easier for me to
recognize files that are in the same directory if all the names in
(Continue reading)

surge | 26 Jul 18:35 2015
Picon

toggle PASTE in insert mode

Hi everybody,

I'm trying to create a mapping in the insert mode that would toggle the PASTE option.

The mapping is defined like this:

inoremap - <ESC>:set map!<CR>i

The thing is, it works the first time and after that, when i type '-', a literal '-' is put in. According to
:verbose onramp -, the mapping doesn't change.

Any ideas?

Thanks!!

-- 
--

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe <at> googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
David Fishburn | 24 Jul 21:34 2015
Picon

helptag escaping

I have the following in one of my documentation files for my plugin:

        autocmd BufRead */MyProjectDir/* DBSetOption variable=blah

But when I run :helptags on that directory I get:
E154: Duplicate tag "/MyProjectDir/" in file c:\vim\vimfiles\doc/dbext.txt


Any idea how to escape something so that:
1.  The example is valid, should a user cut and paste
2.  helptags is happy

Thanks,
David


--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe <at> googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Gmane