Slight improvement of Fl_WinAPI_Window_Driver::border_width_title_bar_height()

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12287 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Manolo Gouy
2017-07-04 17:15:23 +00:00
parent 99615372a6
commit 976959c98e
@@ -102,10 +102,12 @@ RECT // frame of the decorated window in screen coordinates
if (need_r) {
GetWindowRect(fl_xid(win), &r);
}
bx = (r.right - r.left - int(win->w() * scaling))/2;
RECT rc;
GetClientRect(fl_xid(win), &rc);
bx = (r.right - r.left - rc.right)/2;
if (bx < 1) bx = 1;
by = bx;
bt = r.bottom - r.top - int(win->h() * scaling) - 2 * by;
bt = r.bottom - r.top - rc.bottom - 2 * by;
}
return r;
}