Fixed flashing
+ Adde experiments with FromDIP function
This commit is contained in:
parent
1b5c118fd0
commit
7cc3a95f53
5 changed files with 5 additions and 5 deletions
|
@ -12,7 +12,7 @@ namespace GUI {
|
||||||
|
|
||||||
|
|
||||||
Bed_2D::Bed_2D(wxWindow* parent) :
|
Bed_2D::Bed_2D(wxWindow* parent) :
|
||||||
wxPanel(parent, wxID_ANY, wxDefaultPosition, wxSize(20 * wxGetApp().em_unit(), -1), wxTAB_TRAVERSAL)
|
wxPanel(parent, wxID_ANY, wxDefaultPosition, FromDIP(wxSize(250,-1))/*wxSize(20 * wxGetApp().em_unit(), -1)*/, wxTAB_TRAVERSAL)
|
||||||
{
|
{
|
||||||
SetBackgroundStyle(wxBG_STYLE_PAINT); // to avoid assert message after wxAutoBufferedPaintDC
|
SetBackgroundStyle(wxBG_STYLE_PAINT); // to avoid assert message after wxAutoBufferedPaintDC
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
|
|
|
@ -41,7 +41,7 @@ AboutDialog::AboutDialog()
|
||||||
|
|
||||||
// logo
|
// logo
|
||||||
wxBitmap logo_bmp = wxBitmap(from_u8(Slic3r::var("Slic3r_192px.png")), wxBITMAP_TYPE_PNG);
|
wxBitmap logo_bmp = wxBitmap(from_u8(Slic3r::var("Slic3r_192px.png")), wxBITMAP_TYPE_PNG);
|
||||||
auto *logo = new wxStaticBitmap(this, wxID_ANY, std::move(logo_bmp));
|
auto *logo = new wxStaticBitmap(this, wxID_ANY, std::move(logo_bmp), wxDefaultPosition, FromDIP(logo_bmp.GetSize()));
|
||||||
hsizer->Add(logo, 1, wxEXPAND | wxTOP | wxBOTTOM, 35);
|
hsizer->Add(logo, 1, wxEXPAND | wxTOP | wxBOTTOM, 35);
|
||||||
|
|
||||||
wxBoxSizer* vsizer = new wxBoxSizer(wxVERTICAL);
|
wxBoxSizer* vsizer = new wxBoxSizer(wxVERTICAL);
|
||||||
|
|
|
@ -44,7 +44,7 @@ void BedShapePanel::build_panel(ConfigOptionPoints* default_pt)
|
||||||
auto sbsizer = new wxStaticBoxSizer(box, wxVERTICAL);
|
auto sbsizer = new wxStaticBoxSizer(box, wxVERTICAL);
|
||||||
|
|
||||||
// shape options
|
// shape options
|
||||||
m_shape_options_book = new wxChoicebook(this, wxID_ANY, wxDefaultPosition, wxSize(23 * wxGetApp().em_unit(), -1), wxCHB_TOP);
|
m_shape_options_book = new wxChoicebook(this, wxID_ANY, wxDefaultPosition, FromDIP(wxSize(300, -1))/*wxSize(23 * wxGetApp().em_unit(), -1)*/, wxCHB_TOP);
|
||||||
sbsizer->Add(m_shape_options_book);
|
sbsizer->Add(m_shape_options_book);
|
||||||
|
|
||||||
auto optgroup = init_shape_options_page(_(L("Rectangular")));
|
auto optgroup = init_shape_options_page(_(L("Rectangular")));
|
||||||
|
|
|
@ -159,7 +159,7 @@ bool GUI_App::OnInit()
|
||||||
|
|
||||||
// ! Temporary workaround for the correct behavior of the Scrolled sidebar panel
|
// ! Temporary workaround for the correct behavior of the Scrolled sidebar panel
|
||||||
// Do this "manipulations" only once ( after (re)create of the application )
|
// Do this "manipulations" only once ( after (re)create of the application )
|
||||||
if (plater_ && sidebar().obj_list()->GetMinHeight() > 200)
|
if (plater_ && sidebar().obj_list()->GetMinHeight() > 15 * wxGetApp().em_unit())
|
||||||
{
|
{
|
||||||
wxWindowUpdateLocker noUpdates_sidebar(&sidebar());
|
wxWindowUpdateLocker noUpdates_sidebar(&sidebar());
|
||||||
sidebar().obj_list()->SetMinSize(wxSize(-1, 15 * wxGetApp().em_unit()));
|
sidebar().obj_list()->SetMinSize(wxSize(-1, 15 * wxGetApp().em_unit()));
|
||||||
|
|
|
@ -50,7 +50,7 @@ SysInfoDialog::SysInfoDialog()
|
||||||
|
|
||||||
// logo
|
// logo
|
||||||
wxBitmap logo_bmp = wxBitmap(from_u8(Slic3r::var("Slic3r_192px.png")), wxBITMAP_TYPE_PNG);
|
wxBitmap logo_bmp = wxBitmap(from_u8(Slic3r::var("Slic3r_192px.png")), wxBITMAP_TYPE_PNG);
|
||||||
auto *logo = new wxStaticBitmap(this, wxID_ANY, std::move(logo_bmp));
|
auto *logo = new wxStaticBitmap(this, wxID_ANY, std::move(logo_bmp), wxDefaultPosition, FromDIP(logo_bmp.GetSize()));
|
||||||
hsizer->Add(logo, 0, wxEXPAND | wxTOP | wxBOTTOM, 15);
|
hsizer->Add(logo, 0, wxEXPAND | wxTOP | wxBOTTOM, 15);
|
||||||
|
|
||||||
wxBoxSizer* vsizer = new wxBoxSizer(wxVERTICAL);
|
wxBoxSizer* vsizer = new wxBoxSizer(wxVERTICAL);
|
||||||
|
|
Loading…
Reference in a new issue