#ifndef slic3r_SearchComboBox_hpp_ #define slic3r_SearchComboBox_hpp_ #include #include #include //#include #include #include #include #include "Preset.hpp" #include "wxExtensions.hpp" namespace Slic3r { namespace GUI { struct SearchInput { DynamicPrintConfig* config {nullptr}; Preset::Type type {Preset::TYPE_INVALID}; ConfigOptionMode mode {comSimple}; }; class SearchOptions { std::string search_line; public: struct Option { bool operator<(const Option& other) const { return other.label > this->label; } bool operator>(const Option& other) const { return other.label < this->label; } wxString label; std::string opt_key; wxString category; Preset::Type type {Preset::TYPE_INVALID}; // wxString grope; bool fuzzy_match_simple(char const *search_pattern) const; bool fuzzy_match_simple(const wxString& search) const; bool fuzzy_match_simple(const std::string &search) const; bool fuzzy_match(char const *search_pattern, int &outScore); bool fuzzy_match(const wxString &search, int &outScore); bool fuzzy_match(const std::string &search, int &outScore); }; std::vector