From a6f8b8056297f25585ae492130e5b0801e687316 Mon Sep 17 00:00:00 2001 From: David Halter Date: Fri, 14 Sep 2012 00:44:16 +0200 Subject: [PATCH] vim: goto jumps now appear at the top of the screen --- jedi.vim | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/jedi.vim b/jedi.vim index 3ae887a..caeda27 100644 --- a/jedi.vim +++ b/jedi.vim @@ -352,8 +352,8 @@ import vim # update the system path, to include the python scripts import sys import os -from os.path import dirname -sys.path.insert(0, dirname(dirname(vim.eval('s:current_file')))) +from os.path import dirname, abspath +sys.path.insert(0, dirname(dirname(abspath(vim.eval('s:current_file'))))) import traceback # for exception output import re @@ -415,6 +415,7 @@ def _goto(is_definition=False, is_related_name=False, no_output=False): else: vim.command('edit ' + d.module_path) vim.current.window.cursor = d.line_nr, d.column + vim.command('normal! zt') # cursor at top of screen else: # multiple solutions lst = []