mirror of
https://github.com/QIDITECH/QIDISlicer.git
synced 2026-01-31 07:58:43 +03:00
Fix some bugs
This commit is contained in:
@@ -403,11 +403,12 @@ wxBitmapBundle* BitmapCache::from_svg(const std::string& bitmap_name, unsigned t
|
||||
return it->second;
|
||||
|
||||
// map of color replaces
|
||||
//B48
|
||||
std::map<std::string, std::string> replaces;
|
||||
if (dark_mode)
|
||||
replaces["#808080"] = "#FFFFFF";
|
||||
if (!new_color.empty())
|
||||
replaces["#ED6B21"] = new_color;
|
||||
replaces["#4479FB"] = new_color;
|
||||
|
||||
replaces["#ButtonBG"] = dark_mode ? "#4E4E4E" : "#828282";
|
||||
|
||||
@@ -461,11 +462,12 @@ wxBitmap* BitmapCache::load_svg(const std::string &bitmap_name, unsigned target_
|
||||
return it->second;
|
||||
|
||||
// map of color replaces
|
||||
//B48
|
||||
std::map<std::string, std::string> replaces;
|
||||
if (dark_mode)
|
||||
replaces["#808080"] = "#FFFFFF";
|
||||
if (!new_color.empty())
|
||||
replaces["#ED6B21"] = new_color;
|
||||
replaces["#4479FB"] = new_color;
|
||||
|
||||
NSVGimage *image = nsvgParseFromFileWithReplace(Slic3r::var(bitmap_name + ".svg").c_str(), "px", 96.0f, replaces);
|
||||
if (image == nullptr)
|
||||
|
||||
Reference in New Issue
Block a user