Various visual fixes for the tab control. ChangeLog: - Reduced tab offset constant slightly to avoid clipping the label - Prevent label overdraw of updown control by reducing the width of the invalidated region. Oh, btw my licensing "stance" is LGPL only, unless you ask me directly. ... and that ends tonights hacking session thanks -mike
Index: dlls/comctl32/tab.c =================================================================== RCS file: /home/wine/wine/dlls/comctl32/tab.c,v retrieving revision 1.75 diff -u -r1.75 tab.c --- dlls/comctl32/tab.c 4 Mar 2003 04:34:03 -0000 1.75 +++ dlls/comctl32/tab.c 9 Mar 2003 00:56:20 -0000 @@ -79,7 +79,7 @@ /****************************************************************************** * Positioning constants */ -#define SELECTED_TAB_OFFSET 2 +#define SELECTED_TAB_OFFSET 1 #define HORIZONTAL_ITEM_PADDING 6 #define VERTICAL_ITEM_PADDING 3 #define ROUND_CORNER_SIZE 2 @@ -2313,7 +2313,7 @@ HWND hwnd, TAB_INFO* infoPtr) { - RECT clientRect; + RECT clientRect, r; DWORD lStyle = GetWindowLongA(hwnd, GWL_STYLE); INT lastRow = infoPtr->uNumRows - 1; @@ -2347,10 +2347,17 @@ lastRow * (infoPtr->tabHeight - 2) + ((lStyle & TCS_BUTTONS) ? lastRow * BUTTON_SPACINGY : 0) + 2; } - + + /* Punch out the updown control */ + if (infoPtr->needsScrolling && (clientRect.right > 0)) { + GetClientRect(infoPtr->hwndUpDown, &r); + clientRect.right = clientRect.right - (r.right - r.left); + } + TRACE("invalidate (%ld,%ld)-(%ld,%ld)\n", clientRect.left,clientRect.top, clientRect.right,clientRect.bottom); + InvalidateRect(hwnd, &clientRect, TRUE); }