diff --git a/resources/calibration/bed_leveling/bed_leveling.html b/resources/calibration/bed_leveling/bed_leveling.html index 54e78703af1..786e47b3bdd 100644 --- a/resources/calibration/bed_leveling/bed_leveling.html +++ b/resources/calibration/bed_leveling/bed_leveling.html @@ -8,7 +8,7 @@ - @@ -22,7 +22,7 @@

How it works

When clicking on the Generate button, the program will create and slice the test print. You have to send it to your printer and print it. After the print end, check the result of each corners and the middle one against the photos below. You will have to tune your printer/firmware to correct the height if needed.

Read the notes and advices below for more information.

Results

-
+

Bed Level Calibration

need: nothing
+
diff --git a/resources/calibration/bridge_flow/bridge_flow.html b/resources/calibration/bridge_flow/bridge_flow.html index 54079f13aba..735bd07fbb0 100644 --- a/resources/calibration/bridge_flow/bridge_flow.html +++ b/resources/calibration/bridge_flow/bridge_flow.html @@ -9,7 +9,7 @@
-
+

Bridge Flow Ratio Calibration

diff --git a/resources/calibration/cube/cube.html b/resources/calibration/cube/cube.html index 0c06236d938..344db22eb8f 100644 --- a/resources/calibration/cube/cube.html +++ b/resources/calibration/cube/cube.html @@ -9,7 +9,7 @@ -
+

Calibration Cube

diff --git a/resources/calibration/filament_flow/filament_flow.html b/resources/calibration/filament_flow/filament_flow.html index de0828b82f2..ae18bb1c502 100644 --- a/resources/calibration/filament_flow/filament_flow.html +++ b/resources/calibration/filament_flow/filament_flow.html @@ -9,7 +9,7 @@ -
+

Filament Flow Calibration

@@ -25,7 +25,7 @@

Filament Flow Calibration

After verifying the result with the help of the table below, you have to modify the filament extrusion multiplier in your filament preset (if the -20 is the best, change the multiplier from 1 to 0.8, see the formula below). Don't forget to save it afterwards! You can continue with the 2.5 step if you want a bit more precision.

Results

Example:

- +
diff --git a/resources/calibration/filament_temp/filament_temp.html b/resources/calibration/filament_temp/filament_temp.html index 2e925fd80f4..9a71ac55b97 100644 --- a/resources/calibration/filament_temp/filament_temp.html +++ b/resources/calibration/filament_temp/filament_temp.html @@ -9,7 +9,7 @@
-
+

Filament Temperature Calibration

@@ -27,7 +27,7 @@

Filament Temperature Calibration

Results / observation

The goal is to choose the highest temperature possible that doesn't produce artifacts.

First, you have to analyse the tower. Each floor has the according temperature written on it.

- +
diff --git a/resources/calibration/introduction.html b/resources/calibration/introduction.html index 8466dd6da5e..adb865c86f3 100644 --- a/resources/calibration/introduction.html +++ b/resources/calibration/introduction.html @@ -5,7 +5,7 @@ Calibrations -

Introduction

+

Introduction

Welcome to the calibration menu. This menu is here to help you print quick & efficient calibrations.

Why?

Most printer’s profile should work pretty good with default settings, but if you encounter problems, or if you want to go a step above in quality, you have to ensure that everything is well calibrated. Calibrations can be divided in three groups: printer, filament and slicer.

diff --git a/resources/calibration/over-bridge_tuning/over-bridge_tuning.html b/resources/calibration/over-bridge_tuning/over-bridge_tuning.html index 2ec92aeb2a5..dfe59cb6c5a 100644 --- a/resources/calibration/over-bridge_tuning/over-bridge_tuning.html +++ b/resources/calibration/over-bridge_tuning/over-bridge_tuning.html @@ -9,7 +9,7 @@
-
+

Ironing Pattern Calibration

@@ -23,7 +23,7 @@

Ironing Pattern Calibration

You need to do the filament flow calibration and the bridge flow ratio before this one. It's better if you have done the filament temperature.

This calibration method will print test samples with various levels of over-bridge flow ratio, between 100 and 125. Choose the lowest value on which the top surface is smooth without rough "holes".

Results

- +

Exemple:

