Friday, February 21, 2014

When starting gvim with command line arguments it needs a keypress before showing the file content, why?

Hello,

When I start gvim from the command line via this command:

gvim "C:\\temp\\mytest.txt" "+set wrapscan" "+set ignorecase" "+44" "-c/RM_NULL"

(so I want to have the cursor on line 44 and search for keyword "RM_NULL")

It shows up with a blank screen and a text in the bottom "Press key to continue", after I press a key it shows me the content, the cursor is at the correct line and the keyword is in the search buffer (all as I expect)

Why is the keypress needed? Can I do something to avoid it and opens up right away?
It is to my opinion because it does a wrap around from bottom to top since the keyword is exactly at line 44 (if I turn on line numbers then it is line 44)

Since if I open it with "+43" I don't need the keypress. So counting it starts at zero for search but when displaying at 1?

Maybe someone can explain why it is like this.. I use this in a IDE to open up a file from a search results window, from there I get the line number and the keyword.

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@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments:

Post a Comment