diff --git a/src/libslic3r/Arachne/SkeletalTrapezoidation.cpp b/src/libslic3r/Arachne/SkeletalTrapezoidation.cpp index 3248116169..077ffd1af6 100644 --- a/src/libslic3r/Arachne/SkeletalTrapezoidation.cpp +++ b/src/libslic3r/Arachne/SkeletalTrapezoidation.cpp @@ -466,8 +466,6 @@ void SkeletalTrapezoidation::constructFromPolygons(const Polygons& polys) edge.from->incident_edge = &edge; } -using NodeSet = SkeletalTrapezoidation::NodeSet; - void SkeletalTrapezoidation::separatePointyQuadEndNodes() { NodeSet visited_nodes; diff --git a/src/libslic3r/Arrange.cpp b/src/libslic3r/Arrange.cpp index 520f02f5f2..b79450a535 100644 --- a/src/libslic3r/Arrange.cpp +++ b/src/libslic3r/Arrange.cpp @@ -93,7 +93,6 @@ using namespace libnest2d; using Item = _Item; using Box = _Box; using Circle = _Circle; -using Segment = _Segment; using MultiPolygon = ExPolygons; // Summon the spatial indexing facilities from boost diff --git a/src/libslic3r/CutSurface.cpp b/src/libslic3r/CutSurface.cpp index 8967f6c2ba..cf5bd119f4 100644 --- a/src/libslic3r/CutSurface.cpp +++ b/src/libslic3r/CutSurface.cpp @@ -2851,7 +2851,6 @@ bool is_patch_inside_of_model(const SurfacePatch &patch, /// shape point index uint32_t get_shape_point_index(const CutAOI &cut, const CutMesh &model); -using PatchNumber = CutMesh::Property_map; /// /// Separate triangles singned with number n /// diff --git a/src/libslic3r/Feature/FuzzySkin/FuzzySkin.cpp b/src/libslic3r/Feature/FuzzySkin/FuzzySkin.cpp index ae8d50edb7..301eabebc3 100644 --- a/src/libslic3r/Feature/FuzzySkin/FuzzySkin.cpp +++ b/src/libslic3r/Feature/FuzzySkin/FuzzySkin.cpp @@ -32,8 +32,6 @@ // #define DEBUG_FUZZY -using namespace Slic3r; - namespace Slic3r::Feature::FuzzySkin { // Produces a random value between 0 and 1. Thread-safe. diff --git a/src/libslic3r/Fill/FillTpmsFK.cpp b/src/libslic3r/Fill/FillTpmsFK.cpp index 61dd220e64..164e240280 100644 --- a/src/libslic3r/Fill/FillTpmsFK.cpp +++ b/src/libslic3r/Fill/FillTpmsFK.cpp @@ -122,8 +122,6 @@ Polylines get_polylines(const ScalarField& sf, const double tolerance = SCALED_E namespace Slic3r { -using namespace std; - void FillTpmsFK::_fill_surface_single(const FillParams& params, unsigned int thickness_layers, const std::pair& direction, diff --git a/src/libslic3r/Format/AMF.cpp b/src/libslic3r/Format/AMF.cpp index 57165794c2..fa28d93f09 100644 --- a/src/libslic3r/Format/AMF.cpp +++ b/src/libslic3r/Format/AMF.cpp @@ -25,7 +25,6 @@ #include #include #include -namespace pt = boost::property_tree; #include #include diff --git a/src/libslic3r/GCode/SeamPlacer.cpp b/src/libslic3r/GCode/SeamPlacer.cpp index 07e1cc8882..c591dd1c6a 100644 --- a/src/libslic3r/GCode/SeamPlacer.cpp +++ b/src/libslic3r/GCode/SeamPlacer.cpp @@ -1135,7 +1135,6 @@ void SeamPlacer::gather_seam_candidates(const PrintObject *po, const SeamPlacerI void SeamPlacer::calculate_candidates_visibility(const PrintObject *po, const SeamPlacerImpl::GlobalModelInfo &global_model_info) { - using namespace SeamPlacerImpl; std::vector &layers = m_seam_per_object[po].layers; tbb::parallel_for(tbb::blocked_range(0, layers.size()), diff --git a/src/libslic3r/GCode/ToolOrdering.cpp b/src/libslic3r/GCode/ToolOrdering.cpp index 701c2a5858..c0f43f1888 100644 --- a/src/libslic3r/GCode/ToolOrdering.cpp +++ b/src/libslic3r/GCode/ToolOrdering.cpp @@ -1482,7 +1482,6 @@ static FilamentGroupContext build_filament_group_context( FilamentMapMode mode, const std::unordered_map& nozzle_status) { - using namespace MultiNozzleUtils; using namespace FilamentGroupUtils; FilamentGroupContext context; @@ -1691,7 +1690,6 @@ static std::vector apply_master_extruder_preference(const FilamentGroupCont // multi-nozzle (H2C/A2L) resolves to a nozzle-granular result. MultiNozzleUtils::LayeredNozzleGroupResult ToolOrdering::get_recommended_filament_maps(const std::vector>& layer_filaments, const Print* print, const FilamentMapMode mode, const std::vector>& physical_unprintables, const std::vector>& geometric_unprintables, const std::map>& unprintable_volumes, const std::unordered_map& nozzle_status) { - using namespace FilamentGroupUtils; using namespace MultiNozzleUtils; if (!print || layer_filaments.empty()) diff --git a/src/libslic3r/LayerRegion.cpp b/src/libslic3r/LayerRegion.cpp index 5bc68c4ca5..340f9a590d 100644 --- a/src/libslic3r/LayerRegion.cpp +++ b/src/libslic3r/LayerRegion.cpp @@ -230,7 +230,6 @@ std::vector get_grouped_bridges( { result.reserve(bridge_expansions.size()); uint32_t group_id = 0; - using std::move_iterator; for (ExPolygon& expolygon : bridge_expolygons) result.push_back({ std::move(expolygon), group_id ++, bridge_expansions.end() }); } @@ -432,7 +431,6 @@ Surfaces expand_bridges_detect_orientations( const float closing_radius ) { - using namespace Slic3r::Algorithm; double thickness; ExPolygons bridge_expolygons = fill_surfaces_extract_expolygons(surfaces, {stBottomBridge}, thickness); diff --git a/src/libslic3r/MeshBoolean.cpp b/src/libslic3r/MeshBoolean.cpp index 2a05378f58..8f30b356d1 100644 --- a/src/libslic3r/MeshBoolean.cpp +++ b/src/libslic3r/MeshBoolean.cpp @@ -660,7 +660,6 @@ bool empty(const CGALMesh &mesh) bool repair(TriangleMesh& mesh, RepairedMeshErrors* repaired_errors, std::string* error) { - using namespace CGAL; namespace PMP = CGAL::Polygon_mesh_processing; if (mesh.empty()) diff --git a/src/libslic3r/NSVGUtils.cpp b/src/libslic3r/NSVGUtils.cpp index 5274ffad4f..d81d5d5258 100644 --- a/src/libslic3r/NSVGUtils.cpp +++ b/src/libslic3r/NSVGUtils.cpp @@ -263,7 +263,6 @@ size_t get_shapes_count(const NSVGimage &image) } // namespace Slic3r namespace { -using namespace Slic3r; // Polygon + Vec2f Point::coord_type to_coor(float val, double scale) { return static_cast(std::round(val * scale)); } diff --git a/src/libslic3r/PlaceholderParser.cpp b/src/libslic3r/PlaceholderParser.cpp index 8bddfc1f10..18bbc7812e 100644 --- a/src/libslic3r/PlaceholderParser.cpp +++ b/src/libslic3r/PlaceholderParser.cpp @@ -2175,7 +2175,6 @@ namespace client { macro_processor() : macro_processor::base_type(start) { - using namespace qi::labels; qi::alpha_type alpha; qi::alnum_type alnum; qi::eps_type eps; diff --git a/src/libslic3r/PresetBundle.cpp b/src/libslic3r/PresetBundle.cpp index eb8321e4bd..fe74af66fd 100644 --- a/src/libslic3r/PresetBundle.cpp +++ b/src/libslic3r/PresetBundle.cpp @@ -1527,7 +1527,6 @@ bool PresetBundle::apply_vendor_config( const std::string& preferred_printer_variant, const std::string& preferred_filament) { - namespace fs = boost::filesystem; // Get current configuration from AppConfig const auto old_vendors = app_config->vendors(); diff --git a/src/libslic3r/utils.cpp b/src/libslic3r/utils.cpp index 8d5ab732be..cd9ecf100d 100644 --- a/src/libslic3r/utils.cpp +++ b/src/libslic3r/utils.cpp @@ -404,7 +404,6 @@ std::string debug_out_path(const char *name, ...) } namespace logging = boost::log; -namespace src = boost::log::sources; namespace expr = boost::log::expressions; namespace keywords = boost::log::keywords; namespace attrs = boost::log::attributes; @@ -892,7 +891,6 @@ int copy_file_linux_read_write(int infile, int outfile, uintmax_t file_size) // and only features supported by Linux 3.10 (on our build server with CentOS 7) are kept, namely sendfile with ranges and statx() are not supported. bool copy_file_linux(const boost::filesystem::path &from, const boost::filesystem::path &to, boost::system::error_code &ec) { - using namespace boost::filesystem; struct fd_wrapper { diff --git a/src/slic3r/GUI/BaseTransparentDPIFrame.cpp b/src/slic3r/GUI/BaseTransparentDPIFrame.cpp index 14575aa988..c9e4e4b76e 100644 --- a/src/slic3r/GUI/BaseTransparentDPIFrame.cpp +++ b/src/slic3r/GUI/BaseTransparentDPIFrame.cpp @@ -22,8 +22,6 @@ #include "CapsuleButton.hpp" namespace Slic3r::GUI { struct IntEvent; } -using namespace Slic3r; -using namespace Slic3r::GUI; namespace Slic3r { namespace GUI { #define ANIMATION_REFRESH_INTERVAL 20 diff --git a/src/slic3r/GUI/BitmapComboBox.cpp b/src/slic3r/GUI/BitmapComboBox.cpp index 217b885b91..9e5645bb41 100644 --- a/src/slic3r/GUI/BitmapComboBox.cpp +++ b/src/slic3r/GUI/BitmapComboBox.cpp @@ -45,8 +45,6 @@ #include #endif -using Slic3r::GUI::format_wxstr; - #define BORDER_W 10 // --------------------------------- diff --git a/src/slic3r/GUI/ConfigWizard.cpp b/src/slic3r/GUI/ConfigWizard.cpp index 6596cdca0c..347973c667 100644 --- a/src/slic3r/GUI/ConfigWizard.cpp +++ b/src/slic3r/GUI/ConfigWizard.cpp @@ -95,7 +95,6 @@ namespace GUI { using Config::Snapshot; -using Config::SnapshotDB; // Configuration data structures extensions needed for the wizard diff --git a/src/slic3r/GUI/DeviceCore/DevExtensionTool.cpp b/src/slic3r/GUI/DeviceCore/DevExtensionTool.cpp index 1947cf1d87..86cb7362c8 100644 --- a/src/slic3r/GUI/DeviceCore/DevExtensionTool.cpp +++ b/src/slic3r/GUI/DeviceCore/DevExtensionTool.cpp @@ -5,8 +5,6 @@ #include #include -using namespace nlohmann; - namespace Slic3r { diff --git a/src/slic3r/GUI/DeviceCore/DevExtruderSystemCtrl.cpp b/src/slic3r/GUI/DeviceCore/DevExtruderSystemCtrl.cpp index 38513a2274..9379920b27 100644 --- a/src/slic3r/GUI/DeviceCore/DevExtruderSystemCtrl.cpp +++ b/src/slic3r/GUI/DeviceCore/DevExtruderSystemCtrl.cpp @@ -1,11 +1,8 @@ -#include #include "DevExtruderSystem.h" #include "slic3r/GUI/DeviceManager.hpp" -using namespace nlohmann; - namespace Slic3r { int DevExtderSystem::CtrlRetrySwitching() diff --git a/src/slic3r/GUI/DeviceCore/DevMapping.cpp b/src/slic3r/GUI/DeviceCore/DevMapping.cpp index 1ad35d3ee9..906ac2345b 100644 --- a/src/slic3r/GUI/DeviceCore/DevMapping.cpp +++ b/src/slic3r/GUI/DeviceCore/DevMapping.cpp @@ -6,7 +6,6 @@ #include #include -#include #include #include #include @@ -21,8 +20,6 @@ #include "slic3r/GUI/DeviceManager.hpp" #include "slic3r/GUI/GuiColor.hpp" -using namespace nlohmann; - namespace Slic3r { bool DevMappingUtil::is_valid_mapping_result(const MachineObject* obj, std::vector& result, bool check_empty_slot) diff --git a/src/slic3r/GUI/DeviceManager.cpp b/src/slic3r/GUI/DeviceManager.cpp index 392ff4587b..8b7bf39fe1 100644 --- a/src/slic3r/GUI/DeviceManager.cpp +++ b/src/slic3r/GUI/DeviceManager.cpp @@ -115,8 +115,6 @@ namespace fs = boost::filesystem; #define ORCA_NETWORK_DEBUG -namespace pt = boost::property_tree; - float string_to_float(const std::string& str_value) { float value = 0.0; fast_float::from_chars(str_value.c_str(), str_value.c_str() + str_value.size(), value); diff --git a/src/slic3r/GUI/ExtraRenderers.cpp b/src/slic3r/GUI/ExtraRenderers.cpp index 92f39145f0..8f390b82e4 100644 --- a/src/slic3r/GUI/ExtraRenderers.cpp +++ b/src/slic3r/GUI/ExtraRenderers.cpp @@ -38,9 +38,6 @@ #include "wx/private/markupparser.h" #endif // wxUSE_ACCESSIBILITY -using Slic3r::GUI::from_u8; -using Slic3r::GUI::into_u8; - //----------------------------------------------------------------------------- // DataViewBitmapText diff --git a/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp b/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp index 2800b2b146..bcbef0b4b6 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp @@ -4098,8 +4098,6 @@ void GLGizmoCut3D::apply_cut_connectors(ModelObject* mo, const std::string& conn if (mo->cut_connectors.empty()) return; - using namespace Geometry; - size_t connector_id = mo->cut_id.connectors_cnt(); for (const CutConnector& connector : mo->cut_connectors) { TriangleMesh mesh = TriangleMesh(get_connector_mesh(connector.attribs)); diff --git a/src/slic3r/GUI/Gizmos/GLGizmoSVG.cpp b/src/slic3r/GUI/Gizmos/GLGizmoSVG.cpp index 2ab05d6179..c4d76a0315 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoSVG.cpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoSVG.cpp @@ -77,7 +77,6 @@ #include using namespace Slic3r; -using namespace Slic3r::Emboss; using namespace Slic3r::GUI; using namespace Slic3r::GUI::Emboss; diff --git a/src/slic3r/GUI/ImageDPIFrame.cpp b/src/slic3r/GUI/ImageDPIFrame.cpp index 83904fe650..2884792451 100644 --- a/src/slic3r/GUI/ImageDPIFrame.cpp +++ b/src/slic3r/GUI/ImageDPIFrame.cpp @@ -19,9 +19,6 @@ #include #include "wxExtensions.hpp" -using namespace Slic3r; -using namespace Slic3r::GUI; - namespace Slic3r { namespace GUI { #define ANIMATION_REFRESH_INTERVAL 20 ImageDPIFrame::ImageDPIFrame() diff --git a/src/slic3r/GUI/Jobs/CreateFontNameImageJob.cpp b/src/slic3r/GUI/Jobs/CreateFontNameImageJob.cpp index 6159182c2b..d80873d223 100644 --- a/src/slic3r/GUI/Jobs/CreateFontNameImageJob.cpp +++ b/src/slic3r/GUI/Jobs/CreateFontNameImageJob.cpp @@ -30,7 +30,6 @@ #include "libslic3r/libslic3r.h" #include -using namespace Slic3r; using namespace Slic3r::GUI; const std::string CreateFontImageJob::default_text = "AaBbCc 123"; diff --git a/src/slic3r/GUI/Jobs/CreateFontStyleImagesJob.cpp b/src/slic3r/GUI/Jobs/CreateFontStyleImagesJob.cpp index ac9b11b81e..f1b545ad4c 100644 --- a/src/slic3r/GUI/Jobs/CreateFontStyleImagesJob.cpp +++ b/src/slic3r/GUI/Jobs/CreateFontStyleImagesJob.cpp @@ -23,9 +23,6 @@ #include #include -using namespace Slic3r; -using namespace Slic3r::Emboss; -using namespace Slic3r::GUI; using namespace Slic3r::GUI::Emboss; diff --git a/src/slic3r/GUI/MonitorBasePanel.cpp b/src/slic3r/GUI/MonitorBasePanel.cpp index d8a1f3b835..e09be6d6f9 100644 --- a/src/slic3r/GUI/MonitorBasePanel.cpp +++ b/src/slic3r/GUI/MonitorBasePanel.cpp @@ -293,7 +293,6 @@ VideoMonitoringBasePanel::~VideoMonitoringBasePanel() /////////////////////////////////////////////////////////////////////////// -using namespace Slic3r::GUI; TaskListBasePanel::TaskListBasePanel(wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name) : wxPanel(parent, id, pos, size, style, name) { diff --git a/src/slic3r/GUI/PartPlate.cpp b/src/slic3r/GUI/PartPlate.cpp index 6450bf0747..9798d2df23 100644 --- a/src/slic3r/GUI/PartPlate.cpp +++ b/src/slic3r/GUI/PartPlate.cpp @@ -1,4 +1,3 @@ -#include #include #include #include @@ -60,7 +59,6 @@ #include #include #include -#include #include #include #include @@ -113,9 +111,6 @@ #include "slic3r/GUI/GLModel.hpp" class wxFont; -namespace boost { template class optional; } -using boost::optional; -namespace fs = boost::filesystem; static const float GROUND_Z = -0.03f; static const float GROUND_Z_GRIDLINE = -0.26f; diff --git a/src/slic3r/GUI/Plater.cpp b/src/slic3r/GUI/Plater.cpp index c2b0e6f0a9..08dad219b0 100644 --- a/src/slic3r/GUI/Plater.cpp +++ b/src/slic3r/GUI/Plater.cpp @@ -296,11 +296,7 @@ #include "DeviceCore/DevConfigUtil.h" #include "DeviceCore/DevDefs.h" -using boost::optional; namespace fs = boost::filesystem; -using Slic3r::_3DScene; -using Slic3r::Preset; -using Slic3r::GUI::format_wxstr; using namespace nlohmann; static const std::pair THUMBNAIL_SIZE_3MF = { 512, 512 }; diff --git a/src/slic3r/GUI/PresetComboBoxes.cpp b/src/slic3r/GUI/PresetComboBoxes.cpp index 29e34d98a0..d1e4d6126a 100644 --- a/src/slic3r/GUI/PresetComboBoxes.cpp +++ b/src/slic3r/GUI/PresetComboBoxes.cpp @@ -81,8 +81,6 @@ #include #endif -using Slic3r::GUI::format_wxstr; - namespace Slic3r { namespace GUI { diff --git a/src/slic3r/GUI/ReleaseNote.cpp b/src/slic3r/GUI/ReleaseNote.cpp index 67dc80ca6d..f94e80e0f5 100644 --- a/src/slic3r/GUI/ReleaseNote.cpp +++ b/src/slic3r/GUI/ReleaseNote.cpp @@ -76,8 +76,6 @@ namespace Slic3r::GUI { class Plater; } -namespace fs = boost::filesystem; - namespace Slic3r { namespace GUI { wxDEFINE_EVENT(EVT_SECONDARY_CHECK_CONFIRM, wxCommandEvent); diff --git a/src/slic3r/GUI/SavePresetDialog.cpp b/src/slic3r/GUI/SavePresetDialog.cpp index 1d4c2913db..1cae6420ed 100644 --- a/src/slic3r/GUI/SavePresetDialog.cpp +++ b/src/slic3r/GUI/SavePresetDialog.cpp @@ -42,8 +42,6 @@ #include "Widgets/DialogButtons.hpp" -using Slic3r::GUI::format_wxstr; - namespace Slic3r { namespace GUI { #define BORDER_W 10 diff --git a/src/slic3r/GUI/Search.cpp b/src/slic3r/GUI/Search.cpp index dcf0573321..597f809adc 100644 --- a/src/slic3r/GUI/Search.cpp +++ b/src/slic3r/GUI/Search.cpp @@ -1,6 +1,5 @@ #include "Search.hpp" -#include #include "slic3r/GUI/GUI.hpp" #include "libslic3r/Preset.hpp" #include "libslic3r/Config.hpp" @@ -22,7 +21,6 @@ #include #include #include -#include #include #include #include @@ -56,8 +54,6 @@ #include "LinuxDisplayBackend.hpp" #endif -using boost::optional; - namespace Slic3r { wxDEFINE_EVENT(wxCUSTOMEVT_JUMP_TO_OPTION, wxCommandEvent); diff --git a/src/slic3r/GUI/SyncAmsInfoDialog.cpp b/src/slic3r/GUI/SyncAmsInfoDialog.cpp index f4c59088bd..9e6dcbde49 100644 --- a/src/slic3r/GUI/SyncAmsInfoDialog.cpp +++ b/src/slic3r/GUI/SyncAmsInfoDialog.cpp @@ -86,9 +86,6 @@ namespace fs = boost::filesystem; -using namespace Slic3r; -using namespace Slic3r::GUI; - #define OK_BUTTON_SIZE wxSize(FromDIP(90), FromDIP(24)) #define CANCEL_BUTTON_SIZE wxSize(FromDIP(58), FromDIP(24)) #define SyncAmsInfoDialogWidth FromDIP(675) diff --git a/src/slic3r/GUI/UnsavedChangesDialog.cpp b/src/slic3r/GUI/UnsavedChangesDialog.cpp index dffc86a25c..b2bc818ad1 100644 --- a/src/slic3r/GUI/UnsavedChangesDialog.cpp +++ b/src/slic3r/GUI/UnsavedChangesDialog.cpp @@ -1,6 +1,5 @@ #include "UnsavedChangesDialog.hpp" -#include #include #include #include @@ -26,7 +25,6 @@ #include #include #include -#include #include #include @@ -66,8 +64,6 @@ #include "Widgets/DialogButtons.hpp" #include "Widgets/HyperLink.hpp" -using boost::optional; - #ifdef __linux__ #define wxLinux true #else diff --git a/src/slic3r/GUI/WebGuideDialog.cpp b/src/slic3r/GUI/WebGuideDialog.cpp index 665280aca9..d70f4ea81a 100644 --- a/src/slic3r/GUI/WebGuideDialog.cpp +++ b/src/slic3r/GUI/WebGuideDialog.cpp @@ -82,8 +82,6 @@ class wxWindow; -namespace fs = boost::filesystem; - using namespace nlohmann; namespace Slic3r { namespace GUI { diff --git a/src/slic3r/GUI/WebUserLoginDialog.cpp b/src/slic3r/GUI/WebUserLoginDialog.cpp index bf7c7d9365..6d30545177 100644 --- a/src/slic3r/GUI/WebUserLoginDialog.cpp +++ b/src/slic3r/GUI/WebUserLoginDialog.cpp @@ -53,7 +53,6 @@ #include #include #include // ORCA -using namespace std; using namespace nlohmann; diff --git a/src/slic3r/Utils/3DPrinterOS.cpp b/src/slic3r/Utils/3DPrinterOS.cpp index 29b6bd63f8..f7a3387a7c 100644 --- a/src/slic3r/Utils/3DPrinterOS.cpp +++ b/src/slic3r/Utils/3DPrinterOS.cpp @@ -43,9 +43,6 @@ #include -using json = nlohmann::json; - -namespace fs = boost::filesystem; namespace pt = boost::property_tree; namespace { diff --git a/src/slic3r/Utils/AstroBox.cpp b/src/slic3r/Utils/AstroBox.cpp index 6904b56920..75976f7aa3 100644 --- a/src/slic3r/Utils/AstroBox.cpp +++ b/src/slic3r/Utils/AstroBox.cpp @@ -21,7 +21,6 @@ #include "Http.hpp" -namespace fs = boost::filesystem; namespace pt = boost::property_tree; diff --git a/src/slic3r/Utils/BBLCloudServiceAgent.cpp b/src/slic3r/Utils/BBLCloudServiceAgent.cpp index 96525354e5..3737af2f18 100644 --- a/src/slic3r/Utils/BBLCloudServiceAgent.cpp +++ b/src/slic3r/Utils/BBLCloudServiceAgent.cpp @@ -18,8 +18,6 @@ #include #include "libslic3r/AppConfig.hpp" -using json = nlohmann::json; - namespace Slic3r { diff --git a/src/slic3r/Utils/CrealityPrint.cpp b/src/slic3r/Utils/CrealityPrint.cpp index 8a187ff998..081c5dd543 100644 --- a/src/slic3r/Utils/CrealityPrint.cpp +++ b/src/slic3r/Utils/CrealityPrint.cpp @@ -22,8 +22,6 @@ #include #include #include -#include -#include #include #include #include @@ -55,7 +53,6 @@ #include #include using json = nlohmann::json; -using std::to_string; namespace beast = boost::beast; namespace http = beast::http; @@ -63,9 +60,6 @@ namespace websocket = beast::websocket; namespace net = boost::asio; using tcp = boost::asio::ip::tcp; -namespace fs = boost::filesystem; -namespace pt = boost::property_tree; - namespace Slic3r { CrealityPrint::CrealityPrint(DynamicPrintConfig* config) : diff --git a/src/slic3r/Utils/CrealityPrintAgent.cpp b/src/slic3r/Utils/CrealityPrintAgent.cpp index 10f6a51c5d..a8910c2e09 100644 --- a/src/slic3r/Utils/CrealityPrintAgent.cpp +++ b/src/slic3r/Utils/CrealityPrintAgent.cpp @@ -214,7 +214,6 @@ bool CrealityPrintAgent::parse_cfs_response(const std::string& response, int& box_count, std::string& error) { - using nlohmann::json; slots.clear(); box_count = 0; diff --git a/src/slic3r/Utils/Duet.cpp b/src/slic3r/Utils/Duet.cpp index b5ad48fbae..419d795b65 100644 --- a/src/slic3r/Utils/Duet.cpp +++ b/src/slic3r/Utils/Duet.cpp @@ -3,11 +3,8 @@ #include #include #include -#include #include #include -#include -#include #include #include @@ -25,9 +22,6 @@ #include "slic3r/GUI/I18N.hpp" #include "Http.hpp" -namespace fs = boost::filesystem; -namespace pt = boost::property_tree; - namespace Slic3r { Duet::Duet(DynamicPrintConfig *config) : diff --git a/src/slic3r/Utils/ESP3D.cpp b/src/slic3r/Utils/ESP3D.cpp index 7f0cba2414..3890da8235 100644 --- a/src/slic3r/Utils/ESP3D.cpp +++ b/src/slic3r/Utils/ESP3D.cpp @@ -7,8 +7,6 @@ #include #include #include -#include -#include #include #include @@ -28,9 +26,6 @@ #include "slic3r/GUI/I18N.hpp" #include "Http.hpp" -namespace fs = boost::filesystem; -namespace pt = boost::property_tree; - namespace Slic3r { ESP3D::ESP3D(DynamicPrintConfig* config) : m_host(config->opt_string("print_host")), m_console_port("8888") {} diff --git a/src/slic3r/Utils/ElegooLink.cpp b/src/slic3r/Utils/ElegooLink.cpp index d6b40578aa..bb83dca2f5 100644 --- a/src/slic3r/Utils/ElegooLink.cpp +++ b/src/slic3r/Utils/ElegooLink.cpp @@ -50,7 +50,6 @@ #include "slic3r/GUI/BonjourDialog.hpp" #include -namespace fs = boost::filesystem; namespace pt = boost::property_tree; #define MAX_UPLOAD_PACKAGE_LENGTH 1048576 //(1024*1024) diff --git a/src/slic3r/Utils/EmbossStyleManager.cpp b/src/slic3r/Utils/EmbossStyleManager.cpp index 5f03bd5df3..d873b40cf3 100644 --- a/src/slic3r/Utils/EmbossStyleManager.cpp +++ b/src/slic3r/Utils/EmbossStyleManager.cpp @@ -561,7 +561,6 @@ bool StyleManager::set_wx_font(const wxFont &wx_font, std::unique_ptr // StylesSerializable namespace { -using namespace Slic3r; using namespace Slic3r::GUI; using Section = std::map; diff --git a/src/slic3r/Utils/FlashAir.cpp b/src/slic3r/Utils/FlashAir.cpp index 16648c711d..0257fec556 100644 --- a/src/slic3r/Utils/FlashAir.cpp +++ b/src/slic3r/Utils/FlashAir.cpp @@ -2,7 +2,6 @@ #include #include -#include #include #include #include @@ -23,9 +22,6 @@ #include "slic3r/GUI/I18N.hpp" #include "Http.hpp" -namespace fs = boost::filesystem; -namespace pt = boost::property_tree; - namespace Slic3r { FlashAir::FlashAir(DynamicPrintConfig *config) : diff --git a/src/slic3r/Utils/Flashforge.cpp b/src/slic3r/Utils/Flashforge.cpp index b0697b80d4..fd6ad6fcf7 100644 --- a/src/slic3r/Utils/Flashforge.cpp +++ b/src/slic3r/Utils/Flashforge.cpp @@ -25,8 +25,6 @@ #include #include #include -#include -#include #include #include @@ -55,7 +53,6 @@ #include "SerialMessageType.hpp" namespace fs = boost::filesystem; -namespace pt = boost::property_tree; using json = nlohmann::json; namespace Slic3r { diff --git a/src/slic3r/Utils/FontConfigHelp.cpp b/src/slic3r/Utils/FontConfigHelp.cpp index f3280ad83d..81f7d9784c 100644 --- a/src/slic3r/Utils/FontConfigHelp.cpp +++ b/src/slic3r/Utils/FontConfigHelp.cpp @@ -13,8 +13,6 @@ #include #include "libslic3r/Utils.hpp" -using namespace Slic3r::GUI; - // @Vojta suggest to make static variable global // Guard for finalize Font Config diff --git a/src/slic3r/Utils/MKS.cpp b/src/slic3r/Utils/MKS.cpp index 52649a667f..cac9f08110 100644 --- a/src/slic3r/Utils/MKS.cpp +++ b/src/slic3r/Utils/MKS.cpp @@ -4,11 +4,8 @@ #include #include #include -#include #include #include -#include -#include #include #include @@ -31,9 +28,6 @@ #include "SerialMessage.hpp" #include "SerialMessageType.hpp" -namespace fs = boost::filesystem; -namespace pt = boost::property_tree; - namespace Slic3r { MKS::MKS(DynamicPrintConfig* config) : diff --git a/src/slic3r/Utils/Obico.cpp b/src/slic3r/Utils/Obico.cpp index 37a618445a..1a86be377b 100644 --- a/src/slic3r/Utils/Obico.cpp +++ b/src/slic3r/Utils/Obico.cpp @@ -30,7 +30,6 @@ #include "libslic3r/AppConfig.hpp" #include "slic3r/GUI/BonjourDialog.hpp" -namespace fs = boost::filesystem; namespace pt = boost::property_tree; diff --git a/src/slic3r/Utils/OctoPrint.cpp b/src/slic3r/Utils/OctoPrint.cpp index 63199c8781..8fb511d193 100644 --- a/src/slic3r/Utils/OctoPrint.cpp +++ b/src/slic3r/Utils/OctoPrint.cpp @@ -37,7 +37,6 @@ #include #include -namespace fs = boost::filesystem; namespace pt = boost::property_tree; diff --git a/src/slic3r/Utils/PresetUpdater.cpp b/src/slic3r/Utils/PresetUpdater.cpp index 90807eb723..9b518f5a8e 100644 --- a/src/slic3r/Utils/PresetUpdater.cpp +++ b/src/slic3r/Utils/PresetUpdater.cpp @@ -64,8 +64,6 @@ namespace Slic3r::GUI::Config { class SnapshotDB; } namespace fs = boost::filesystem; using Slic3r::GUI::Config::Index; using Slic3r::GUI::Config::Version; -using Slic3r::GUI::Config::Snapshot; -using Slic3r::GUI::Config::SnapshotDB; // FIXME: Incompat bundle resolution doesn't deal with inherited user presets diff --git a/src/slic3r/Utils/PrintHost.cpp b/src/slic3r/Utils/PrintHost.cpp index 2b3c4d181d..b51dcc6af3 100644 --- a/src/slic3r/Utils/PrintHost.cpp +++ b/src/slic3r/Utils/PrintHost.cpp @@ -1,6 +1,5 @@ #include "PrintHost.hpp" -#include #include "libslic3r/Config.hpp" #include #include @@ -16,7 +15,6 @@ #include #include #include -#include #include #include #include @@ -50,7 +48,6 @@ #include "Moonraker.hpp" namespace fs = boost::filesystem; -using boost::optional; using Slic3r::GUI::PrintHostQueueDialog; namespace Slic3r { diff --git a/src/slic3r/Utils/QidiPrinterAgent.cpp b/src/slic3r/Utils/QidiPrinterAgent.cpp index 06499e1092..c2dc4411a6 100644 --- a/src/slic3r/Utils/QidiPrinterAgent.cpp +++ b/src/slic3r/Utils/QidiPrinterAgent.cpp @@ -18,8 +18,6 @@ #include #include -using json = nlohmann::json; - namespace Slic3r { namespace { diff --git a/src/slic3r/Utils/Repetier.cpp b/src/slic3r/Utils/Repetier.cpp index ae269cac4f..1663a3570a 100644 --- a/src/slic3r/Utils/Repetier.cpp +++ b/src/slic3r/Utils/Repetier.cpp @@ -27,7 +27,6 @@ #include "Http.hpp" -namespace fs = boost::filesystem; namespace pt = boost::property_tree; diff --git a/src/slic3r/Utils/Serial.cpp b/src/slic3r/Utils/Serial.cpp index 2b64330826..1b54125c0f 100644 --- a/src/slic3r/Utils/Serial.cpp +++ b/src/slic3r/Utils/Serial.cpp @@ -288,7 +288,6 @@ std::vector scan_serial_ports() // Class Serial namespace asio = boost::asio; -using boost::system::error_code; Serial::Serial(asio::io_service& io_service) : asio::serial_port(io_service) diff --git a/src/slic3r/Utils/SnapmakerPrinterAgent.cpp b/src/slic3r/Utils/SnapmakerPrinterAgent.cpp index a237d1b2b1..b172ebb015 100644 --- a/src/slic3r/Utils/SnapmakerPrinterAgent.cpp +++ b/src/slic3r/Utils/SnapmakerPrinterAgent.cpp @@ -13,8 +13,6 @@ #include #include -using json = nlohmann::json; - namespace Slic3r { namespace { diff --git a/src/slic3r/Utils/TCPConsole.cpp b/src/slic3r/Utils/TCPConsole.cpp index 78d4624abc..45192c2786 100644 --- a/src/slic3r/Utils/TCPConsole.cpp +++ b/src/slic3r/Utils/TCPConsole.cpp @@ -3,9 +3,7 @@ #include #include #include -#include #include -#include #include #include #include @@ -24,9 +22,6 @@ #include "SerialMessage.hpp" #include "SerialMessageType.hpp" -using boost::asio::steady_timer; -using boost::asio::ip::tcp; - namespace Slic3r { namespace Utils { diff --git a/src/slic3r/Utils/UltiMaker.cpp b/src/slic3r/Utils/UltiMaker.cpp index 432725f0e8..9b6894034e 100644 --- a/src/slic3r/Utils/UltiMaker.cpp +++ b/src/slic3r/Utils/UltiMaker.cpp @@ -6,7 +6,6 @@ #include #include #include -#include #include #include #include @@ -34,8 +33,6 @@ #include #include #include -namespace fs = boost::filesystem; -namespace pt = boost::property_tree; namespace Slic3r { diff --git a/src/slic3r/Utils/json_diff.cpp b/src/slic3r/Utils/json_diff.cpp index 171a44c63d..37bb55f799 100644 --- a/src/slic3r/Utils/json_diff.cpp +++ b/src/slic3r/Utils/json_diff.cpp @@ -16,7 +16,6 @@ #include #include -using namespace std; using json = nlohmann::json; int json_diff::diff_objects(json const &in, json &out, json const &base) diff --git a/tests/fff_print/test_flow.cpp b/tests/fff_print/test_flow.cpp index 328c610e02..f3e8abd02e 100644 --- a/tests/fff_print/test_flow.cpp +++ b/tests/fff_print/test_flow.cpp @@ -12,7 +12,6 @@ #include "libslic3r/Flow.hpp" #include "libslic3r/libslic3r.h" -using namespace Slic3r::Test; using namespace Slic3r; /// Test the expected behavior for auto-width, diff --git a/tests/fff_print/test_helpers.cpp b/tests/fff_print/test_helpers.cpp index e32f79944e..14365a5860 100644 --- a/tests/fff_print/test_helpers.cpp +++ b/tests/fff_print/test_helpers.cpp @@ -27,8 +27,6 @@ #include "test_utils.hpp" -using namespace std; - namespace Slic3r { namespace Test { const std::unordered_map mesh_names { diff --git a/tests/fff_print/test_model.cpp b/tests/fff_print/test_model.cpp index 43041c0bdf..1ad806e455 100644 --- a/tests/fff_print/test_model.cpp +++ b/tests/fff_print/test_model.cpp @@ -19,7 +19,6 @@ #include "libslic3r/Print.hpp" using namespace Slic3r; -using namespace Slic3r::Test; SCENARIO("Model construction", "[Model]") { GIVEN("A Slic3r Model") { diff --git a/tests/fff_print/test_trianglemesh.cpp b/tests/fff_print/test_trianglemesh.cpp index b7e3b96beb..ab5c334d2e 100644 --- a/tests/fff_print/test_trianglemesh.cpp +++ b/tests/fff_print/test_trianglemesh.cpp @@ -21,7 +21,6 @@ //#include "test_options.hpp" using namespace Slic3r; -using namespace std; static inline TriangleMesh make_cube() { return make_cube(20., 20, 20); } diff --git a/tests/libslic3r/test_arachne_walls.cpp b/tests/libslic3r/test_arachne_walls.cpp index f568a0d014..9f216a0518 100644 --- a/tests/libslic3r/test_arachne_walls.cpp +++ b/tests/libslic3r/test_arachne_walls.cpp @@ -241,7 +241,6 @@ TEST_CASE("Arachne wall generation - 60% min_bead_width", "[Arachne]") { // getTransitionThickness(1) = (1 + 0.619) * 0.42 = 0.68mm. A 0.5mm-thick wall therefore sits // in the transition band: alpha produced 2 beads here, beta collapses it to 1 fat bead. TEST_CASE("Arachne widening keeps two beads in transition band (#14376)", "[Arachne]") { - using namespace Slic3r::Arachne; // Widths in mm; the scaled coord_t values and the thresholds below are both derived from // these so a width change cannot silently desync the transition-band math. diff --git a/tests/libslic3r/test_caddocument.cpp b/tests/libslic3r/test_caddocument.cpp index 84c93a39d0..4ee1de587d 100644 --- a/tests/libslic3r/test_caddocument.cpp +++ b/tests/libslic3r/test_caddocument.cpp @@ -992,7 +992,6 @@ TEST_CASE("tessellate tracks per-triangle face id", "[CadDocument]") TEST_CASE("extrude two-sided + through-all + intersect", "[CadDocument]") { - using namespace Slic3r; SketchPlane xy = SketchPlane::XY(); // a 10x10 square wire centred on origin SketchProfile sp; @@ -1013,7 +1012,6 @@ TEST_CASE("extrude two-sided + through-all + intersect", "[CadDocument]") TEST_CASE("extrude taper + up-to-face distance", "[CadDocument]") { - using namespace Slic3r; SketchPlane xy = SketchPlane::XY(); SketchProfile sp; sp.points = { Vec2d(-5,-5),Vec2d(5,-5),Vec2d(5,5),Vec2d(-5,5) }; sp.closed = true; TopoDS_Wire w = sp.to_occt_wire(xy); @@ -1047,7 +1045,6 @@ TEST_CASE("extrude taper + up-to-face distance", "[CadDocument]") // asserting, because that is what "the thread actually cuts" means. TEST_CASE("internal thread cuts a visible groove into the bore wall", "[CadDocument][thread]") { - using namespace Slic3r; SketchPlane xy = SketchPlane::XY(); // 40x40x20 box centred on the origin, extruded +Z. @@ -1093,7 +1090,6 @@ TEST_CASE("internal thread cuts a visible groove into the bore wall", "[CadDocum TEST_CASE("revolve builds a solid of revolution about an in-plane axis", "[CadDocument]") { - using namespace Slic3r; SketchPlane xy = SketchPlane::XY(); // Rectangle profile (10 wide x 10 tall, area 100) offset to +v so it lies entirely @@ -1136,7 +1132,6 @@ TEST_CASE("revolve builds a solid of revolution about an in-plane axis", "[CadDo TEST_CASE("sweep builds a solid by sweeping a profile along a path", "[CadDocument]") { - using namespace Slic3r; CadDocument doc; // Profile: circle r=5 on the XY plane at the origin (area = 25*pi). @@ -1172,7 +1167,6 @@ TEST_CASE("sweep builds a solid by sweeping a profile along a path", "[CadDocume TEST_CASE("pattern replicates a body linearly and circularly", "[CadDocument]") { - using namespace Slic3r; // Linear: a 10x10x10 box (V=1000) repeated 3x at 20mm spacing along plane X. // 20 > 10 so the copies are disjoint -> total V = 3*1000 = 3000. @@ -1221,8 +1215,6 @@ TEST_CASE("pattern replicates a body linearly and circularly", "[CadDocument]") TEST_CASE("pattern-on-curve: copies land on a line and bbox spans the curve length", "[CadDocument][pattern]") { using Catch::Matchers::WithinAbs; - using Catch::Matchers::WithinRel; - using namespace Slic3r; CadDocument doc; @@ -1250,7 +1242,6 @@ TEST_CASE("pattern-on-curve: copies land on a line and bbox spans the curve leng TEST_CASE("pattern-on-curve: bad refs are safe", "[CadDocument][pattern]") { - using namespace Slic3r; CadDocument doc; int s0 = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 4, 4, 0, "Seed"); @@ -1266,7 +1257,6 @@ TEST_CASE("pattern-on-curve: bad refs are safe", "[CadDocument][pattern]") TEST_CASE("pattern-on-curve: round-trip through serialize/deserialize", "[CadDocument][pattern]") { using Catch::Matchers::WithinRel; - using namespace Slic3r; CadDocument doc; int s0 = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 4, 4, 0, "Seed"); @@ -1312,7 +1302,6 @@ TEST_CASE("pattern-on-curve: round-trip through serialize/deserialize", "[CadDoc TEST_CASE("thread standards table carries correct ISO/UTS measures", "[CadDocument]") { - using namespace Slic3r; // Table is non-empty and every entry is self-consistent. const auto& table = thread_standards(); @@ -1459,7 +1448,6 @@ TEST_CASE("loft builds a solid skinning two profiles on parallel planes", "[CadD TEST_CASE("draft tapers a solid face about the body base", "[CadDocument]") { - using namespace Slic3r; // 10x10x10 box from z=0..10 (V=1000). Drafting a vertical side face by +10deg about // the bottom (neutral) plane tilts its top edge inward, removing material so V<1000. @@ -1740,7 +1728,6 @@ TEST_CASE("split by face keep upper only", "[CadDocument][cut]") TEST_CASE("split by face round-trip serialization", "[CadDocument][cut]") { - using Catch::Matchers::WithinRel; using Catch::Matchers::WithinAbs; CadDocument doc; @@ -1808,7 +1795,6 @@ TEST_CASE("split by face round-trip serialization", "[CadDocument][cut]") TEST_CASE("mirror reflects a body about a plane", "[CadDocument]") { using Catch::Matchers::WithinRel; - using Catch::Matchers::WithinAbs; auto make_box = [](CadDocument& doc, double w, double h, double d) { int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), w, h, 0, "Box"); @@ -1939,7 +1925,6 @@ TEST_CASE("mirror reflects a body about a plane", "[CadDocument]") TEST_CASE("mirror serialization round-trip", "[CadDocument]") { - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 0, "Box"); @@ -2453,7 +2438,6 @@ TEST_CASE("a v3 recipe is refused with a message naming the version", "[CadDocum TEST_CASE("re-edit: editing a mid-timeline feature rebuilds downstream", "[CadDocument]") { - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), @@ -2486,7 +2470,6 @@ TEST_CASE("re-edit: editing a mid-timeline feature rebuilds downstream", "[CadDo TEST_CASE("re-edit survives serialize -> deserialize", "[CadDocument]") { - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), @@ -2519,7 +2502,6 @@ TEST_CASE("re-edit survives serialize -> deserialize", "[CadDocument]") TEST_CASE("re-edit: multi-type timeline replays all downstream features", "[CadDocument]") { - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), @@ -2994,7 +2976,6 @@ TEST_CASE("datum coordinate system: point_world gives world axes", "[CadDocument TEST_CASE("helix curve: arc length, bounding box, left-handed, conical", "[CadDocument]") { using Catch::Matchers::WithinRel; - using Catch::Matchers::WithinAbs; // --- Cylindrical helix r=5, pitch=2, height=10 (5 turns) --- // One turn arc length = sqrt((2*pi*r)^2 + pitch^2) = sqrt((10*pi)^2 + 4). @@ -3386,7 +3367,6 @@ TEST_CASE("transform degenerate axis errors", "[CadDocument]") TEST_CASE("transform moved body participates in later boolean at its new position", "[CadDocument]") { - using Catch::Matchers::WithinAbs; CadDocument doc; // Two boxes that do NOT overlap @@ -3516,7 +3496,6 @@ TEST_CASE("thicken a planar face to a plate", "[CadDocument]") TEST_CASE("thicken flip offsets against face normal", "[CadDocument]") { - using Catch::Matchers::WithinAbs; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 0, "BoxSketch"); @@ -3615,7 +3594,6 @@ TEST_CASE("thicken zero thickness returns error", "[CadDocument]") TEST_CASE("thickened plate fuses with source", "[CadDocument]") { - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 0, "Box"); @@ -3649,7 +3627,6 @@ TEST_CASE("thickened plate fuses with source", "[CadDocument]") TEST_CASE("thicken round-trip serialization", "[CadDocument]") { using Catch::Matchers::WithinAbs; - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 0, "Box"); @@ -3833,7 +3810,6 @@ TEST_CASE("project bad face id returns error", "[CadDocument][project]") TEST_CASE("project round-trip serialization", "[CadDocument][project]") { using Catch::Matchers::WithinAbs; - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 10, "Box"); @@ -4609,8 +4585,6 @@ TEST_CASE("golden recipe v1 still deserialises", "[CadDocument]") TEST_CASE("rib adds material to a box", "[CadDocument][rib]") { - using Catch::Matchers::WithinRel; - using Catch::Matchers::WithinAbs; CadDocument doc; @@ -4763,7 +4737,6 @@ TEST_CASE("bridge two collinear lines", "[CadDocument][bridge]") TEST_CASE("bridge closes a C profile and extrudes", "[CadDocument][bridge]") { - using Catch::Matchers::WithinAbs; using Catch::Matchers::WithinRel; CadDocument doc; @@ -4861,8 +4834,6 @@ TEST_CASE("bridge round-trip serialization", "[CadDocument][bridge]") TEST_CASE("delete_face removes a fillet face and restores volume", "[CadDocument][deleteface]") { - using Catch::Matchers::WithinRel; - using Catch::Matchers::WithinAbs; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 10, "Box"); @@ -4912,7 +4883,6 @@ TEST_CASE("delete_face with bad face index fails safely", "[CadDocument][deletef TEST_CASE("delete_face round-trip serialization", "[CadDocument][deleteface]") { - using Catch::Matchers::WithinRel; using Catch::Matchers::WithinAbs; CadDocument doc; @@ -4970,7 +4940,6 @@ TEST_CASE("delete_face round-trip serialization", "[CadDocument][deleteface]") TEST_CASE("hole: counterbore removes more material than a simple bore", "[CadDocument][hole]") { - using Catch::Matchers::WithinAbs; auto make_box_hole = [](int style, double cbore_d, double cbore_depth, double csink_d, double csink_angle, const std::string& desig) { CadDocument doc; @@ -4998,7 +4967,6 @@ TEST_CASE("hole: counterbore removes more material than a simple bore", "[CadDoc TEST_CASE("hole: countersink removes more material than a simple bore", "[CadDocument][hole]") { - using Catch::Matchers::WithinAbs; auto make_box = []() { CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 30, 30, 0, "Box"); @@ -5301,7 +5269,6 @@ TEST_CASE("parametric recipe round-trips through serialize/deserialize", "[CadDo TEST_CASE("surface-extrude makes an open shell", "[CadDocument][surface]") { - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 0, "Rect"); @@ -5324,7 +5291,6 @@ TEST_CASE("surface-extrude makes an open shell", "[CadDocument][surface]") TEST_CASE("surface-revolve makes an open shell", "[CadDocument][surface]") { - using Catch::Matchers::WithinRel; CadDocument doc; // A small rectangle offset from the axis: u=10..15, v=0..5. @@ -5395,7 +5361,6 @@ TEST_CASE("surface round-trip serialize/deserialize", "[CadDocument][surface]") TEST_CASE("thicken-surface makes a solid from a sheet", "[CadDocument][surface]") { - using Catch::Matchers::WithinRel; using Catch::Matchers::WithinAbs; CadDocument doc; @@ -5519,7 +5484,6 @@ TEST_CASE("thicken surface fills the corners of a closed-loop wall", "[CadDocume TEST_CASE("surface-offset creates another sheet shifted outward", "[CadDocument][surface]") { - using Catch::Matchers::WithinAbs; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 0, "Rect"); @@ -5568,7 +5532,6 @@ TEST_CASE("thicken-surface on non-sheet fails", "[CadDocument][surface]") TEST_CASE("thicken-surface round-trip serialize/deserialize", "[CadDocument][surface]") { using Catch::Matchers::WithinAbs; - using Catch::Matchers::WithinRel; CadDocument doc; int sk = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 20, 20, 0, "Rect"); @@ -5608,7 +5571,6 @@ TEST_CASE("thicken-surface round-trip serialize/deserialize", "[CadDocument][sur TEST_CASE("surface-loft makes an open shell", "[CadDocument][surface]") { - using Catch::Matchers::WithinAbs; CadDocument doc; SketchProfile bot; @@ -6315,7 +6277,6 @@ TEST_CASE("mate conflicts: a broken mate is left to apply_mate", "[CadDocument][ TEST_CASE("ordering: fillet after mate resolves face ids", "[CadDocument][mate]") { - using Catch::Matchers::WithinAbs; CadDocument doc; int sk_a = doc.add_sketch(SketchShape::Rectangle, SketchPlane::XY(), 10, 10, 0, "BoxA"); @@ -7846,7 +7807,6 @@ TEST_CASE("plane_of_face gives a sketchable plane for a planar face only", "[Cad // that asserts a state the code cannot reach is exactly what the contract forbids. TEST_CASE("recompute on a healthy box + fillet leaves no body null and no error (positive contract)", "[CadDocument]") { - using namespace Slic3r; CadDocument doc; SketchProfile sp; sp.points.push_back(Vec2d(0, 0)); @@ -8758,7 +8718,6 @@ TEST_CASE("a body carries its own name, through recompute and the recipe", "[Cad TEST_CASE("deleting a feature remaps the references of every consumer, not just Extrude", "[CadDocument]") { - using namespace Slic3r; const SketchPlane xy = SketchPlane::XY(); // A rectangle 10x10 centred at v = 15, revolved 360 deg about the plane X axis. @@ -9098,7 +9057,6 @@ namespace { // centerline x = 0 from (0,0) to (0,20): the half-profile of a tube, drawn the usual way. Slic3r::CadFeature tube_half_profile() { - using namespace Slic3r; CadFeature sk; sk.type = CadFeatureType::Sketch; sk.plane = SketchPlane::XY(); @@ -9113,7 +9071,6 @@ Slic3r::CadFeature tube_half_profile() TEST_CASE("revolve about a line of the sketch", "[CadDocument][revolve]") { - using namespace Slic3r; SECTION("a construction centerline: the profile sweeps into a tube around it") { CadDocument doc; diff --git a/tests/libslic3r/test_config.cpp b/tests/libslic3r/test_config.cpp index e13070062f..553e94b1c0 100644 --- a/tests/libslic3r/test_config.cpp +++ b/tests/libslic3r/test_config.cpp @@ -16,7 +16,6 @@ #include #include -#include #include #include "libslic3r/Config.hpp" #include @@ -32,8 +31,6 @@ #include #include -namespace fs = boost::filesystem; - using namespace Slic3r; SCENARIO("Generic config validation performs as expected.", "[Config]") { diff --git a/tests/libslic3r/test_indexed_triangle_set.cpp b/tests/libslic3r/test_indexed_triangle_set.cpp index c65bf589a8..c6e5007c4b 100644 --- a/tests/libslic3r/test_indexed_triangle_set.cpp +++ b/tests/libslic3r/test_indexed_triangle_set.cpp @@ -19,7 +19,6 @@ using namespace Slic3r; TEST_CASE("Split empty mesh", "[its_split][its]") { - using namespace Slic3r; indexed_triangle_set its; @@ -29,7 +28,6 @@ TEST_CASE("Split empty mesh", "[its_split][its]") { } TEST_CASE("Split simple mesh consisting of one part", "[its_split][its]") { - using namespace Slic3r; auto cube = its_make_cube(10., 10., 10.); @@ -53,7 +51,6 @@ void debug_write_obj(const std::vector &res, const std::st } TEST_CASE("Split two non-watertight mesh", "[its_split][its]") { - using namespace Slic3r; auto cube1 = its_make_cube(10., 10., 10.); cube1.indices.pop_back(); @@ -76,7 +73,6 @@ TEST_CASE("Split two non-watertight mesh", "[its_split][its]") { } TEST_CASE("Split non-manifold mesh", "[its_split][its]") { - using namespace Slic3r; auto cube = its_make_cube(10., 10., 10.), cube_low = cube; @@ -96,7 +92,6 @@ TEST_CASE("Split non-manifold mesh", "[its_split][its]") { } TEST_CASE("Split two watertight meshes", "[its_split][its]") { - using namespace Slic3r; auto sphere1 = its_make_sphere(10., 2 * PI / 200.), sphere2 = sphere1; diff --git a/tests/libslic3r/test_marchingsquares.cpp b/tests/libslic3r/test_marchingsquares.cpp index dd6f5dbd97..55dac1e939 100644 --- a/tests/libslic3r/test_marchingsquares.cpp +++ b/tests/libslic3r/test_marchingsquares.cpp @@ -377,7 +377,6 @@ TEST_CASE("10x10 raster with two rings", "[MarchingSquares]") TEST_CASE("Square with hole in the middle", "[MarchingSquares]") { - using namespace Slic3r; ExPolygons inp = {square_with_hole(50.)}; @@ -434,7 +433,6 @@ TEST_CASE("Square with hole in the middle", "[MarchingSquares]") TEST_CASE("Circle with hole in the middle", "[MarchingSquares]") { - using namespace Slic3r; test_expolys(create_raster({1000, 1000}), circle_with_hole(25.), W1x1, "circle_with_hole"); } diff --git a/tests/libslic3r/test_timeutils.cpp b/tests/libslic3r/test_timeutils.cpp index 213b5e6788..9550740fa8 100644 --- a/tests/libslic3r/test_timeutils.cpp +++ b/tests/libslic3r/test_timeutils.cpp @@ -9,8 +9,6 @@ #include #include -using namespace Slic3r; - static void test_time_fmt(Slic3r::Utils::TimeFormat fmt) { using namespace Slic3r::Utils; time_t t = get_current_time_utc(); diff --git a/tests/libslic3r/test_voronoi.cpp b/tests/libslic3r/test_voronoi.cpp index b512fe38fe..a08b84d3eb 100644 --- a/tests/libslic3r/test_voronoi.cpp +++ b/tests/libslic3r/test_voronoi.cpp @@ -29,10 +29,6 @@ #include #endif -using boost::polygon::voronoi_builder; -using boost::polygon::voronoi_diagram; -using boost::polygon::construct_voronoi; - using namespace Slic3r; using VD = Geometry::VoronoiDiagram; diff --git a/tests/slic3rutils/test_plugin_sort.cpp b/tests/slic3rutils/test_plugin_sort.cpp index 8af2ce3b5b..2db7911436 100644 --- a/tests/slic3rutils/test_plugin_sort.cpp +++ b/tests/slic3rutils/test_plugin_sort.cpp @@ -13,9 +13,6 @@ using Slic3r::GUI::PluginSortKey; using Slic3r::GUI::PluginSortOrder; using Slic3r::GUI::PluginSource; using Slic3r::GUI::PluginStatus; -using Slic3r::GUI::plugin_sort_key_from_string; -using Slic3r::GUI::plugin_sort_order_from_string; -using Slic3r::GUI::sort_plugin_items_for_dialog; namespace { diff --git a/tests/slic3rutils/test_slicing_pipeline_bindings.cpp b/tests/slic3rutils/test_slicing_pipeline_bindings.cpp index bb29f6d607..d05589b552 100644 --- a/tests/slic3rutils/test_slicing_pipeline_bindings.cpp +++ b/tests/slic3rutils/test_slicing_pipeline_bindings.cpp @@ -144,7 +144,6 @@ TEST_CASE("orca.slicing is workflow-only: context exposes raw print/object; view } #include "libslic3r/PrintConfig.hpp" // DynamicPrintConfig for the psGCodePostProcess context -#include #include #include #include "libslic3r/BoundingBox.hpp" @@ -157,7 +156,6 @@ TEST_CASE("orca.slicing is workflow-only: context exposes raw print/object; view // the export path handed in. Exercising the real bindings by calling the Python execute() directly // (not the C++ audit trampoline) keeps this a pure binding-surface test. TEST_CASE("orca.slicing psGCodePostProcess context: file edit in place + config fallback", "[slicing_pipeline]") { - namespace fs = boost::filesystem; ensure_python_initialized(); import_orca_module(); py::gil_scoped_acquire gil; @@ -237,7 +235,6 @@ struct TestLayerRegion : Slic3r::LayerRegion { // decomposition of an ExtrusionLoop into its contained ExtrusionPath (flatten() // does NOT decompose loops, hence the hand-rolled recursive walk). static void build_nested_perimeters(TestLayerRegion& region) { - using namespace Slic3r; ExtrusionPath pathA(erExternalPerimeter); // -> "Outer wall" pathA.mm3_per_mm = 0.05; pathA.width = 0.45f; pathA.height = 0.20f; pathA.polyline.points = { Point3(0, 0, 0), Point3(10, 0, 0), Point3(10, 10, 0) }; @@ -434,7 +431,6 @@ namespace { // Nested collection: outer -> inner -> [ ExtrusionLoop(pathA), ExtrusionPath(pathB) ]. // Exercises polymorphic downcast of .entities and loop decomposition in flatten_paths(). static Slic3r::ExtrusionEntityCollection build_nested_collection() { - using namespace Slic3r; ExtrusionPath pathA(erExternalPerimeter); // -> "Outer wall" pathA.mm3_per_mm = 0.05; pathA.width = 0.45f; pathA.height = 0.20f; pathA.polyline.points = { Point3(0, 0, 0), Point3(10, 0, 0), Point3(10, 10, 0) };