rem: rect.pos.y = 2;
context: paintTabView(TabView *tPtr){    Pixmap buffer;    WMScreen *scr = W_VIEW(tPtr)->screen;    Display *dpy = scr->display;    GC white = WMColorGC(scr->white);    int i;    WMRect rect;    if (tPtr->flags.type == WTTopTabsBevelBorder) {	int count = tPtr->visibleTabs;	int first = tPtr->firstVisible;	int offs;	int moreAtLeft;	int moreAtRight;	int selectedIsVisible;		buffer = XCreatePixmap(dpy, W_VIEW(tPtr)->window,			       W_VIEW(tPtr)->size.width, tPtr->tabHeight,			       W_VIEW(tPtr)->screen->depth);	XFillRectangle(dpy, buffer, WMColorGC(W_VIEW(tPtr)->backColor),		       0, 0, W_VIEW(tPtr)->size.width, tPtr->tabHeight);	rect.pos.y = 2;	if (tPtr->flags.dontFitAll) {	    rect.pos.x = 15 + BUTTONED_SIDE_OFFSET;	    offs = BUTTONED_SIDE_OFFSET;	    moreAtLeft = first > 0;	    moreAtRight = (first + count) < tPtr->itemCount;	    if (tPtr->selectedItem >= first		&& tPtr->selectedItem < first + count)		selectedIsVisible = 1;	    else		selectedIsVisible = 0;	} else {	    rect.pos.x = 15 + NORMAL_SIDE_OFFSET;	    offs = NORMAL_SIDE_OFFSET;	    moreAtLeft = 0;	    moreAtRight = 0;	    selectedIsVisible = 1;	}	rect.size.width = tPtr->tabWidth;	rect.size.height = tPtr->tabHeight;	for (i = count - (moreAtRight ? 0 : 1);	     i >= (moreAtLeft ? -1 : 0); i--) {	    if (!selectedIsVisible || i != (tPtr->selectedItem-first)) {		drawTab(tPtr, buffer, offs + (rect.size.width-10)*i, 0,			rect.size.width, rect.size.height, False);	    }	}		if (selectedIsVisible) {	    drawTab(tPtr, buffer, 		    offs + (rect.size.width-10) * (tPtr->selectedItem - first),		    0, rect.size.width, rect.size.height, True);	    XDrawLine(dpy, buffer, white, 0, tPtr->tabHeight - 1,		      offs, tPtr->tabHeight - 1);	    XDrawLine(dpy, buffer, white, 		      offs + 10 + (rect.size.width-10) * count,		      tPtr->tabHeight - 1, W_VIEW(tPtr)->size.width - 1,		      tPtr->tabHeight - 1);	} else {	    XDrawLine(dpy, buffer, white, 0, tPtr->tabHeight - 1,		      W_VIEW(tPtr)->size.width, tPtr->tabHeight - 1);	    	}	for (i = 0; i < count; i++) {	    W_DrawLabel(tPtr->items[first+i], buffer, rect);	    rect.pos.x += rect.size.width - 10;	}	if (moreAtLeft) {	    paintDot(tPtr, buffer, 4, 10);	    paintDot(tPtr, buffer, 7, 10);	    paintDot(tPtr, buffer, 10, 10);	}	if (moreAtRight) {	    int x;	    	    x = BUTTONED_SIDE_OFFSET - 5 + tPtr->visibleTabs * (tPtr->tabWidth - 10);	    	    x = x + (W_VIEW(tPtr)->size.width - x)/2;	    	    paintDot(tPtr, buffer, x + 5, 10);	    paintDot(tPtr, buffer, x + 8, 10);	    paintDot(tPtr, buffer, x + 11, 10);	    	}	XCopyArea(dpy, buffer, W_VIEW(tPtr)->window, scr->copyGC, 0, 0,		  W_VIEW(tPtr)->size.width, tPtr->tabHeight, 0, 0);	XFreePixmap(dpy, buffer);    }    switch (tPtr->flags.type) {     case WTTopTabsBevelBorder:	drawRelief(scr, W_VIEW(tPtr)->window, 0, tPtr->tabHeight - 1,		   W_VIEW(tPtr)->size.width,		   W_VIEW(tPtr)->size.height - tPtr->tabHeight + 1);	break;     case WTNoTabsBevelBorder:	W_DrawRelief(scr, W_VIEW(tPtr)->window, 0, 0, W_VIEW(tPtr)->size.width,		     W_VIEW(tPtr)->size.height, WRRaised);	break;     case WTNoTabsLineBorder:	W_DrawRelief(scr, W_VIEW(tPtr)->window, 0, 0, W_VIEW(tPtr)->size.width,		     W_VIEW(tPtr)->size.height, WRSimple);	break;     case WTNoTabsNoBorder:	break;    }}