diff --git a/src/slic3r/GUI/CalibrationAbstractDialog.cpp b/src/slic3r/GUI/CalibrationAbstractDialog.cpp index 4a8478320c7..004ceee0ce0 100644 --- a/src/slic3r/GUI/CalibrationAbstractDialog.cpp +++ b/src/slic3r/GUI/CalibrationAbstractDialog.cpp @@ -25,7 +25,7 @@ namespace GUI { #if ENABLE_SCROLLABLE wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER) #else - wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE) + wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER) #endif // ENABLE_SCROLLABLE { this->gui_app = app; @@ -45,10 +45,15 @@ void CalibrationAbstractDialog::create(std::string html_path, wxSize dialog_size //html html_viewer = new wxHtmlWindow(this, wxID_ANY, - wxDefaultPosition, dialog_size, wxHW_SCROLLBAR_AUTO); + wxDefaultPosition, wxDefaultSize, wxHW_SCROLLBAR_AUTO); html_viewer->LoadPage(Slic3r::resources_dir()+ html_path); main_sizer->Add(html_viewer, 1, wxEXPAND | wxALL, 5); + wxDisplay display(wxDisplay::GetFromWindow(main_frame)); + wxRect screen = display.GetClientArea(); + dialog_size.x = std::min(int(dialog_size.x * this->scale_factor()), screen.width - 50); + dialog_size.y = std::min(int(dialog_size.y * this->scale_factor()), screen.height - 50); + wxStdDialogButtonSizer* buttons = new wxStdDialogButtonSizer(); create_buttons(buttons); @@ -63,6 +68,7 @@ void CalibrationAbstractDialog::create(std::string html_path, wxSize dialog_size SetSizer(main_sizer); main_sizer->SetSizeHints(this); + this->SetSize(dialog_size.x, dialog_size.y); } void CalibrationAbstractDialog::close_me(wxCommandEvent& event_args) { @@ -120,8 +126,9 @@ void CalibrationAbstractDialog::on_dpi_changed(const wxRect& suggested_rect) { msw_buttons_rescale(this, em_unit(), { wxID_OK }); + wxSize oldSize = this->GetSize(); Layout(); - Fit(); + this->SetSize(oldSize.x * this->scale_factor() / this->prev_scale_factor(), oldSize.y * this->scale_factor() / this->prev_scale_factor()); Refresh(); } diff --git a/src/slic3r/GUI/CalibrationAbstractDialog.hpp b/src/slic3r/GUI/CalibrationAbstractDialog.hpp index ff23a18f060..f5320444ed5 100644 --- a/src/slic3r/GUI/CalibrationAbstractDialog.hpp +++ b/src/slic3r/GUI/CalibrationAbstractDialog.hpp @@ -24,7 +24,7 @@ class CalibrationAbstractDialog : public DPIDialog private: wxPanel* create_header(wxWindow* parent, const wxFont& bold_font); protected: - void create(std::string html_path, wxSize dialogsize = wxSize(800, 500)); + void create(std::string html_path, wxSize dialogsize = wxSize(850, 550)); virtual void create_buttons(wxStdDialogButtonSizer*) = 0; void on_dpi_changed(const wxRect& suggested_rect) override; void close_me(wxCommandEvent& event_args); diff --git a/src/slic3r/GUI/CalibrationBridgeDialog.hpp b/src/slic3r/GUI/CalibrationBridgeDialog.hpp index 1db136c328f..becc86446d0 100644 --- a/src/slic3r/GUI/CalibrationBridgeDialog.hpp +++ b/src/slic3r/GUI/CalibrationBridgeDialog.hpp @@ -10,7 +10,7 @@ class CalibrationBridgeDialog : public CalibrationAbstractDialog { public: - CalibrationBridgeDialog(GUI_App* app, MainFrame* mainframe) : CalibrationAbstractDialog(app, mainframe, "Bridge calibration") { create("/calibration/bridge_flow/bridge_flow.html", wxSize(600, 300)); } + CalibrationBridgeDialog(GUI_App* app, MainFrame* mainframe) : CalibrationAbstractDialog(app, mainframe, "Bridge calibration") { create("/calibration/bridge_flow/bridge_flow.html", wxSize(850, 400)); } virtual ~CalibrationBridgeDialog() { } protected: diff --git a/src/slic3r/GUI/FreeCADDialog.cpp b/src/slic3r/GUI/FreeCADDialog.cpp index 34f83af0874..7d8d079e869 100644 --- a/src/slic3r/GUI/FreeCADDialog.cpp +++ b/src/slic3r/GUI/FreeCADDialog.cpp @@ -222,21 +222,14 @@ FreeCADDialog::FreeCADDialog(GUI_App* app, MainFrame* mainframe) createSTC(); m_errors = new wxTextCtrl(this, wxID_ANY, "", - wxDefaultPosition, wxSize(600, 100), wxHW_SCROLLBAR_AUTO | wxTE_MULTILINE); + wxDefaultPosition, wxSize(200, 100 * this->scale_factor()), wxHW_SCROLLBAR_AUTO | wxTE_MULTILINE); m_errors->SetEditable(false); m_help = new wxTextCtrl(this, wxID_ANY, create_help_text(), - wxDefaultPosition, wxSize(200, 500), wxTE_MULTILINE); + wxDefaultPosition, wxSize(200 * this->scale_factor(), 200), wxTE_MULTILINE); m_help->SetEditable(false); - //wxBoxSizer *m_icons = new wxBoxSizer(wxHORIZONTAL); - //m_icons->Add(16,16,0,0,0,freecad_icon); - - //wxSizerItem* Add(wxSizer * sizer, const wxGBPosition & pos, const wxGBSpan & span = wxDefaultSpan, int flag = 0, int border = 0, wxObject * userData = NULL) - //wxSizerItem* Add(wxSizer * sizer, int proportion = 0, int flag = 0, int border = 0, wxObject * userData = NULL) main_sizer->Add(m_text, wxGBPosition(1,1), wxGBSpan(2,1), wxEXPAND | wxALL, 2); - //main_sizer->Add(m_icons, wxGBPosition(1, 2), wxGBSpan(1, 1), 0, 2); - //main_sizer->Add(m_help, wxGBPosition(2, 2), wxGBSpan(2, 1), wxEXPAND | wxVERTICAL, 2); main_sizer->Add(m_help, wxGBPosition(1, 2), wxGBSpan(3, 1), wxEXPAND | wxVERTICAL, 2); main_sizer->Add(m_errors, wxGBPosition(3, 1), wxGBSpan(1, 1), wxEXPAND | wxHORIZONTAL, 2); @@ -245,7 +238,7 @@ FreeCADDialog::FreeCADDialog(GUI_App* app, MainFrame* mainframe) wxStdDialogButtonSizer* buttons = new wxStdDialogButtonSizer(); - wxButton* bt_new = new wxButton(this, wxID_FILE3, _(L("New"))); + wxButton* bt_new = new wxButton(this, wxID_FILE1, _(L("New"))); bt_new->Bind(wxEVT_BUTTON, &FreeCADDialog::new_script, this); buttons->Add(bt_new); wxButton* bt_load = new wxButton(this, wxID_FILE2, _(L("Load"))); @@ -260,7 +253,7 @@ FreeCADDialog::FreeCADDialog(GUI_App* app, MainFrame* mainframe) buttons->Add(bt_quick_save); buttons->AddSpacer(30); - wxButton* bt_create_geometry = new wxButton(this, wxID_FILE1, _(L("Generate"))); + wxButton* bt_create_geometry = new wxButton(this, wxID_APPLY, _(L("Generate"))); bt_create_geometry->Bind(wxEVT_BUTTON, &FreeCADDialog::create_geometry, this); buttons->Add(bt_create_geometry); @@ -276,6 +269,14 @@ FreeCADDialog::FreeCADDialog(GUI_App* app, MainFrame* mainframe) SetSizer(main_sizer); main_sizer->SetSizeHints(this); + wxSize dialog_size(800 * this->scale_factor(), 600 * this->scale_factor()); + wxDisplay display(wxDisplay::GetFromWindow(main_frame)); + wxRect screen = display.GetClientArea(); + dialog_size.x = std::min(dialog_size.x, screen.width - 50); + dialog_size.y = std::min(dialog_size.y, screen.height - 50); + + this->SetSize(dialog_size); + //set keyboard shortcut wxAcceleratorEntry entries[6]; //entries[0].Set(wxACCEL_CTRL, (int) 'X', bt_create_geometry->GetId()); @@ -611,7 +612,7 @@ void FreeCADDialog::on_key_type(wxKeyEvent& event) void FreeCADDialog::createSTC() { m_text = new wxStyledTextCtrl(this, wxID_ANY, - wxDefaultPosition, wxSize(600,400), wxHW_SCROLLBAR_AUTO); + wxDefaultPosition, wxDefaultSize, wxHW_SCROLLBAR_AUTO); //m_text->SetMarginWidth(MARGIN_LINE_NUMBERS, 50); m_text->StyleSetForeground(wxSTC_STYLE_LINENUMBER, wxColour(75, 75, 75)); @@ -624,6 +625,7 @@ void FreeCADDialog::createSTC() m_text->SetIndentationGuides(wxSTC_IV_LOOKFORWARD); m_text->SetBackSpaceUnIndents(true); m_text->SetTabIndents(true); + m_text->SetZoom(int((this->scale_factor() - 1) * 10)); m_text->SetWrapMode(wxSTC_WRAP_WORD); @@ -668,10 +670,15 @@ void FreeCADDialog::createSTC() void FreeCADDialog::on_dpi_changed(const wxRect& suggested_rect) { - msw_buttons_rescale(this, em_unit(), { wxID_OK }); + msw_buttons_rescale(this, em_unit(), { wxID_FILE1, wxID_FILE2, wxID_FILE3, wxID_FILE4, wxID_APPLY, wxID_CLOSE }); + + m_errors->SetMinSize(wxSize(200, 100 * this->scale_factor())); + m_help->SetMinSize(wxSize(200 * this->scale_factor(), 200)); + m_text->SetZoom(int((this->scale_factor() - 1) * 10)); + wxSize oldSize = this->GetSize(); Layout(); - Fit(); + this->SetSize(oldSize.x * this->scale_factor() / this->prev_scale_factor(), oldSize.y * this->scale_factor() / this->prev_scale_factor()); Refresh(); }