Thanks for your replies.

I like the first solution, but it doesn't return to the original tab, which
was what I found most difficult.
Ian's solution works :-)

I didn't know about the function tabpagenr(), my solution was:

:function OpenFile()
:   let tab_id = expand("%") 
:   tab split
:   tabmove
:   cs find f <cfile>   " locate the file using cscope plugin ( 'normal gf'
is fine also)
:   while tab_id != expand("%")
:       tabprev
:   endw
:   normal j
:endfunction

Kind regards,
Francis
-- 
View this message in context: 
http://www.nabble.com/A-challenge-for-those-who-feel-like-it-tf3657250.html#a10281573
Sent from the Vim - General mailing list archive at Nabble.com.

Reply via email to