diff --git a/src/slic3r/GUI/Widgets/TabCtrl.cpp b/src/slic3r/GUI/Widgets/TabCtrl.cpp index 33de03c2b..84c1a4b63 100644 --- a/src/slic3r/GUI/Widgets/TabCtrl.cpp +++ b/src/slic3r/GUI/Widgets/TabCtrl.cpp @@ -26,7 +26,11 @@ TabCtrl::TabCtrl(wxWindow * parent, long style) : StaticBox(parent, id, pos, size, style) { +#if 0 radius = 5; +#else + radius = 1; +#endif SetBorderColor(0xcecece); sizer = new wxBoxSizer(wxHORIZONTAL); sizer->AddSpacer(10); @@ -254,9 +258,10 @@ void TabCtrl::doRender(wxDC& dc) auto x1 = btns[sel]->GetPosition().x; auto x2 = x1 + btns[sel]->GetSize().x; - x1 -= TAB_BUTTON_SPACE; x2 += TAB_BUTTON_SPACE; const int BS = border_width / 2; const int BS2 = (1 + border_width) / 2; +#if 0 + x1 -= TAB_BUTTON_SPACE; x2 += TAB_BUTTON_SPACE; dc.DrawLine(0, size.y - BS2, x1 - radius + BS2, size.y - BS2); dc.DrawArc(x1 - radius, size.y, x1, size.y - radius, x1 - radius, size.y - radius); dc.DrawLine(x1, size.y - radius, x1, radius); @@ -266,6 +271,13 @@ void TabCtrl::doRender(wxDC& dc) dc.DrawLine(x2, radius, x2, size.y - radius); dc.DrawArc(x2, size.y - radius, x2 + radius, size.y, x2 + radius, size.y - radius); dc.DrawLine(x2 + radius - BS2, size.y - BS2, size.x, size.y - BS2); +#else + dc.DrawLine(0, size.y - BS2, size.x, size.y - BS2); + wxColor c(0x42AE00); + dc.SetPen(wxPen(c, 0)); + dc.SetBrush(c); + dc.DrawRoundedRectangle(x1 - radius, size.y - BS2 - border_width * 3, x2 + radius * 2 - x1, border_width * 3, radius); +#endif } bool TabCtrl::sendTabCtrlEvent(bool changing)