1
0
forked from aniani/vim

updated for version 7.4a.038

Problem:    When using MSVC 2012 there are various issues, including GUI size
            computations.
Solution:   Use SM_CXPADDEDBORDER. (Mike Williams)
This commit is contained in:
Bram Moolenaar
2013-07-21 17:53:58 +02:00
parent 5f919ee8eb
commit 9d48895e4c
4 changed files with 25 additions and 10 deletions

View File

@@ -2909,9 +2909,11 @@ gui_mswin_get_valid_dimensions(
int base_width, base_height;
base_width = gui_get_base_width()
+ GetSystemMetrics(SM_CXFRAME) * 2;
+ (GetSystemMetrics(SM_CXFRAME) +
GetSystemMetrics(SM_CXPADDEDBORDER)) * 2;
base_height = gui_get_base_height()
+ GetSystemMetrics(SM_CYFRAME) * 2
+ (GetSystemMetrics(SM_CYFRAME) +
GetSystemMetrics(SM_CXPADDEDBORDER)) * 2
+ GetSystemMetrics(SM_CYCAPTION)
#ifdef FEAT_MENU
+ gui_mswin_get_menu_height(FALSE)
@@ -3274,9 +3276,11 @@ gui_mch_newfont()
GetWindowRect(s_hwnd, &rect);
gui_resize_shell(rect.right - rect.left
- GetSystemMetrics(SM_CXFRAME) * 2,
- (GetSystemMetrics(SM_CXFRAME) +
GetSystemMetrics(SM_CXPADDEDBORDER)) * 2,
rect.bottom - rect.top
- GetSystemMetrics(SM_CYFRAME) * 2
- (GetSystemMetrics(SM_CYFRAME) +
GetSystemMetrics(SM_CXPADDEDBORDER)) * 2
- GetSystemMetrics(SM_CYCAPTION)
#ifdef FEAT_MENU
- gui_mswin_get_menu_height(FALSE)