From bce6dd3d6097fd2577a127a33f7b978e7e7c7c5a Mon Sep 17 00:00:00 2001 From: Bjorn Winckler Date: Wed, 1 Aug 2007 06:48:05 +0000 Subject: [PATCH] Notifying MacVim when SetTextDimensionsMsgID received. git-svn-id: http://macvim.googlecode.com/svn/trunk@44 96c4425d-ca35-0410-94e5-3396d5c13a8f --- MMBackend.m | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/MMBackend.m b/MMBackend.m index 3a938bf0e4..18b61e6b46 100644 --- a/MMBackend.m +++ b/MMBackend.m @@ -986,6 +986,12 @@ static int eventButtonNumberToVimMouseButton(int buttonNumber); int rows = *((int*)bytes); bytes += sizeof(int); int cols = *((int*)bytes); bytes += sizeof(int); + // NOTE! Vim doesn't call gui_mch_set_shellsize() after + // gui_resize_shell(), so we have to manually set the rows and columns + // here. (MacVim doesn't change the rows and columns to avoid + // inconsistent states between Vim and MacVim.) + [self setRows:rows columns:cols]; + //NSLog(@"[VimTask] Resizing shell to %dx%d.", cols, rows); gui_resize_shell(cols, rows); } else if (ExecuteMenuMsgID == msgid) {