mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-17 02:22:17 +00:00
FIX: use StaticBox for background
Change-Id: I2bba259c53eaf987662a97dd93eac4fb8f73d47b
This commit is contained in:
@@ -31,6 +31,7 @@ TabCtrl::TabCtrl(wxWindow * parent,
|
||||
#else
|
||||
radius = 1;
|
||||
#endif
|
||||
border_width = 1;
|
||||
SetBorderColor(0xcecece);
|
||||
sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
sizer->AddSpacer(10);
|
||||
@@ -251,9 +252,6 @@ void TabCtrl::doRender(wxDC& dc)
|
||||
{
|
||||
wxSize size = GetSize();
|
||||
int states = state_handler.states();
|
||||
dc.SetPen(wxPen(border_color.colorForStates(states), border_width));
|
||||
dc.SetBrush(*wxTRANSPARENT_BRUSH);
|
||||
|
||||
if (sel < 0) { return; }
|
||||
|
||||
auto x1 = btns[sel]->GetPosition().x;
|
||||
@@ -262,6 +260,8 @@ void TabCtrl::doRender(wxDC& dc)
|
||||
const int BS2 = (1 + border_width) / 2;
|
||||
#if 0
|
||||
x1 -= TAB_BUTTON_SPACE; x2 += TAB_BUTTON_SPACE;
|
||||
dc.SetPen(wxPen(border_color.colorForStates(states), border_width));
|
||||
dc.SetBrush(*wxTRANSPARENT_BRUSH);
|
||||
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);
|
||||
@@ -272,6 +272,7 @@ void TabCtrl::doRender(wxDC& dc)
|
||||
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.SetPen(wxPen(border_color.colorForStates(states), border_width));
|
||||
dc.DrawLine(0, size.y - BS2, size.x, size.y - BS2);
|
||||
wxColor c(0x42AE00);
|
||||
dc.SetPen(wxPen(c, 0));
|
||||
|
||||
Reference in New Issue
Block a user