Commit Graph

50 Commits

Author SHA1 Message Date
bubnikv
8d7f88b381 Imported error reporting when loading presets with option keys
or option values that our poor software does not understand.
This applies to configs added by some forks of slic3r, for example
slic3r++
PrusaSlicer has encountered an error: Failed loading the preset file: #3909
2020-03-25 16:04:11 +01:00
Lukas Matena
eb3b65d8af Fixing build against wxWidgets 3.0
The wxString saga continues. wxWidgets 3.0 don't have the wxString::FromUTF8(const std::string&) overload, we must use the GUI::from_u8 helper
Also wxWidgets 3.0 don't allow to disable wxString->const char* conversion, so calling show_info(wxWindow*, wxString, const char*) was ambiguous
Several includes moved around
2020-03-04 10:34:59 +01:00
bubnikv
25d6818fc7 Fix of
Opening saved project removes Print Host settings #3655
Octoprint Settings when Opening a .3MF file #3244

When loading a configuration file (from AMF, 3MF, .ini or .gcode),
and if the host settings ("print_host", "printhost_apikey", "printhost_cafile")
in the configuration file is empty, then the config is considered to be anonymized,
and these anonymized keys are loaded from the referenced "derived from" profile,
if it exists in user's PrusaSlicer configuration directory.

We are aware that this is a patch work and a better long term solution
is to separate physical printer settings from logical printer settings,
but this is a good enough solution for PrusaSlicer 2.2.0 release.
2020-02-18 14:13:56 +01:00
bubnikv
059bdb4711 Implemented handling of complex ConfigOptionFloatOrPercent chains
by the PlaceholderParser.

Namely, all the options with the "ratio_over" reference are now handled
correctly by the PlaceholderParser with the exception
of the "first_layer_extrusion_width", which overrides speed of extrusions
by their respective extrusion type.

Also the various extrusion widths (extrusion_width, first_layer_extrusion_width,
external_perimeter_extrusion_width etc.) produce the same numbers
as if ran through the back-end, with the assumption of not overriding
layer height by the variable layer height editing tool or layer height
modifiers.
2020-02-04 15:27:38 +01:00
bubnikv
79d7a0130f Fixing some missing throw statements.
Adding noexcept to move constructors / operators.
2020-01-13 17:41:40 +01:00
bubnikv
81187e7e0e Some refactoring and const correctness fixes. 2020-01-07 14:35:43 +01:00
bubnikv
9406b50447 Const correctness improvements:
removed some unnecessary const_casts that remove const.
2020-01-03 16:33:04 +01:00
bubnikv
13cc74ef0a Ported test_config.cpp from upstream Slic3r.
Extended ConfigBase with set() functions similar to the upstream Slic3r.
ConfigBase::set_deserialize() newly throws if the operation fails.
Extrusion width parameters are newly tested for negative values.
2019-10-18 11:53:19 +02:00
bubnikv
98a71a557b Ported test_support_material.cpp from upstream slic3r.
Ported extension of ExtrusionEntityCollection::flatten() to disable
flattening of no_sort() collections.
2019-10-17 19:09:24 +02:00
bubnikv
c228a49fe0 Ported test_support_material from upstream Slic3r.
Reworked the FFF testing framework & ConfigBase::set_deserialize()
for more compact tests: set_deserialize() now accepts list
of key / value pairs.

