mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-10-23 00:31:11 -06:00
Another step towards the C++ presets.
This commit is contained in:
parent
ee645007f2
commit
5a99e694ce
11 changed files with 431 additions and 483 deletions
|
@ -1,6 +1,8 @@
|
|||
#ifndef slic3r_Utils_hpp_
|
||||
#define slic3r_Utils_hpp_
|
||||
|
||||
#include <locale>
|
||||
|
||||
namespace Slic3r {
|
||||
|
||||
extern void set_logging_level(unsigned int level);
|
||||
|
@ -23,6 +25,7 @@ std::string config_path(const std::string &file_name);
|
|||
// The suffix ".ini" will be added if it is missing in the name.
|
||||
std::string config_path(const std::string §ion, const std::string &name);
|
||||
|
||||
extern std::locale locale_utf8;
|
||||
extern std::string encode_path(const char *src);
|
||||
extern std::string decode_path(const char *src);
|
||||
extern std::string normalize_utf8_nfc(const char *src);
|
||||
|
|
|
@ -226,9 +226,10 @@ std::string decode_path(const char *src)
|
|||
#endif /* WIN32 */
|
||||
}
|
||||
|
||||
std::locale locale_utf8(boost::locale::generator().generate(""));
|
||||
|
||||
std::string normalize_utf8_nfc(const char *src)
|
||||
{
|
||||
static std::locale locale_utf8(boost::locale::generator().generate(""));
|
||||
return boost::locale::normalize(src, boost::locale::norm_nfc, locale_utf8);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue