diff --git a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp index ffb30f365..9385d9864 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.cpp @@ -35,6 +35,8 @@ #include #include +#include + #include #include // measure enumeration of fonts @@ -53,7 +55,6 @@ #define SHOW_FINE_POSITION #define SHOW_WX_WEIGHT_INPUT #define DRAW_PLACE_TO_ADD_TEXT -#define ALLOW_REVERT_ALL_STYLES #endif // ALLOW_DEBUG_MODE using namespace Slic3r; @@ -1313,6 +1314,7 @@ static std::string concat(std::vector data) { return ss.str(); } +#include static boost::filesystem::path get_fontlist_cache_path() { return boost::filesystem::path(data_dir()) / "cache" / "fonts.cereal"; @@ -1351,6 +1353,7 @@ template void serialize(Archive &ar, FacenamesSerializer &t, cons } CEREAL_CLASS_VERSION(FacenamesSerializer, FACENAMES_VERSION); // register class version +#include bool GLGizmoEmboss::store(const Facenames &facenames) { std::string cache_path = get_fontlist_cache_path().string(); boost::nowide::ofstream file(cache_path, std::ios::binary); @@ -2013,16 +2016,6 @@ void GLGizmoEmboss::draw_delete_style_button() { } } -void GLGizmoEmboss::draw_revert_all_styles_button() { - if (draw_button(IconType::revert_all)) { - m_style_manager = StyleManager(m_imgui->get_glyph_ranges()); - m_style_manager.init(nullptr, create_default_styles()); - assert(m_style_manager.get_font_file_with_cache().has_value()); - process(); - } else if (ImGui::IsItemHovered()) - ImGui::SetTooltip("%s", _u8L("Revert all styles").c_str()); -} - void GLGizmoEmboss::fix_transformation(const FontProp &from, const FontProp &to) { @@ -2166,11 +2159,6 @@ void GLGizmoEmboss::draw_style_list() { ImGui::SameLine(); draw_style_add_button(); - -#ifdef ALLOW_REVERT_ALL_STYLES - ImGui::SameLine(); - draw_revert_all_styles_button(); -#endif // ALLOW_REVERT_ALL_STYLES // delete button ImGui::SameLine(); @@ -3137,7 +3125,6 @@ void GLGizmoEmboss::init_icons() "make_unbold.svg", "search.svg", "open.svg", - "revert_all_.svg", "add_text_part.svg", "add_text_negative.svg", "add_text_modifier.svg" diff --git a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp index 9df7722e6..fecbeadaa 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoEmboss.hpp @@ -105,7 +105,6 @@ private: void fix_transformation(const FontProp &from, const FontProp &to); void draw_style_list(); void draw_delete_style_button(); - void draw_revert_all_styles_button(); void draw_style_rename_popup(); void draw_style_rename_button(); void draw_style_save_button(bool is_modified); @@ -323,7 +322,6 @@ private: unbold, system_selector, open_file, - revert_all, // VolumeType icons part, negative,