Fixed an incorrect assert in LayerRegion.
2019-10-17 17:09:15 +02:00
bubnikv
69c8b1cd21 new cheaper constructor for DynamicPrintConfig from FullPrintConfig:
DynamicPrintConfig::full_print_config()
new cheaper constructors of DynamicConfig / DynamicPrintConfig from ConfigBase
Unit tests: ported test_model from upstream Slic3r, thanks @lordofhyphens
Unit tests refactored to use less autos and initializer lists for readibility,
DynamicPrintConfig is handled by value, not by shared pointer.
2019-10-16 11:16:50 +02:00
tamasmeszaros
f29e18dad2 Fix crashing test executable on gcc 4.9 2019-10-02 14:42:28 +02:00
Lukas Matena
7861fa5086 Whitespace changes to supress misleading indentation warnings
These appear in newer gcc when spaces and tabs are mixed
2019-09-24 16:01:01 +02:00
Lukas Matena
3f988b314c Fixed several warnings (Config.hpp and few other files) 2019-09-06 15:55:07 +02:00
YuSanka
2d1c554758 Some reverts for commit 4cd4d2c8b5 2019-08-14 17:07:30 +02:00
YuSanka
4cd4d2c8b5 Fixed wrong page selection for Printer Setting after application run 2019-08-13 17:09:42 +02:00
Lukas Matena
6da196b419 Corrected return value of ConfigOptionVector::apply_override to what was intended (this didn't cause any bug though, the return value is currently not used) 2019-08-05 15:24:49 +02:00
YuSanka
d0d01ef7ab Merge remote-tracking branch 'origin/vb_filament_overrides' into ys_overrides 2019-07-28 22:01:48 +02:00
YuSanka
40a576a8ad Implemented update of the override filaments options from/to config 2019-07-28 22:00:39 +02:00
bubnikv
17edc289e9 Fixed missing return value. 2019-07-25 17:18:51 +02:00
bubnikv
f8218eb903 Reworked the FFF Print::update() to process the filament retract
override values and to store them into the output G-code.
2019-07-25 14:39:19 +02:00
bubnikv
42c8940795 Fixed is_nil() method on ConfigOptions.
PlaceholderParser was extended to support external config.
The external config has a lowest priority when looking up a variable.
2019-07-24 12:39:01 +02:00
bubnikv
6ea3a8e2b4 WIP: Nullable config values. Fixed compare operator for float vectors. 2019-07-23 17:15:34 +02:00
bubnikv
3b1a44c084 WIP: Nullable configuration value concept, implemented for
ConfigOptionFloatsNullable, ConfigOptionIntsNullable,
ConfigOptionPercentsNullable, ConfigOptionBoolsNullable.

retract override values were added to the Filament profile:
vector of floats: "retract_length", "retract_lift", "retract_lift_above",
	"retract_lift_below", "retract_speed", "deretract_speed",
	"retract_restart_extra", "retract_before_travel",
vector of bools: "retract_layer_change", "wipe"
vector of percents: "retract_before_wipe"
2019-07-23 14:15:42 +02:00
bubnikv
4049f33609 Fix of osx builds 2019-07-18 18:19:40 +02:00
bubnikv
9fd0c55eb8 Simplified the "cereal" includes to not clash with Perl includes 2019-07-04 22:09:14 +02:00
bubnikv
c7cc760067 Merge remote-tracking branch 'origin/master' into vb_undo_redo 2019-07-04 20:22:15 +02:00
bubnikv
da3583b1db Fix of https://github.com/prusa3d/PrusaSlicer/issues/2516 2019-06-27 09:48:19 +02:00
bubnikv
d99e932ee8 WIP Undo / Redo: Serialization of the Model / ModelObject / Model instance
using the cereal framework.
2019-06-26 16:29:12 +02:00
bubnikv
a710e7e7e4 WIP: Undo / Redo stack.
Integration of the "cereal" serialization library.
Serialization / deserialization of the DynamicConfig / DynamicPrintConfig.
DynamicPrintConfig serializes ordinal identifiers instead
of the option key strings to conserve space.
2019-06-26 13:26:49 +02:00
bubnikv
09d80b1b2a Added ConfigDef::get_default_value<>() template,
refactored calling code to use it.
2019-05-03 18:30:58 +02:00
bubnikv
a61e833536 Implemented the "Support for support enforcers only" quick selection.
Reduced some memory leaks due to the ConfigDef::default_value pointer.
2019-05-03 18:01:39 +02:00
bubnikv
c7ba650097 Help for the FFF / SLA command line parameters.
Removed the cli parameter from most options as it is derived
from the option key. Options without CLI parameter are now marked
with cli = nocli.
2019-03-13 19:17:26 +01:00
bubnikv
18025cc669 Reworked the command line interface based on the current state
of the upstream.
Thanks @alexrj, @lordofhyphens for the original code of slic3r.cpp
2019-03-13 15:44:50 +01:00
YuSanka
c62a51ead1 Implemented ModeSizer with ModeButtons for the mode view changing from the settings tabs and plater 2019-01-10 11:09:31 +01:00
YuSanka
591d42fd76 Fixed editing of the extruder's settings (SPE-735) 2019-01-08 10:18:21 +01:00
bubnikv
6888fefc2e Fixed constness of Config::env_ 2018-12-10 10:44:30 +01:00
bubnikv
c586ca4ae0 Implemented compatible_printer / compatible_printer_condition
for filaments and SLA materials.

Fixed compatible_printers / compatible_prints dialog to show
system profiles as well.
2018-12-04 17:56:49 +01:00
bubnikv
bbfbe88a5f Integrated SLAPrint into background processing.
Fixed couple of compiler warnings.
2018-11-08 20:18:40 +01:00
bubnikv
05b1ed3c2a Fixed a compilation issue on OSX 2018-11-08 15:02:47 +01:00
bubnikv
041de161a9 Fixes to storing and loading configs from AMF/3MF. 2018-11-07 14:57:50 +01:00
bubnikv
e4eec90046 Fixed loading of old 3mf files. 2018-11-06 19:09:54 +01:00
bubnikv
fd1c5dd218 WIP: SL1 profiles, SL1 in wizard, switching between FFF / SLA 2018-10-31 16:22:36 +01:00
bubnikv
66e97aa4eb Reduced memory leaks in ConfigDef / PrintConfigDef
Deleted unsafe default copy constructors / operators in Model / ModelObject / ModelInstance / ModelVolume
Fixed some issues with copying the Model / ModelObject / ModelInstance / ModelVolume inside Print::apply()
Fixed some invalidation issues in Print::apply()
Temporarily renamed the Slic3rPE profile directory to Slic3rPE-alpha.
2018-10-30 15:24:36 +01:00
YuSanka
3f9fb575b8 Middle mode is changed to Advanced 2018-10-25 14:55:03 +02:00
YuSanka
f47949504e Prototype of the hiding according to view mode
+ Added mode icon near option's label
+ Fixed segmentation fault on Linux
2018-10-21 23:10:36 +02:00
bubnikv
c3dc562ab0 Resurrected --dont-arrange command line parameter,
fixed command line print parameter validation.
2018-09-25 09:55:15 +02:00
bubnikv
9f2cd347e3 Fix of a set method to make ConfigOptionEnum compatible with
ConfigOptionEnumGeneric.
2018-09-21 23:00:49 +02:00
bubnikv
add45a8f6e Added C++ command line processing, thanks @alexrj and @loh 2018-09-20 16:48:13 +02:00
bubnikv
0558b53493 WIP: Moved sources int src/, separated most of the source code from Perl.
The XS was left only for the unit / integration tests, and it links
libslic3r only. No wxWidgets are allowed to be used from Perl starting
from now.
2018-09-19 11:02:24 +02:00