准备菜单下的工具栏位置修改。整体按钮颜色修改。Gcode连续路径修改。纤维进给率和普通打印速度暂时还原,方便测试
This commit is contained in:
parent
2df7bf7e09
commit
fb00d0ac0b
|
@ -209,6 +209,7 @@ std::string CalibPressureAdvance::draw_line(GCodeWriter &writer, Vec2d to_pt, do
|
|||
const double e_per_mm = CalibPressureAdvance::e_per_mm(line_width, layer_height, m_config.option<ConfigOptionFloats>("nozzle_diameter")->get_at(0),
|
||||
m_config.option<ConfigOptionFloats>("filament_diameter")->get_at(0),
|
||||
m_config.option<ConfigOptionFloats>("filament_flow_ratio")->get_at(0));
|
||||
//m_config.option<ConfigOptionFloats>("fibre_feed_rate")->get_at(0));
|
||||
|
||||
const double length = get_distance(Vec2d(m_last_pos.x(), m_last_pos.y()), to_pt);
|
||||
auto dE = e_per_mm * length;
|
||||
|
@ -556,6 +557,7 @@ void CalibPressureAdvancePattern::generate_custom_gcodes(const DynamicPrintConfi
|
|||
double number_e_per_mm = e_per_mm(line_width(), height_layer(), m_config.option<ConfigOptionFloats>("nozzle_diameter")->get_at(0),
|
||||
m_config.option<ConfigOptionFloats>("filament_diameter")->get_at(0),
|
||||
m_config.option<ConfigOptionFloats>("filament_flow_ratio")->get_at(0));
|
||||
//m_config.option<ConfigOptionFloats>("fibre_feed_rate")->get_at(0));
|
||||
|
||||
// glyph on every other line
|
||||
for (int j = 0; j < num_patterns; j += 2) {
|
||||
|
|
|
@ -134,6 +134,7 @@ double Extruder::filament_cost() const
|
|||
double Extruder::filament_flow_ratio() const
|
||||
{
|
||||
return m_config->filament_flow_ratio.get_at(m_id);
|
||||
//return m_config->fibre_feed_rate.get_at(m_id);
|
||||
}
|
||||
|
||||
// Return a "retract_before_wipe" percentage as a factor clamped to <0, 1>
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,49 @@
|
|||
#ifndef slic3r_FillLine_hpp_
|
||||
#define slic3r_FillLine_hpp_
|
||||
|
||||
#include "../libslic3r.h"
|
||||
|
||||
#include "FillBase.hpp"
|
||||
|
||||
namespace Slic3r {
|
||||
|
||||
class Surface;
|
||||
|
||||
class FillLine : public Fill
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillLine(*this); };
|
||||
~FillLine() override = default;
|
||||
|
||||
protected:
|
||||
void _fill_surface_single(
|
||||
const FillParams ¶ms,
|
||||
unsigned int thickness_layers,
|
||||
const std::pair<float, Point> &direction,
|
||||
ExPolygon expolygon,
|
||||
Polylines &polylines_out) override;
|
||||
|
||||
coord_t _min_spacing;
|
||||
coord_t _line_spacing;
|
||||
// distance threshold for allowing the horizontal infill lines to be connected into a continuous path
|
||||
coord_t _diagonal_distance;
|
||||
// only for line infill
|
||||
coord_t _line_oscillation;
|
||||
|
||||
Line _line(int i, coord_t x, coord_t y_min, coord_t y_max) const {
|
||||
coord_t osc = (i & 1) ? this->_line_oscillation : 0;
|
||||
return Line(Point(x - osc, y_min), Point(x + osc, y_max));
|
||||
}
|
||||
|
||||
bool _can_connect(coord_t dist_X, coord_t dist_Y)
|
||||
{
|
||||
const auto TOLERANCE = coord_t(10 * SCALED_EPSILON);
|
||||
return (dist_X >= (this->_line_spacing - this->_line_oscillation) - TOLERANCE)
|
||||
&& (dist_X <= (this->_line_spacing + this->_line_oscillation) + TOLERANCE)
|
||||
&& (dist_Y <= this->_diagonal_distance);
|
||||
}
|
||||
};
|
||||
|
||||
}; // namespace Slic3r
|
||||
|
||||
#endif // slic3r_FillLine_hpp_
|
|
@ -4103,7 +4103,7 @@ double GCode::get_path_speed(const ExtrusionPath &path)
|
|||
// cap speed with max_volumetric_speed anyway (even if user is not using autospeed)
|
||||
speed = std::min(speed, extrude_speed);
|
||||
}
|
||||
|
||||
//speed = m_config.get_abs_value("default_print_speed");
|
||||
return speed;
|
||||
}
|
||||
|
||||
|
@ -4113,10 +4113,15 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
// next copies (if any) would not detect the correct orientation
|
||||
|
||||
// extrude all loops ccw
|
||||
//获取一份副本;否则,不要修改原始循环对象的方向
|
||||
//下一个副本(如果有的话)无法检测到正确的方向
|
||||
//挤出所有循环ccw
|
||||
bool was_clockwise = loop.make_counter_clockwise();
|
||||
bool is_hole = loop.loop_role() == elrPerimeterHole;
|
||||
// find the point of the loop that is closest to the current extruder position
|
||||
// or randomize if requested
|
||||
//找到最接近当前挤出机位置的环路点
|
||||
//或根据要求随机化
|
||||
Point last_pos = this->last_pos();
|
||||
if (!m_config.spiral_mode && description == "perimeter") {
|
||||
assert(m_layer != nullptr);
|
||||
|
@ -4127,6 +4132,7 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
|
||||
const auto seam_scarf_type = m_config.seam_slope_type.value;
|
||||
// BBS: not apply on fist layer, too small E has stick issue with hotend plate
|
||||
//BBS:不适用于第一层,太小的E与热端板有粘连问题
|
||||
bool enable_seam_slope = ((seam_scarf_type == SeamScarfType::External && !is_hole) ||
|
||||
seam_scarf_type == SeamScarfType::All) &&
|
||||
!m_config.spiral_mode &&
|
||||
|
@ -4136,12 +4142,16 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
|
||||
if (enable_seam_slope && m_config.seam_slope_conditional.value) {
|
||||
//BBS: the seam has been decide, only check the seam position angle
|
||||
//BBS:接缝已确定,只检查接缝位置角度
|
||||
enable_seam_slope = loop.check_seam_point_angle(m_config.scarf_angle_threshold.value * M_PI / 180.0);
|
||||
}
|
||||
|
||||
// clip the path to avoid the extruder to get exactly on the first point of the loop;
|
||||
// if polyline was shorter than the clipping distance we'd get a null polyline, so
|
||||
// we discard it in that case
|
||||
//夹紧路径,避免挤出机精确地到达环路的第一点;
|
||||
//如果折线短于剪切距离,我们将得到一条空折线,因此
|
||||
//那样的话,我们就把它扔掉了
|
||||
const double seam_gap = scale_(EXTRUDER_CONFIG(nozzle_diameter)) * (m_config.seam_gap.value / 100);
|
||||
const double clip_length = m_enable_loop_clipping && !enable_seam_slope ? seam_gap : 0;
|
||||
// get paths
|
||||
|
@ -4151,29 +4161,35 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
|
||||
double small_peri_speed=-1;
|
||||
// apply the small perimeter speed
|
||||
//应用小圆周速度
|
||||
if (speed==-1 && loop.length() <= SMALL_PERIMETER_LENGTH(m_config.small_perimeter_threshold.value))
|
||||
small_peri_speed = m_config.small_perimeter_speed.get_abs_value(m_config.outer_wall_speed);
|
||||
|
||||
// extrude along the path
|
||||
//沿路径拉伸
|
||||
std::string gcode;
|
||||
bool is_small_peri=false;
|
||||
|
||||
const auto speed_for_path = [&speed, &small_peri_speed](const ExtrusionPath &path) {
|
||||
// don't apply small perimeter setting for overhangs/bridges/non-perimeters
|
||||
//不要对悬垂/桥梁/非周界应用小周界设置
|
||||
const bool is_small_peri = is_perimeter(path.role()) && !is_bridge(path.role()) && small_peri_speed > 0 &&
|
||||
(path.get_overhang_degree() == 0 || path.get_overhang_degree() > 5);
|
||||
return is_small_peri ? small_peri_speed : speed;
|
||||
};
|
||||
|
||||
//BBS: avoid overhang on conditional scarf mode
|
||||
//BBS:避免有条件围巾模式的悬垂
|
||||
bool slope_has_overhang = false;
|
||||
if (enable_seam_slope) {
|
||||
// Create seam slope
|
||||
//创建接缝坡度
|
||||
double start_slope_ratio;
|
||||
if (m_config.seam_slope_start_height.percent) {
|
||||
start_slope_ratio = m_config.seam_slope_start_height.value / 100.;
|
||||
} else {
|
||||
// Get the ratio against current layer height
|
||||
//获取与当前图层高度的比率
|
||||
double h = paths.front().height;
|
||||
start_slope_ratio = m_config.seam_slope_start_height.value / h;
|
||||
}
|
||||
|
@ -4187,19 +4203,25 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
const int slope_steps = m_config.seam_slope_steps;
|
||||
const double slope_max_segment_length = scale_(slope_min_length / slope_steps);
|
||||
// BBS: check if has overhang on slope path
|
||||
//BBS:检查斜坡路径上是否有悬垂物
|
||||
if (m_config.seam_slope_conditional.value)
|
||||
slope_has_overhang = has_overhang_path_on_slope(loop.paths, slope_min_length);
|
||||
if (!slope_has_overhang) {
|
||||
// Calculate the sloped loop
|
||||
//BBS: should has smaller e at start to get better seam
|
||||
//计算倾斜环路
|
||||
//BBS:开始时应该有较小的e,以获得更好的接缝
|
||||
ExtrusionLoopSloped new_loop(paths, seam_gap, slope_min_length, slope_max_segment_length, start_slope_ratio, loop.loop_role());
|
||||
|
||||
//BBS: clip end and start to get better seam
|
||||
//BBS:剪尾开始缝得更好
|
||||
new_loop.clip_slope(seam_gap);
|
||||
// BBS: slowdown speed to improve seam, to be fix, cooling need to be apply correctly
|
||||
//new_loop.target_speed = get_path_speed(new_loop.starts.back());
|
||||
//new_loop.slowdown_slope_speed();
|
||||
// BBS: smooth speed of discontinuity areas
|
||||
//BBS:放慢速度以改善接缝,需要修复,冷却需要正确应用
|
||||
//BBS:不连续区域的平滑速度
|
||||
if (m_config.detect_overhang_wall && m_config.smooth_speed_discontinuity_area && (loop.role() == erExternalPerimeter || loop.role() == erPerimeter))
|
||||
smooth_speed_discontinuity_area(new_loop.paths);
|
||||
// Then extrude it
|
||||
|
@ -4208,9 +4230,11 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
}
|
||||
|
||||
// Fix path for wipe
|
||||
//修复擦拭路径
|
||||
if (!new_loop.ends.empty()) {
|
||||
paths.clear();
|
||||
// The start slope part is ignored as it overlaps with the end part
|
||||
//起始坡度部分与结束部分重叠时将被忽略
|
||||
paths.reserve(new_loop.paths.size() + new_loop.ends.size());
|
||||
paths.insert(paths.end(), new_loop.paths.begin(), new_loop.paths.end());
|
||||
paths.insert(paths.end(), new_loop.ends.begin(), new_loop.ends.end());
|
||||
|
@ -4224,6 +4248,7 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
|
||||
if (!enable_seam_slope || slope_has_overhang) {
|
||||
// BBS: smooth speed of discontinuity areas
|
||||
//BBS:不连续区域的平滑速度
|
||||
if (m_config.detect_overhang_wall && m_config.smooth_speed_discontinuity_area && (loop.role() == erExternalPerimeter || loop.role() == erPerimeter))
|
||||
smooth_speed_discontinuity_area(paths);
|
||||
|
||||
|
@ -4233,8 +4258,10 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
}
|
||||
|
||||
//BBS: don't reset acceleration when printing first layer. During first layer, acceleration is always same value.
|
||||
//BBS:打印第一层时不要重置加速。在第一层,加速度总是相同的值。
|
||||
if (!this->on_first_layer()) {
|
||||
// reset acceleration
|
||||
//重置加速度
|
||||
gcode += m_writer.set_acceleration((unsigned int) (m_config.default_acceleration.value + 0.5));
|
||||
if (!this->is_BBL_Printer())
|
||||
gcode += m_writer.set_jerk_xy(m_config.default_jerk.value);
|
||||
|
@ -4246,6 +4273,7 @@ std::string GCode::extrude_loop(ExtrusionLoop loop, std::string description, dou
|
|||
m_wipe.path = Polyline();
|
||||
for (ExtrusionPath &path : paths) {
|
||||
//BBS: Don't need to save duplicated point into wipe path
|
||||
//BBS:不需要将重复点保存到擦除路径中
|
||||
if (!m_wipe.path.empty() && !path.empty() &&
|
||||
m_wipe.path.last_point() == path.first_point())
|
||||
m_wipe.path.append(path.polyline.points.begin() + 1, path.polyline.points.end());
|
||||
|
@ -4789,25 +4817,34 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
// go to first point of extrusion path
|
||||
//BBS: path.first_point is 2D point. But in lazy raise case, lift z is done in travel_to function.
|
||||
//Add m_need_change_layer_lift_z when change_layer in case of no lift if m_last_pos is equal to path.first_point() by chance
|
||||
//转到挤出路径的第一点
|
||||
//BBS:path.first_point是二维点。但在懒惰提升的情况下,提升z是在travel_to函数中完成的。
|
||||
//如果m_last_pos偶然等于path.first_point(),则在没有提升的情况下,在change_layer时添加m_need_change_layer_lift_z
|
||||
if (!m_last_pos_defined || m_last_pos != path.first_point() || m_need_change_layer_lift_z || (sloped != nullptr && !sloped->is_flat())) {
|
||||
gcode += this->travel_to(
|
||||
path.first_point(),
|
||||
path.role(),
|
||||
"move to first " + description + " point",
|
||||
sloped == nullptr ? DBL_MAX : get_sloped_z(sloped->slope_begin.z_ratio)
|
||||
|
||||
);
|
||||
//gcode += m_writer.extrude_to_xy(this->point_to_gcode(line.b),e_per_mm * line_length,comment);
|
||||
m_need_change_layer_lift_z = false;
|
||||
}
|
||||
|
||||
// if needed, write the gcode_label_objects_end then gcode_label_objects_start
|
||||
// should be already done by travel_to, but just in case
|
||||
//如果需要,编写gcode_label_objects_end,然后编写gcode-label_objects/start
|
||||
//应该已经通过travel-to完成了,但以防万一
|
||||
m_writer.add_object_change_labels(gcode);
|
||||
|
||||
// compensate retraction
|
||||
//补偿回缩
|
||||
gcode += this->unretract();
|
||||
m_config.apply(m_calib_config);
|
||||
|
||||
// adjust acceleration
|
||||
//调整加速度
|
||||
if (m_config.default_acceleration.value > 0) {
|
||||
double acceleration;
|
||||
if (this->on_first_layer() && m_config.initial_layer_acceleration.value > 0) {
|
||||
|
@ -4821,6 +4858,8 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
} else if (m_config.outer_wall_acceleration.value > 0
|
||||
//BBS: FIXME, in fact,we only need to set acceleration for outer wall. But we don't know
|
||||
//whether the overhang perimeter is outer or not. So using specific acceleration together.
|
||||
//BBS:FIXME,事实上,我们只需要为外墙设置加速度。但我们不知道
|
||||
//无论悬垂周界是否在外部。所以一起使用特定的加速度。
|
||||
&& (path.role() == erExternalPerimeter || path.role() == erOverhangPerimeter)) {
|
||||
acceleration = m_config.outer_wall_acceleration.value;
|
||||
} else if (m_config.top_surface_acceleration.value > 0 && is_top_surface(path.role())) {
|
||||
|
@ -4851,9 +4890,11 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
gcode += m_writer.set_jerk_xy(jerk);
|
||||
}
|
||||
// calculate extrusion length per distance unit
|
||||
//计算每距离单位的挤出长度
|
||||
auto _mm3_per_mm = path.mm3_per_mm * double(m_curr_print->calib_mode() == CalibMode::Calib_Flow_Rate ? this->config().print_flow_ratio.value : 1);
|
||||
|
||||
// calculate extrusion length per distance unit
|
||||
//计算每距离单位的挤出长度
|
||||
if( path.role() == erTopSolidInfill )
|
||||
_mm3_per_mm *= m_config.top_solid_infill_flow_ratio.value;
|
||||
else if (this->on_first_layer())
|
||||
|
@ -4910,6 +4951,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
}
|
||||
}
|
||||
//BBS: if not set the speed, then use the filament_max_volumetric_speed directly
|
||||
//BBS:如果不设置速度,则直接使用film_max_volumetric_speed
|
||||
if( speed == 0 )
|
||||
{
|
||||
if (_mm3_per_mm>0)
|
||||
|
@ -4920,6 +4962,8 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
if (this->on_first_layer()) {
|
||||
//BBS: for solid infill of initial layer, speed can be higher as long as
|
||||
//wall lines have be attached
|
||||
//BBS:对于初始层的固体填充,速度可以更高,只要
|
||||
//已附加墙线
|
||||
if (path.role() != erBottomSurface)
|
||||
speed = m_config.get_abs_value("initial_layer_speed");
|
||||
}
|
||||
|
@ -4939,11 +4983,13 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
extrude_speed = EXTRUDER_CONFIG(filament_max_volumetric_speed) / _mm3_per_mm;
|
||||
|
||||
// cap speed with max_volumetric_speed anyway (even if user is not using autospeed)
|
||||
//无论如何,使用max_volumetric_speed限制速度(即使用户没有使用autospeed)
|
||||
speed = std::min(speed, extrude_speed);
|
||||
}
|
||||
double F = speed * 60; // convert mm/sec to mm/min
|
||||
|
||||
// extrude arc or line
|
||||
//拉伸圆弧或直线
|
||||
if (m_enable_extrusion_role_markers)
|
||||
{
|
||||
if (path.role() != m_last_extrusion_role)
|
||||
|
@ -4961,6 +5007,9 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
// adds processor tags and updates processor tracking data
|
||||
// PrusaMultiMaterial::Writer may generate GCodeProcessor::Height_Tag lines without updating m_last_height
|
||||
// so, if the last role was erWipeTower we force export of GCodeProcessor::Height_Tag lines
|
||||
//添加处理器标签并更新处理器跟踪数据
|
||||
//PrusaMultiMaterial::编写器可能生成GCodeProcessor::Height_Tag行,而不更新m_last_Height
|
||||
//因此,如果最后一个角色是erWipeTower,我们强制导出GCodeProcessor::Height_Tag行
|
||||
bool last_was_wipe_tower = (m_last_processor_extrusion_role == erWipeTower);
|
||||
char buf[64];
|
||||
assert(is_decimal_separator_point());
|
||||
|
@ -4995,6 +5044,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
if (m_enable_cooling_markers) {
|
||||
if (EXTRUDER_CONFIG(enable_overhang_bridge_fan)) {
|
||||
//BBS: Overhang_threshold_none means Overhang_threshold_1_4 and forcing cooling for all external perimeter
|
||||
//BBS:Overhang_threshold _none表示Overhang_tthreshold _1_4,并强制冷却所有外部周边
|
||||
int overhang_threshold = EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none ?
|
||||
Overhang_threshold_none : EXTRUDER_CONFIG(overhang_fan_threshold) - 1;
|
||||
if ((EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none && path.role() == erExternalPerimeter)) {
|
||||
|
@ -5023,6 +5073,8 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
std::string comment = GCodeWriter::full_gcode_comment ? description : "";
|
||||
//BBS: use G1 if not enable arc fitting or has no arc fitting result or in spiral_mode mode
|
||||
//Attention: G2 and G3 is not supported in spiral_mode mode
|
||||
//BBS:如果未启用圆弧拟合或没有圆弧拟合结果或处于spiral_mode模式,则使用G1
|
||||
//注意:在spiral_mode模式下不支持G2和G3
|
||||
if (!m_config.enable_arc_fitting ||
|
||||
path.polyline.fitting_result.empty() ||
|
||||
m_config.spiral_mode ||
|
||||
|
@ -5032,6 +5084,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
for (const Line &line : path.polyline.lines()) {
|
||||
const double line_length = line.length() * SCALING_FACTOR;
|
||||
// BBS: extursion cmd should E0 on cmd line
|
||||
//BBS:扩展cmd应该在cmd行上显示E0
|
||||
if (line_length < EPSILON) continue;
|
||||
path_length += line_length;
|
||||
|
||||
|
@ -5042,19 +5095,23 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
comment);
|
||||
} else {
|
||||
// Sloped extrusion
|
||||
//倾斜挤压
|
||||
auto dE = e_per_mm * line_length;
|
||||
auto [z_ratio, e_ratio, slope_speed] = sloped->interpolate(path_length / total_length);
|
||||
//FIX: cooling need to apply correctly
|
||||
//修复:冷却需要正确应用
|
||||
//gcode += m_writer.set_speed(slope_speed * 60, "", comment);
|
||||
Vec2d dest2d = this->point_to_gcode(line.b);
|
||||
Vec3d dest3d(dest2d(0), dest2d(1), get_sloped_z(z_ratio));
|
||||
//BBS: todo, should use small e at start to get good seam
|
||||
//BBS:todo,应该在开始时使用小e来获得良好的接缝
|
||||
double slope_e = dE * e_ratio;
|
||||
gcode += m_writer.extrude_to_xyz(dest3d, slope_e);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// BBS: start to generate gcode from arc fitting data which includes line and arc
|
||||
//BBS:开始从包括直线和圆弧的圆弧拟合数据生成gcode
|
||||
const std::vector<PathFittingData>& fitting_result = path.polyline.fitting_result;
|
||||
for (size_t fitting_index = 0; fitting_index < fitting_result.size(); fitting_index++) {
|
||||
switch (fitting_result[fitting_index].path_type) {
|
||||
|
@ -5065,6 +5122,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
const Line line = Line(path.polyline.points[point_index - 1], path.polyline.points[point_index]);
|
||||
const double line_length = line.length() * SCALING_FACTOR;
|
||||
// BBS: extursion cmd should E0 on cmd line
|
||||
//BBS:扩展cmd应该在cmd行上显示E0
|
||||
if (line_length < EPSILON)
|
||||
continue;
|
||||
path_length += line_length;
|
||||
|
@ -5080,6 +5138,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
const ArcSegment& arc = fitting_result[fitting_index].arc_data;
|
||||
const double arc_length = fitting_result[fitting_index].arc_data.length * SCALING_FACTOR;
|
||||
// BBS: extursion cmd should E0 on cmd line
|
||||
//BBS:扩展cmd应该在cmd行上显示E0
|
||||
if (arc_length < EPSILON)
|
||||
continue;
|
||||
const Vec2d center_offset = this->point_to_gcode(arc.center) - this->point_to_gcode(arc.start_point);
|
||||
|
@ -5094,6 +5153,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
}
|
||||
default:
|
||||
//BBS: should never happen that a empty path_type has been stored
|
||||
//BBS:不应该出现存储了空path_type的情况
|
||||
assert(0);
|
||||
break;
|
||||
}
|
||||
|
@ -5103,6 +5163,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
|||
if (m_enable_cooling_markers) {
|
||||
if (EXTRUDER_CONFIG(enable_overhang_bridge_fan)) {
|
||||
//BBS: Overhang_threshold_none means Overhang_threshold_1_4 and forcing cooling for all external perimeter
|
||||
//BBS:Overhang_threshold _none表示Overhang_tthreshold _1_4,并强制冷却所有外部周边
|
||||
int overhang_threshold = EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none ?
|
||||
Overhang_threshold_none : EXTRUDER_CONFIG(overhang_fan_threshold) - 1;
|
||||
if ((EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none && path.role() == erExternalPerimeter)) {
|
||||
|
@ -5156,38 +5217,52 @@ std::string GCode::_encode_label_ids_to_base64(std::vector<size_t> ids)
|
|||
}
|
||||
|
||||
// This method accepts &point in print coordinates.
|
||||
//此方法接受打印坐标中的&point。
|
||||
std::string GCode::travel_to(const Point &point, ExtrusionRole role, std::string comment, double z )
|
||||
{
|
||||
/* Define the travel move as a line between current position and the taget point.
|
||||
This is expressed in print coordinates, so it will need to be translated by
|
||||
this->origin in order to get G-code coordinates. */
|
||||
/*将行程移动定义为当前位置和标记点之间的线。
|
||||
这是以打印坐标表示的,因此需要转换为
|
||||
此->原点,以获得G代码坐标*/
|
||||
Polyline travel { this->last_pos(), point };
|
||||
|
||||
// check whether a straight travel move would need retraction
|
||||
//检查直线移动是否需要缩回
|
||||
LiftType lift_type = LiftType::SpiralLift;
|
||||
bool needs_retraction = this->needs_retraction(travel, role, lift_type);
|
||||
// check whether wipe could be disabled without causing visible stringing
|
||||
//检查是否可以在不造成可见串接的情况下禁用擦拭
|
||||
bool could_be_wipe_disabled = false;
|
||||
// Save state of use_external_mp_once for the case that will be needed to call twice m_avoid_crossing_perimeters.travel_to.
|
||||
//为需要调用两次m_avoid_crossing_perimeters.travel_to的情况保存use_external_mp_once的状态。
|
||||
const bool used_external_mp_once = m_avoid_crossing_perimeters.used_external_mp_once();
|
||||
|
||||
// if a retraction would be needed, try to use reduce_crossing_wall to plan a
|
||||
// multi-hop travel path inside the configuration space
|
||||
//如果需要撤回,请尝试使用reduce_crossing_wall来计划
|
||||
//配置空间内的多跳行进路径
|
||||
if (needs_retraction
|
||||
&& m_config.reduce_crossing_wall
|
||||
&& ! m_avoid_crossing_perimeters.disabled_once()
|
||||
//BBS: don't generate detour travel paths when current position is unclear
|
||||
//BBS:当前位置不清楚时,不要生成绕行行驶路径
|
||||
&& m_writer.is_current_position_clear()) {
|
||||
travel = m_avoid_crossing_perimeters.travel_to(*this, point, &could_be_wipe_disabled);
|
||||
// check again whether the new travel path still needs a retraction
|
||||
//再次检查新的行进路径是否仍需要缩回
|
||||
needs_retraction = this->needs_retraction(travel, role, lift_type);
|
||||
//if (needs_retraction && m_layer_index > 1) exit(0);
|
||||
//如果(needs_reduction&&mlayer_index>1)退出(0);
|
||||
}
|
||||
|
||||
// Re-allow reduce_crossing_wall for the next travel moves
|
||||
//重新允许reduce_crossing_wall用于下一次行程移动
|
||||
m_avoid_crossing_perimeters.reset_once_modifiers();
|
||||
|
||||
// generate G-code for the travel move
|
||||
//为行程生成G代码
|
||||
std::string gcode;
|
||||
if (needs_retraction) {
|
||||
if (m_config.reduce_crossing_wall && could_be_wipe_disabled)
|
||||
|
@ -5198,23 +5273,31 @@ std::string GCode::travel_to(const Point &point, ExtrusionRole role, std::string
|
|||
// When "Wipe while retracting" is enabled, then extruder moves to another position, and travel from this position can cross perimeters.
|
||||
// Because of it, it is necessary to call avoid crossing perimeters again with new starting point after calling retraction()
|
||||
// FIXME Lukas H.: Try to predict if this second calling of avoid crossing perimeters will be needed or not. It could save computations.
|
||||
//当启用“缩回时擦拭”时,挤出机会移动到另一个位置,从这个位置开始移动可以穿过周边。
|
||||
//因此,在调用retraction()后,有必要使用新的起点再次调用避免跨越边界
|
||||
//FIXME Lukas H.:试着预测是否需要第二次呼吁避免穿越边界。它可以节省计算。
|
||||
if (last_post_before_retract != this->last_pos() && m_config.reduce_crossing_wall) {
|
||||
// If in the previous call of m_avoid_crossing_perimeters.travel_to was use_external_mp_once set to true restore this value for next call.
|
||||
//如果在上一次调用m_avoid_crossing_perimeters.travel_to时,use_external_mp_once设置为true,则在下次调用时恢复此值。
|
||||
if (used_external_mp_once)
|
||||
m_avoid_crossing_perimeters.use_external_mp_once();
|
||||
travel = m_avoid_crossing_perimeters.travel_to(*this, point);
|
||||
// If state of use_external_mp_once was changed reset it to right value.
|
||||
//如果use_external_mp_once的状态被更改,则将其重置为正确的值。
|
||||
if (used_external_mp_once)
|
||||
m_avoid_crossing_perimeters.reset_once_modifiers();
|
||||
}
|
||||
} else
|
||||
// Reset the wipe path when traveling, so one would not wipe along an old path.
|
||||
//行驶时重置擦拭路径,这样就不会沿着旧路径擦拭。
|
||||
m_wipe.reset_path();
|
||||
|
||||
// if needed, write the gcode_label_objects_end then gcode_label_objects_start
|
||||
//如果需要,编写gcode_label_objects_end,然后编写gcode-label_objects/start
|
||||
m_writer.add_object_change_labels(gcode);
|
||||
|
||||
// use G1 because we rely on paths being straight (G0 may make round paths)
|
||||
//使用G1,因为我们依赖于直线路径(G0可能会形成圆形路径)
|
||||
if (travel.size() >= 2) {
|
||||
// OrcaSlicer
|
||||
if (this->on_first_layer()) {
|
||||
|
@ -5225,30 +5308,39 @@ std::string GCode::travel_to(const Point &point, ExtrusionRole role, std::string
|
|||
|
||||
if (m_spiral_vase) {
|
||||
// No lazy z lift for spiral vase mode
|
||||
//螺旋花瓶模式没有懒惰的z型升降机
|
||||
for (size_t i = 1; i < travel.size(); ++i)
|
||||
gcode += m_writer.travel_to_xy(this->point_to_gcode(travel.points[i]), comment);
|
||||
} else {
|
||||
if (travel.size() == 2) {
|
||||
// No extra movements emitted by avoid_crossing_perimeters, simply move to the end point with z change
|
||||
//avoid_crossing_perimeters不会发出额外的移动,只需移动到z变化的终点即可
|
||||
const auto &dest2d = this->point_to_gcode(travel.points.back());
|
||||
Vec3d dest3d(dest2d(0), dest2d(1), z == DBL_MAX ? m_nominal_z : z);
|
||||
//zheli****************************************************************************
|
||||
//*******************************************************************************
|
||||
//auto dE = m_extruder->E();
|
||||
gcode += m_writer.travel_to_xyz(dest3d, comment);
|
||||
} else {
|
||||
// Extra movements emitted by avoid_crossing_perimeters, lift the z to normal height at the beginning, then apply the z
|
||||
// ratio at the last point
|
||||
//avoid_crossing_perimeters发出的额外运动,在开始时将z提升到正常高度,然后在最后一点应用z比率
|
||||
for (size_t i = 1; i < travel.size(); ++i) {
|
||||
if (i == 1) {
|
||||
// Lift to normal z at beginning
|
||||
//开始时提升到正常z
|
||||
Vec2d dest2d = this->point_to_gcode(travel.points[i]);
|
||||
Vec3d dest3d(dest2d(0), dest2d(1), m_nominal_z);
|
||||
gcode += m_writer.travel_to_xyz(dest3d, comment);
|
||||
} else if (z != DBL_MAX && i == travel.size() - 1) {
|
||||
// Apply z_ratio for the very last point
|
||||
//将z_ratio应用于最后一点
|
||||
Vec2d dest2d = this->point_to_gcode(travel.points[i]);
|
||||
Vec3d dest3d(dest2d(0), dest2d(1), z);
|
||||
gcode += m_writer.travel_to_xyz(dest3d, comment);
|
||||
} else {
|
||||
// For all points in between, no z change
|
||||
//对于介于两者之间的所有点,z不变
|
||||
gcode += m_writer.travel_to_xy(this->point_to_gcode(travel.points[i]), comment );
|
||||
}
|
||||
}
|
||||
|
|
|
@ -345,6 +345,28 @@ std::string GCodeWriter::travel_to_xy(const Vec2d &point, const std::string &com
|
|||
return w.string();
|
||||
}
|
||||
|
||||
std::string GCodeWriter::travel_to_xy_test(const Vec2d& point, const std::string& comment)
|
||||
{
|
||||
m_pos(0) = point(0);
|
||||
m_pos(1) = point(1);
|
||||
|
||||
this->set_current_position_clear(true);
|
||||
//BBS: take plate offset into consider
|
||||
Vec2d point_on_plate = { point(0) - m_x_offset, point(1) - m_y_offset };
|
||||
|
||||
GCodeG1Formatter w;
|
||||
w.emit_xy(point_on_plate);
|
||||
w.emit_f(this->config.travel_speed.value * 60.0);
|
||||
//double dE = 3.6919824438491271030063717038767;
|
||||
auto dE = m_extruder->E();
|
||||
if (dE > 0) {
|
||||
w.emit_e(dE);
|
||||
}
|
||||
//BBS
|
||||
w.emit_comment(GCodeWriter::full_gcode_comment, comment);
|
||||
return w.string();
|
||||
}
|
||||
|
||||
std::string GCodeWriter::travel_to_xyz(const Vec3d &point, const std::string &comment)
|
||||
{
|
||||
// FIXME: This function was not being used when travel_speed_z was separated (bd6badf).
|
||||
|
@ -357,6 +379,7 @@ std::string GCodeWriter::travel_to_xyz(const Vec3d &point, const std::string &co
|
|||
adjust the nominal Z by reducing the lift amount that will be
|
||||
used for unlift. */
|
||||
// BBS
|
||||
/*如果目标Z低于当前Z但高于标称Z,我们不会执行Z移动,而只会在XY平面内移动,并通过减少用于未点火的升程量来调整标称Z*/
|
||||
Vec3d dest_point = point;
|
||||
//BBS: a z_hop need to be handle when travel
|
||||
if (std::abs(m_to_lift) > EPSILON) {
|
||||
|
@ -364,6 +387,8 @@ std::string GCodeWriter::travel_to_xyz(const Vec3d &point, const std::string &co
|
|||
//BBS: don't need to do real lift if the current position is absolutely same with target.
|
||||
//This ususally happens when the last extrusion line is short and the end of wipe position
|
||||
//is same with the traget point by chance.
|
||||
//BBS:如果当前位置与目标完全相同,则不需要进行真正的提升。
|
||||
//这通常发生在最后一条挤出线较短,擦拭位置的末端偶然与托盘点相同的情况下。
|
||||
if ((!this->is_current_position_clear() || m_pos != dest_point) &&
|
||||
m_to_lift + m_pos(2) > point(2)) {
|
||||
m_lifted = m_to_lift + m_pos(2) - point(2);
|
||||
|
@ -373,16 +398,20 @@ std::string GCodeWriter::travel_to_xyz(const Vec3d &point, const std::string &co
|
|||
|
||||
std::string slop_move;
|
||||
//BBS: minus plate offset
|
||||
//BBS:负板偏移
|
||||
Vec3d source = { m_pos(0) - m_x_offset, m_pos(1) - m_y_offset, m_pos(2) };
|
||||
Vec3d target = { dest_point(0) - m_x_offset, dest_point(1) - m_y_offset, dest_point(2) };
|
||||
Vec3d delta = target - source;
|
||||
Vec2d delta_no_z = { delta(0), delta(1) };
|
||||
//BBS: don'need slope travel because we don't know where is the source position the first time
|
||||
//BBS: Also don't need to do slope move or spiral lift if x-y distance is absolute zero
|
||||
//BBS:不需要斜坡旅行,因为我们第一次不知道震源位置在哪里
|
||||
//BBS:如果x-y距离为绝对零,也不需要进行斜坡移动或螺旋升降
|
||||
if (delta(2) > 0 && delta_no_z.norm() != 0.0f) {
|
||||
//BBS: SpiralLift
|
||||
if (m_to_lift_type == LiftType::SpiralLift && this->is_current_position_clear()) {
|
||||
//BBS: todo: check the arc move all in bed area, if not, then use lazy lift
|
||||
//BBS:todo:检查床区的弧形移动,如果没有,则使用LazyLift
|
||||
double radius = delta(2) / (2 * PI * atan(GCodeWriter::slope_threshold));
|
||||
Vec2d ij_offset = radius * delta_no_z.normalized();
|
||||
ij_offset = { -ij_offset(1), ij_offset(0) };
|
||||
|
@ -434,19 +463,23 @@ std::string GCodeWriter::travel_to_xyz(const Vec3d &point, const std::string &co
|
|||
m_lifted -= (point(2) - nominal_z);
|
||||
// In case that z_hop == layer_height we could end up with almost zero in_m_lifted
|
||||
// and a retract could be skipped
|
||||
//如果z_hop==layer_height,我们最终可能会得到几乎为零的In_m_leed,并且可以跳过收回操作
|
||||
if (std::abs(m_lifted) < EPSILON)
|
||||
m_lifted = 0.;
|
||||
//BBS
|
||||
this->set_current_position_clear(true);
|
||||
return this->travel_to_xy(to_2d(point));
|
||||
//return this->travel_to_xy(to_2d(point));
|
||||
return this->travel_to_xy_test(to_2d(point));
|
||||
}
|
||||
else {
|
||||
/* In all the other cases, we perform an actual XYZ move and cancel
|
||||
the lift. */
|
||||
/*在所有其他情况下,我们执行实际的XYZ移动并取消提升*/
|
||||
m_lifted = 0;
|
||||
}
|
||||
|
||||
//BBS: take plate offset into consider
|
||||
//BBS:考虑板材偏移
|
||||
Vec3d point_on_plate = { dest_point(0) - m_x_offset, dest_point(1) - m_y_offset, dest_point(2) };
|
||||
std::string out_string;
|
||||
GCodeG1Formatter w;
|
||||
|
|
|
@ -67,6 +67,7 @@ public:
|
|||
std::string toolchange(unsigned int extruder_id);
|
||||
std::string set_speed(double F, const std::string &comment = std::string(), const std::string &cooling_marker = std::string()) const;
|
||||
std::string travel_to_xy(const Vec2d &point, const std::string &comment = std::string());
|
||||
std::string travel_to_xy_test(const Vec2d &point, const std::string &comment = std::string());
|
||||
std::string travel_to_xyz(const Vec3d &point, const std::string &comment = std::string());
|
||||
std::string travel_to_z(double z, const std::string &comment = std::string());
|
||||
bool will_move_z(double z) const;
|
||||
|
|
|
@ -1867,15 +1867,15 @@ void PrintConfigDef::init_fff_params()
|
|||
def->mode = comSimple;
|
||||
def->set_default_value(new ConfigOptionFloat(0.3));
|
||||
|
||||
def = this->add("fibre_feed_rate", coFloat);
|
||||
def = this->add("fibre_feed_rate", coFloats);
|
||||
def->label = L("Fibre feed rate");
|
||||
def->category = L("Others");
|
||||
//def->tooltip = L("The width within which to jitter. It's adversed to be below outer wall line width");
|
||||
def->sidetext = L("mm");
|
||||
//def->sidetext = L("mm");
|
||||
def->min = 0;
|
||||
def->max = 1;
|
||||
def->max = 2;
|
||||
def->mode = comSimple;
|
||||
def->set_default_value(new ConfigOptionFloat(0.3));
|
||||
def->set_default_value(new ConfigOptionFloats{ 1. });
|
||||
|
||||
def = this->add("fuzzy_skin_point_distance", coFloat);
|
||||
def->label = L("Fuzzy skin point distance");
|
||||
|
|
|
@ -895,6 +895,7 @@ PRINT_CONFIG_CLASS_DEFINE(
|
|||
((ConfigOptionString, machine_end_gcode))
|
||||
((ConfigOptionStrings, filament_end_gcode))
|
||||
((ConfigOptionFloats, filament_flow_ratio))
|
||||
((ConfigOptionFloats, fibre_feed_rate))
|
||||
((ConfigOptionBools, enable_pressure_advance))
|
||||
((ConfigOptionFloats, pressure_advance))
|
||||
((ConfigOptionFloats, filament_diameter))
|
||||
|
|
|
@ -249,6 +249,9 @@ void PrintObject::prepare_infill()
|
|||
// The preceding step (perimeter generator) only modifies extra_perimeters and the extra perimeters are only used by discover_vertical_shells()
|
||||
// with more than a single region. If this step does not use Surface::extra_perimeters or Surface::extra_perimeters is always zero, it is safe
|
||||
// to reset to the untyped slices before re-runnning detect_surfaces_type().
|
||||
//为了在重新切片(使用类型化切片)时提高detect_surfaces_type()的鲁棒性,请参阅GH问题#7442。
|
||||
//前面的步骤(周长生成器)仅修改extra_perimeters,并且额外的周长仅由具有多个区域的discover_vertical_shell()使用。
|
||||
//如果此步骤不使用Surface::extra_perimeters或Surface::extra_perimeter始终为零,则可以在重新运行detect_surfaces_type()之前重置为非类型切片。
|
||||
for (Layer* layer : m_layers) {
|
||||
layer->restore_untyped_slices_no_extra_perimeters();
|
||||
m_print->throw_if_canceled();
|
||||
|
@ -1900,6 +1903,7 @@ void PrintObject::bridge_over_infill()
|
|||
#else
|
||||
// This method applies bridge flow to the first internal solid layer above sparse infill.
|
||||
// This method applies bridge flow to the first internal solid layer above sparse infill.
|
||||
//该方法将桥流应用于稀疏填充物上方的第一个内部固体层。
|
||||
void PrintObject::bridge_over_infill()
|
||||
{
|
||||
BOOST_LOG_TRIVIAL(info) << "Bridge over infill - Start" << log_memory_info();
|
||||
|
|
|
@ -44,9 +44,11 @@ void AMSMaterialsSetting::create()
|
|||
|
||||
m_button_confirm = new Button(this, _L("Confirm"));
|
||||
m_btn_bg_green = StateColor(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_confirm->SetBackgroundColor(m_btn_bg_green);
|
||||
m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_button_confirm->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_button_confirm->SetTextColor(wxColour("#FFFFFE"));
|
||||
m_button_confirm->SetMinSize(AMS_MATERIALS_SETTING_BUTTON_SIZE);
|
||||
m_button_confirm->SetCornerRadius(FromDIP(12));
|
||||
|
@ -147,7 +149,8 @@ void AMSMaterialsSetting::create_panel_normal(wxWindow* parent)
|
|||
m_sizer_filament->Add(m_comboBox_filament, 1, wxALIGN_CENTER, 0);
|
||||
|
||||
m_readonly_filament = new TextInput(parent, wxEmptyString, "", "", wxDefaultPosition, AMS_MATERIALS_SETTING_COMBOX_WIDTH, wxTE_READONLY | wxRIGHT);
|
||||
m_readonly_filament->SetBorderColor(StateColor(std::make_pair(0xDBDBDB, (int)StateColor::Focused), std::make_pair(0x00AE42, (int)StateColor::Hovered),
|
||||
//m_readonly_filament->SetBorderColor(StateColor(std::make_pair(0xDBDBDB, (int)StateColor::Focused), std::make_pair(0x00AE42, (int)StateColor::Hovered),
|
||||
m_readonly_filament->SetBorderColor(StateColor(std::make_pair(0xDBDBDB, (int)StateColor::Focused), std::make_pair(0x215F9A, (int)StateColor::Hovered),
|
||||
std::make_pair(0xDBDBDB, (int)StateColor::Normal)));
|
||||
m_readonly_filament->SetFont(::Label::Body_14);
|
||||
m_readonly_filament->SetLabelColor(AMS_MATERIALS_SETTING_GREY800);
|
||||
|
@ -1051,7 +1054,8 @@ void AMSMaterialsSetting::on_select_filament(wxCommandEvent &evt)
|
|||
}
|
||||
else {
|
||||
m_button_confirm->SetBackgroundColor(m_btn_bg_green);
|
||||
m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_button_confirm->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_button_confirm->SetTextColor(wxColour("#FFFFFE"));
|
||||
m_button_confirm->Enable(true);
|
||||
}
|
||||
|
|
|
@ -1283,7 +1283,8 @@ void AmsReplaceMaterialDialog::create()
|
|||
|
||||
auto label_title = new Label(this, _L("Auto Refill"));
|
||||
label_title->SetFont(Label::Head_14);
|
||||
label_title->SetForegroundColour(0x00AE42);
|
||||
//label_title->SetForegroundColour(0x00AE42);
|
||||
label_title->SetForegroundColour(0x9A5F21);
|
||||
label_txt = new Label(this, _L("When the current material run out, the printer will continue to print in the following order."));
|
||||
label_txt->SetFont(Label::Body_13);
|
||||
label_txt->SetForegroundColour(StateColor::darkModeColorFor(wxColour("#323A3C")));
|
||||
|
@ -1318,7 +1319,8 @@ void AmsReplaceMaterialDialog::create()
|
|||
std::pair<wxColour, int>(wxColour(38, 46, 48), StateColor::Enabled));
|
||||
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_sizer->Add( 0, 0, 1, wxEXPAND, 0 );
|
||||
|
||||
m_main_sizer->Add(0,0,0, wxTOP, FromDIP(12));
|
||||
|
|
|
@ -51,7 +51,8 @@
|
|||
#define AUFILE_GREY500 wxColour(158, 158, 158)
|
||||
#define AUFILE_GREY300 wxColour(238, 238, 238)
|
||||
#define AUFILE_GREY200 wxColour(248, 248, 248)
|
||||
#define AUFILE_BRAND wxColour(0, 174, 66)
|
||||
//#define AUFILE_BRAND wxColour(0, 174, 66)
|
||||
#define AUFILE_BRAND wxColour(0x9A5F21)
|
||||
#define AUFILE_BRAND_TRANSPARENT wxColour(215, 232, 222)
|
||||
//#define AUFILE_PICTURES_SIZE wxSize(FromDIP(300), FromDIP(300))
|
||||
//#define AUFILE_PICTURES_PANEL_SIZE wxSize(FromDIP(300), FromDIP(340))
|
||||
|
|
|
@ -139,7 +139,8 @@ PingCodeBindDialog::PingCodeBindDialog(Plater* plater /*= nullptr*/)
|
|||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_bind->SetBackgroundColor(btn_bg_green);
|
||||
m_button_bind->SetBorderColor(*wxWHITE);
|
||||
m_button_bind->SetTextColor(wxColour("#FFFFFE"));
|
||||
|
@ -480,7 +481,8 @@ PingCodeBindDialog::~PingCodeBindDialog() {
|
|||
m_link_Terms_title->SetFont(Label::Head_13);
|
||||
m_link_Terms_title->SetMaxSize(wxSize(FromDIP(450), -1));
|
||||
m_link_Terms_title->Wrap(FromDIP(450));
|
||||
m_link_Terms_title->SetForegroundColour(wxColour(0x00AE42));
|
||||
//m_link_Terms_title->SetForegroundColour(wxColour(0x00AE42));
|
||||
m_link_Terms_title->SetForegroundColour(wxColour(0x9A5F21));
|
||||
m_link_Terms_title->Bind(wxEVT_LEFT_DOWN, [this](auto& e) {
|
||||
wxString txt = _L("Thank you for purchasing a Bambu Lab device.Before using your Bambu Lab device, please read the termsand conditions.By clicking to agree to use your Bambu Lab device, you agree to abide by the Privacy Policy and Terms of Use(collectively, the \"Terms\"). If you do not comply with or agree to the Bambu Lab Privacy Policy, please do not use Bambu Lab equipment and services.");
|
||||
ConfirmBeforeSendDialog confirm_dlg(this, wxID_ANY, _L("Terms and Conditions"), ConfirmBeforeSendDialog::ButtonStyle::ONLY_CONFIRM);
|
||||
|
@ -499,7 +501,8 @@ PingCodeBindDialog::~PingCodeBindDialog() {
|
|||
m_link_privacy_title->SetFont(Label::Head_13);
|
||||
m_link_privacy_title->SetMaxSize(wxSize(FromDIP(450), -1));
|
||||
m_link_privacy_title->Wrap(FromDIP(450));
|
||||
m_link_privacy_title->SetForegroundColour(wxColour(0x00AE42));
|
||||
//m_link_privacy_title->SetForegroundColour(wxColour(0x00AE42));
|
||||
m_link_privacy_title->SetForegroundColour(wxColour(0x9A5F21));
|
||||
m_link_privacy_title->Bind(wxEVT_LEFT_DOWN, [this](auto& e) {
|
||||
std::string url;
|
||||
std::string country_code = Slic3r::GUI::wxGetApp().app_config->get_country_code();
|
||||
|
@ -539,7 +542,8 @@ PingCodeBindDialog::~PingCodeBindDialog() {
|
|||
m_link_notice_title->SetFont(Label::Head_13);
|
||||
m_link_notice_title->SetMaxSize(wxSize(FromDIP(450), -1));
|
||||
m_link_notice_title->Wrap(FromDIP(450));
|
||||
m_link_notice_title->SetForegroundColour(wxColour(0x00AE42));
|
||||
//m_link_notice_title->SetForegroundColour(wxColour(0x00AE42));
|
||||
m_link_notice_title->SetForegroundColour(wxColour(0x9A5F21));
|
||||
m_link_notice_title->Bind(wxEVT_ENTER_WINDOW, [this](auto& e) {SetCursor(wxCURSOR_HAND); });
|
||||
m_link_notice_title->Bind(wxEVT_LEAVE_WINDOW, [this](auto& e) {SetCursor(wxCURSOR_ARROW); });
|
||||
m_link_notice_title->Bind(wxEVT_LEFT_DOWN, [this](auto& e) {
|
||||
|
@ -678,7 +682,8 @@ PingCodeBindDialog::~PingCodeBindDialog() {
|
|||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_bind->SetBackgroundColor(btn_bg_green);
|
||||
m_button_bind->SetBorderColor(*wxWHITE);
|
||||
m_button_bind->SetTextColor(wxColour("#FFFFFE"));
|
||||
|
@ -1032,9 +1037,11 @@ UnBindMachineDialog::UnBindMachineDialog(Plater *plater /*= nullptr*/)
|
|||
m_sizer_button->Add(0, 0, 1, wxEXPAND, 5);
|
||||
m_button_unbind = new Button(this, _L("Confirm"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_unbind->SetBackgroundColor(btn_bg_green);
|
||||
m_button_unbind->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_button_unbind->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_button_unbind->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_button_unbind->SetTextColor(wxColour("#FFFFFE"));
|
||||
m_button_unbind->SetSize(BIND_DIALOG_BUTTON_SIZE);
|
||||
m_button_unbind->SetMinSize(BIND_DIALOG_BUTTON_SIZE);
|
||||
|
|
|
@ -85,7 +85,8 @@ BonjourDialog::BonjourDialog(wxWindow *parent, Slic3r::PrinterTechnology tech)
|
|||
auto button_sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
|
||||
|
|
|
@ -74,10 +74,12 @@ HistoryWindow::HistoryWindow(wxWindow* parent, const std::vector<PACalibResult>&
|
|||
|
||||
Button * mew_btn = new Button(scroll_window, _L("New"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
mew_btn->SetBackgroundColour(*wxWHITE);
|
||||
mew_btn->SetBackgroundColor(btn_bg_green);
|
||||
mew_btn->SetBorderColor(wxColour(0, 174, 66));
|
||||
//mew_btn->SetBorderColor(wxColour(0, 174, 66));
|
||||
mew_btn->SetBorderColor(wxColour(0x9A5F21));
|
||||
mew_btn->SetTextColor(wxColour("#FFFFFE"));
|
||||
mew_btn->SetMinSize(wxSize(FromDIP(100), FromDIP(24)));
|
||||
mew_btn->SetMaxSize(wxSize(FromDIP(100), FromDIP(24)));
|
||||
|
@ -322,10 +324,12 @@ void HistoryWindow::sync_history_data() {
|
|||
auto edit_button = new Button(m_history_data_panel, _L("Edit"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
edit_button->SetBackgroundColour(*wxWHITE);
|
||||
edit_button->SetBackgroundColor(btn_bg_green);
|
||||
edit_button->SetBorderColor(wxColour(0, 174, 66));
|
||||
//edit_button->SetBorderColor(wxColour(0, 174, 66));
|
||||
edit_button->SetBorderColor(wxColour(0x9A5F21));
|
||||
edit_button->SetTextColor(wxColour("#FFFFFE"));
|
||||
edit_button->SetMinSize(wxSize(-1, FromDIP(24)));
|
||||
edit_button->SetCornerRadius(FromDIP(12));
|
||||
|
@ -438,10 +442,12 @@ EditCalibrationHistoryDialog::EditCalibrationHistoryDialog(wxWindow* parent, con
|
|||
Button* save_btn = new Button(top_panel, _L("Save"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
save_btn->SetBackgroundColour(*wxWHITE);
|
||||
save_btn->SetBackgroundColor(btn_bg_green);
|
||||
save_btn->SetBorderColor(wxColour(0, 174, 66));
|
||||
//save_btn->SetBorderColor(wxColour(0, 174, 66));
|
||||
save_btn->SetBorderColor(wxColour(0x9A5F21));
|
||||
save_btn->SetTextColor(wxColour("#FFFFFE"));
|
||||
save_btn->SetMinSize(wxSize(-1, FromDIP(24)));
|
||||
save_btn->SetCornerRadius(FromDIP(12));
|
||||
|
@ -653,10 +659,12 @@ NewCalibrationHistoryDialog::NewCalibrationHistoryDialog(wxWindow *parent, const
|
|||
auto btn_sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
Button * ok_btn = new Button(top_panel, _L("Ok"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
ok_btn->SetBackgroundColour(*wxWHITE);
|
||||
ok_btn->SetBackgroundColor(btn_bg_green);
|
||||
ok_btn->SetBorderColor(wxColour(0, 174, 66));
|
||||
//ok_btn->SetBorderColor(wxColour(0, 174, 66));
|
||||
ok_btn->SetBorderColor(wxColour(0x9A5F21));
|
||||
ok_btn->SetTextColor(wxColour("#FFFFFE"));
|
||||
ok_btn->SetMinSize(wxSize(-1, FromDIP(24)));
|
||||
ok_btn->SetCornerRadius(FromDIP(12));
|
||||
|
|
|
@ -10,7 +10,8 @@ namespace Slic3r { namespace GUI {
|
|||
#define SELECT_MACHINE_GREY900 wxColour(38, 46, 48)
|
||||
#define SELECT_MACHINE_GREY600 wxColour(144,144,144)
|
||||
#define SELECT_MACHINE_GREY400 wxColour(206, 206, 206)
|
||||
#define SELECT_MACHINE_BRAND wxColour(0, 174, 66)
|
||||
//#define SELECT_MACHINE_BRAND wxColour(0, 174, 66)
|
||||
#define SELECT_MACHINE_BRAND wxColour(0x9A5F21)
|
||||
#define SELECT_MACHINE_REMIND wxColour(255,111,0)
|
||||
#define SELECT_MACHINE_LIGHT_GREEN wxColour(219, 253, 231)
|
||||
|
||||
|
|
|
@ -528,6 +528,7 @@ static bool get_preset_info(const DynamicConfig& config, const BedType plate_typ
|
|||
static bool get_flow_ratio(const DynamicConfig& config, float& flow_ratio)
|
||||
{
|
||||
const ConfigOptionFloats *flow_ratio_opt = config.option<ConfigOptionFloats>("filament_flow_ratio");
|
||||
//const ConfigOptionFloats *flow_ratio_opt = config.option<ConfigOptionFloats>("fibre_feed_rate");
|
||||
if (flow_ratio_opt) {
|
||||
flow_ratio = flow_ratio_opt->get_at(0);
|
||||
if (flow_ratio > 0)
|
||||
|
@ -1057,6 +1058,7 @@ void FlowRateWizard::on_cali_start(CaliPresetStage stage, float cali_value, Flow
|
|||
else if (stage == CaliPresetStage::CALI_MANUAL_STAGE_2) {
|
||||
cali_stage = 2;
|
||||
temp_filament_preset->config.set_key_value("filament_flow_ratio", new ConfigOptionFloats{ cali_value });
|
||||
//temp_filament_preset->config.set_key_value("fibre_feed_rate", new ConfigOptionFloats{ cali_value });
|
||||
if (from_page == FlowRatioCaliSource::FROM_PRESET_PAGE) {
|
||||
calib_info.process_bar = preset_page->get_sending_progress_bar();
|
||||
}
|
||||
|
@ -1135,6 +1137,7 @@ void FlowRateWizard::on_cali_save()
|
|||
for (int i = 0; i < new_results.size(); i++) {
|
||||
std::map<std::string, ConfigOption*> key_value_map;
|
||||
key_value_map.insert(std::make_pair("filament_flow_ratio", new ConfigOptionFloats{ new_results[i].second }));
|
||||
//key_value_map.insert(std::make_pair("fibre_feed_rate", new ConfigOptionFloats{ new_results[i].second }));
|
||||
wxString message;
|
||||
if (!save_preset(old_preset_name, into_u8(new_results[i].first), key_value_map, message)) {
|
||||
MessageDialog error_msg_dlg(nullptr, message, wxEmptyString, wxICON_WARNING | wxOK);
|
||||
|
@ -1181,6 +1184,7 @@ void FlowRateWizard::on_cali_save()
|
|||
}
|
||||
std::map<std::string, ConfigOption*> key_value_map;
|
||||
key_value_map.insert(std::make_pair("filament_flow_ratio", new ConfigOptionFloats{ new_flow_ratio }));
|
||||
//key_value_map.insert(std::make_pair("fibre_feed_rate", new ConfigOptionFloats{ new_flow_ratio }));
|
||||
|
||||
wxString message;
|
||||
if (!save_preset(old_preset_name, into_u8(new_preset_name), key_value_map, message)) {
|
||||
|
|
|
@ -144,7 +144,8 @@ CaliPageButton::CaliPageButton(wxWindow* parent, CaliPageActionType type, wxStri
|
|||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed),
|
||||
|
@ -152,7 +153,8 @@ CaliPageButton::CaliPageButton(wxWindow* parent, CaliPageActionType type, wxStri
|
|||
std::pair<wxColour, int>(wxColour(255, 255, 255), StateColor::Normal));
|
||||
|
||||
StateColor btn_bd_green(std::pair<wxColour, int>(wxColour(255, 255, 254), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Enabled));
|
||||
|
||||
StateColor btn_bd_white(std::pair<wxColour, int>(wxColour(255, 255, 254), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(38, 46, 48), StateColor::Enabled));
|
||||
|
|
|
@ -927,6 +927,7 @@ void CalibrationPresetPage::on_recommend_input_value()
|
|||
Preset *selected_filament_preset = selected_filaments.begin()->second;
|
||||
if (selected_filament_preset) {
|
||||
const ConfigOptionFloats* flow_ratio_opt = selected_filament_preset->config.option<ConfigOptionFloats>("filament_flow_ratio");
|
||||
//const ConfigOptionFloats* flow_ratio_opt = selected_filament_preset->config.option<ConfigOptionFloats>("fibre_feed_rate");
|
||||
if (flow_ratio_opt) {
|
||||
m_cali_stage_panel->set_flow_ratio_value(flow_ratio_opt->get_at(0));
|
||||
}
|
||||
|
@ -1770,6 +1771,7 @@ void CalibrationPresetPage::get_cali_stage(CaliPresetStage& stage, float& value)
|
|||
std::map<int, Preset*> selected_filaments = get_selected_filaments();
|
||||
if (!selected_filaments.empty()) {
|
||||
const ConfigOptionFloats* flow_ratio_opt = selected_filaments.begin()->second->config.option<ConfigOptionFloats>("filament_flow_ratio");
|
||||
//const ConfigOptionFloats* flow_ratio_opt = selected_filaments.begin()->second->config.option<ConfigOptionFloats>("fibre_feed_rate");
|
||||
if (flow_ratio_opt) {
|
||||
m_cali_stage_panel->set_flow_ratio_value(flow_ratio_opt->get_at(0));
|
||||
value = flow_ratio_opt->get_at(0);
|
||||
|
|
|
@ -55,10 +55,12 @@ ConnectPrinterDialog::ConnectPrinterDialog(wxWindow *parent, wxWindowID id, cons
|
|||
StateColor btn_bg(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//StateColor btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor btn_bd(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_text(std::pair<wxColour, int>(wxColour(255, 255, 255), StateColor::Normal));
|
||||
|
||||
|
|
|
@ -912,7 +912,8 @@ wxBoxSizer *CreateFilamentPresetDialog::create_button_item()
|
|||
bSizer_button->Add(0, 0, 1, wxEXPAND, 0);
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_button_create = new Button(this, _L("Create"));
|
||||
m_button_create->SetBackgroundColor(btn_bg_green);
|
||||
|
@ -1848,7 +1849,8 @@ wxBoxSizer *CreatePrinterPresetDialog::create_hot_bed_stl_item(wxWindow *parent)
|
|||
StateColor flush_bg_col(std::pair<wxColour, int>(wxColour(219, 253, 231), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Normal));
|
||||
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
//StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(172, 172, 172), StateColor::Normal));
|
||||
|
||||
m_button_bed_stl = new Button(parent, _L("Load stl"));
|
||||
|
@ -1885,7 +1887,8 @@ wxBoxSizer *CreatePrinterPresetDialog::create_hot_bed_svg_item(wxWindow *parent)
|
|||
StateColor flush_bg_col(std::pair<wxColour, int>(wxColour(219, 253, 231), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Normal));
|
||||
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
//StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(172, 172, 172), StateColor::Normal));
|
||||
|
||||
m_button_bed_svg = new Button(parent, _L("Load svg"));
|
||||
|
@ -1933,7 +1936,8 @@ wxBoxSizer *CreatePrinterPresetDialog::create_page1_btns_item(wxWindow *parent)
|
|||
bSizer_button->Add(0, 0, 1, wxEXPAND, 0);
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_button_OK = new Button(parent, _L("OK"));
|
||||
m_button_OK->SetBackgroundColor(btn_bg_green);
|
||||
|
@ -2514,7 +2518,8 @@ wxBoxSizer *CreatePrinterPresetDialog::create_page2_btns_item(wxWindow *parent)
|
|||
bSizer_button->Add(0, 0, 1, wxEXPAND, 0);
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
|
||||
|
@ -3243,7 +3248,8 @@ CreatePresetSuccessfulDialog::CreatePresetSuccessfulDialog(wxWindow *parent, con
|
|||
break;
|
||||
}
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
|
||||
|
@ -4101,7 +4107,8 @@ wxBoxSizer *ExportConfigsDialog::create_button_item(wxWindow* parent)
|
|||
bSizer_button->Add(0, 0, 1, wxEXPAND, 0);
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_button_ok = new Button(this, _L("OK"));
|
||||
m_button_ok->SetBackgroundColor(btn_bg_green);
|
||||
|
@ -4610,7 +4617,8 @@ wxBoxSizer *EditFilamentPresetDialog::create_add_filament_btn()
|
|||
StateColor flush_fg_col(std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Pressed), std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Normal));
|
||||
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
//StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(172, 172, 172), StateColor::Normal));
|
||||
|
||||
m_add_filament_btn->SetBackgroundColor(flush_bg_col);
|
||||
|
@ -4670,7 +4678,8 @@ wxBoxSizer *EditFilamentPresetDialog::create_button_sizer()
|
|||
bSizer_button->Add(0, 0, 1, wxEXPAND, 0);
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_ok_btn = new Button(this, _L("OK"));
|
||||
m_ok_btn->SetBackgroundColor(btn_bg_green);
|
||||
|
@ -4870,7 +4879,8 @@ wxBoxSizer *CreatePresetForPrinterDialog::create_button_sizer()
|
|||
bSizer_button->Add(0, 0, 1, wxEXPAND, 0);
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_ok_btn = new Button(this, _L("OK"));
|
||||
m_ok_btn->SetBackgroundColor(btn_bg_green);
|
||||
|
@ -5016,11 +5026,13 @@ wxPanel *PresetTree::get_child_item(wxPanel *parent, std::shared_ptr<Preset> pre
|
|||
StateColor flush_fg_col(std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Pressed), std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Normal));
|
||||
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
//StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(172, 172, 172), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
Button *edit_preset_btn = new Button(panel, _L("Edit Preset"));
|
||||
edit_preset_btn->SetFont(Label::Body_10);
|
||||
|
|
|
@ -485,7 +485,8 @@ void DailyTipsPanel::render_controller_buttons(const ImVec2& pos, const ImVec2&
|
|||
button_text = ImGui::PrevArrowBtnIcon;
|
||||
if (ImGui::IsMouseHoveringRect(prev_button_pos, prev_button_pos + button_size, true))
|
||||
{
|
||||
button_text_color = ImColor(0, 174, 66, (int)(255 * m_fade_opacity));
|
||||
//button_text_color = ImColor(0, 174, 66, (int)(255 * m_fade_opacity));
|
||||
button_text_color = ImColor(33, 95, 154, (int)(255 * m_fade_opacity));
|
||||
if (ImGui::IsMouseClicked(ImGuiMouseButton_Left))
|
||||
retrieve_data_from_hint_database(HintDataNavigation::Prev);
|
||||
}
|
||||
|
@ -500,7 +501,8 @@ void DailyTipsPanel::render_controller_buttons(const ImVec2& pos, const ImVec2&
|
|||
button_text = ImGui::NextArrowBtnIcon;
|
||||
if (ImGui::IsMouseHoveringRect(next_button_pos, next_button_pos + button_size, true))
|
||||
{
|
||||
button_text_color = ImColor(0, 174, 66, (int)(255 * m_fade_opacity));
|
||||
//button_text_color = ImColor(0, 174, 66, (int)(255 * m_fade_opacity));
|
||||
button_text_color = ImColor(33, 95, 154, (int)(255 * m_fade_opacity));
|
||||
if (ImGui::IsMouseClicked(ImGuiMouseButton_Left))
|
||||
retrieve_data_from_hint_database(HintDataNavigation::Next);
|
||||
}
|
||||
|
|
|
@ -172,10 +172,12 @@ void ExtrusionCalibration::create()
|
|||
|
||||
m_button_cali = new Button(m_step_1_panel, _L("Start calibration"));
|
||||
m_btn_bg_green = StateColor(std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Disabled), std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_cali->SetBackgroundColor(m_btn_bg_green);
|
||||
m_button_cali->SetFont(Label::Body_13);
|
||||
m_button_cali->SetBorderColor({ std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Disabled), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled) });
|
||||
//m_button_cali->SetBorderColor({ std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Disabled), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled) });
|
||||
m_button_cali->SetBorderColor({ std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Disabled), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Enabled) });
|
||||
m_button_cali->SetTextColor({ std::pair<wxColour, int>(wxColour(172, 172, 172), StateColor::Disabled), std::pair<wxColour, int>(EXTRUSION_CALIBRATION_GREY200, StateColor::Enabled) });
|
||||
m_button_cali->SetCornerRadius(FromDIP(12));
|
||||
m_button_cali->SetMinSize(wxSize(-1, FromDIP(24)));
|
||||
|
@ -183,9 +185,11 @@ void ExtrusionCalibration::create()
|
|||
|
||||
m_cali_cancel = new Button(m_step_1_panel, _L("Cancel"));
|
||||
m_btn_bg_green = StateColor(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_cali_cancel->SetBackgroundColor(m_btn_bg_green);
|
||||
m_cali_cancel->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_cali_cancel->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_cali_cancel->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_cali_cancel->SetTextColor(EXTRUSION_CALIBRATION_GREY200);
|
||||
m_cali_cancel->SetMinSize(EXTRUSION_CALIBRATION_BUTTON_SIZE);
|
||||
m_cali_cancel->SetCornerRadius(FromDIP(12));
|
||||
|
@ -258,10 +262,12 @@ void ExtrusionCalibration::create()
|
|||
// save button
|
||||
m_button_save_result = new Button(m_step_2_panel, _L("Save"));
|
||||
m_btn_bg_green = StateColor(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_save_result->SetBackgroundColor(m_btn_bg_green);
|
||||
m_button_save_result->SetFont(Label::Body_13);
|
||||
m_button_save_result->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_button_save_result->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_button_save_result->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_button_save_result->SetTextColor(EXTRUSION_CALIBRATION_GREY200);
|
||||
m_button_save_result->SetMinSize(EXTRUSION_CALIBRATION_BUTTON_SIZE);
|
||||
m_button_save_result->SetCornerRadius(FromDIP(12));
|
||||
|
|
|
@ -589,8 +589,10 @@ void GCodeViewer::SequentialView::GCodeWindow::render(float top, float bottom, f
|
|||
return ret;
|
||||
};
|
||||
|
||||
static const ImVec4 LINE_NUMBER_COLOR = { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f };
|
||||
static const ImVec4 SELECTION_RECT_COLOR = { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f };
|
||||
//static const ImVec4 LINE_NUMBER_COLOR = { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f };
|
||||
static const ImVec4 LINE_NUMBER_COLOR = { 33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0f };
|
||||
//static const ImVec4 SELECTION_RECT_COLOR = { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f };
|
||||
static const ImVec4 SELECTION_RECT_COLOR = { 33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0f };
|
||||
static const ImVec4 COMMAND_COLOR = m_is_dark ? ImVec4( 240.0f / 255.0f, 240.0f / 255.0f, 240.0f / 255.0f, 1.0f ) : ImVec4( 1.0f, 1.0f, 1.0f, 1.0f );
|
||||
static const ImVec4 PARAMETERS_COLOR = m_is_dark ? ImVec4( 179.0f / 255.0f, 179.0f / 255.0f, 179.0f / 255.0f, 1.0f ) : ImVec4( 206.0f / 255.0f, 206.0f / 255.0f, 206.0f / 255.0f, 1.0f );
|
||||
static const ImVec4 COMMENT_COLOR = m_is_dark ? ImVec4(129.0f / 255.0f, 129.0f / 255.0f, 129.0f / 255.0f, 1.0f) : ImVec4( 172.0f / 255.0f, 172.0f / 255.0f, 172.0f / 255.0f, 1.0f );
|
||||
|
|
|
@ -233,9 +233,13 @@ void GLCanvas3D::LayersEditing::render_variable_layer_height_dialog(const GLCanv
|
|||
ImGuiWrapper& imgui = *wxGetApp().imgui();
|
||||
const Size& cnv_size = canvas.get_canvas_size();
|
||||
float zoom = (float)wxGetApp().plater()->get_camera().get_zoom();
|
||||
float left_pos = canvas.m_main_toolbar.get_item("layersediting")->render_left_pos;
|
||||
const float x = 0.5 * cnv_size.get_width() + left_pos * zoom;
|
||||
imgui.set_next_window_pos(x, canvas.m_main_toolbar.get_height(), ImGuiCond_Always, 0.0f, 0.0f);
|
||||
//float left_pos = canvas.m_main_toolbar.get_item("layersediting")->render_left_pos;
|
||||
float top_pos = canvas.m_main_toolbar.get_item("layersediting")->render_top_pos;
|
||||
//const float x = 0.5 * cnv_size.get_width() + left_pos * zoom;
|
||||
const float x = canvas.m_main_toolbar.get_width();
|
||||
const float y = 0.5 * cnv_size.get_height() - top_pos * zoom;
|
||||
//imgui.set_next_window_pos(x, canvas.m_main_toolbar.get_height(), ImGuiCond_Always, 0.0f, 0.0f);
|
||||
imgui.set_next_window_pos(x, y, ImGuiCond_Always, 0.0f, 0.0f);
|
||||
|
||||
imgui.push_toolbar_style(canvas.get_scale());
|
||||
ImGui::PushStyleVar(ImGuiStyleVar_FramePadding, ImVec2(6.0f * canvas.get_scale(), 4.0f * canvas.get_scale()));
|
||||
|
@ -315,7 +319,8 @@ void GLCanvas3D::LayersEditing::render_variable_layer_height_dialog(const GLCanv
|
|||
|
||||
ImGui::Separator();
|
||||
|
||||
float get_cur_y = ImGui::GetContentRegionMax().y + ImGui::GetFrameHeight() + canvas.m_main_toolbar.get_height();
|
||||
//float get_cur_y = ImGui::GetContentRegionMax().y + ImGui::GetFrameHeight() + canvas.m_main_toolbar.get_height();
|
||||
float get_cur_y = y - ImGui::GetContentRegionMax().y - ImGui::GetFrameHeight();
|
||||
std::map<wxString, wxString> captions_texts = {
|
||||
{_L("Left mouse button:") ,_L("Add detail")},
|
||||
{_L("Right mouse button:"), _L("Remove detail")},
|
||||
|
@ -323,6 +328,7 @@ void GLCanvas3D::LayersEditing::render_variable_layer_height_dialog(const GLCanv
|
|||
{_L("Shift + Right mouse button:"), _L("Smoothing")},
|
||||
{_L("Mouse wheel:"), _L("Increase/decrease edit area")}
|
||||
};
|
||||
//show_tooltip_information(canvas, captions_texts, x, get_cur_y);
|
||||
show_tooltip_information(canvas, captions_texts, x, get_cur_y);
|
||||
ImGui::SameLine();
|
||||
if (imgui.button(_L("Reset")))
|
||||
|
@ -1132,6 +1138,7 @@ GLCanvas3D::GLCanvas3D(wxGLCanvas* canvas, Bed3D &bed)
|
|||
#endif
|
||||
, m_in_render(false)
|
||||
, m_main_toolbar(GLToolbar::Normal, "Main")
|
||||
//, m_left_toolbar(GLToolbar::Normal, "Left")
|
||||
, m_separator_toolbar(GLToolbar::Normal, "Separator")
|
||||
, m_assemble_view_toolbar(GLToolbar::Normal, "Assembly_View")
|
||||
, m_return_toolbar()
|
||||
|
@ -1318,6 +1325,7 @@ void GLCanvas3D::on_change_color_mode(bool is_dark, bool reinit) {
|
|||
// set dirty to re-generate icon texture
|
||||
m_separator_toolbar.set_icon_dirty();
|
||||
m_main_toolbar.set_icon_dirty();
|
||||
//m_left_toolbar.set_icon_dirty();
|
||||
wxGetApp().plater()->get_collapse_toolbar().set_icon_dirty();
|
||||
m_assemble_view_toolbar.set_icon_dirty();
|
||||
m_gizmos.set_icon_dirty();
|
||||
|
@ -1689,6 +1697,11 @@ void GLCanvas3D::enable_main_toolbar(bool enable)
|
|||
m_main_toolbar.set_enabled(enable);
|
||||
}
|
||||
|
||||
//void GLCanvas3D::enable_left_toolbar(bool enable)
|
||||
//{
|
||||
// m_left_toolbar.set_enabled(enable);
|
||||
//}
|
||||
|
||||
void GLCanvas3D::reset_select_plate_toolbar_selection() {
|
||||
if (m_sel_plate_toolbar.m_all_plates_stats_item)
|
||||
m_sel_plate_toolbar.m_all_plates_stats_item->selected = false;
|
||||
|
@ -3006,6 +3019,7 @@ void GLCanvas3D::on_idle(wxIdleEvent& evt)
|
|||
return;
|
||||
|
||||
m_dirty |= m_main_toolbar.update_items_state();
|
||||
//m_dirty |= m_left_toolbar.update_items_state();
|
||||
//BBS: GUI refactor: GLToolbar
|
||||
m_dirty |= m_assemble_view_toolbar.update_items_state();
|
||||
// BBS
|
||||
|
@ -5503,8 +5517,11 @@ bool GLCanvas3D::_render_arrange_menu(float left, float right, float bottom, flo
|
|||
#if BBS_TOOLBAR_ON_TOP
|
||||
float zoom = (float)wxGetApp().plater()->get_camera().get_zoom();
|
||||
float left_pos = m_main_toolbar.get_item("arrange")->render_left_pos;
|
||||
const float x = 0.5 * canvas_w + left_pos * zoom;
|
||||
imgui->set_next_window_pos(x, m_main_toolbar.get_height(), ImGuiCond_Always, 0.0f, 0.0f);
|
||||
float top_pos = m_main_toolbar.get_item("arrange")->render_top_pos;
|
||||
//const float x = 0.5 * canvas_w + left_pos * zoom;
|
||||
const float y = 0.5 * canvas_h - top_pos * zoom;
|
||||
//imgui->set_next_window_pos(x, m_main_toolbar.get_height(), ImGuiCond_Always, 0.0f, 0.0f);
|
||||
imgui->set_next_window_pos(m_main_toolbar.get_width(), y, ImGuiCond_Always, 0.0f, 0.0f);
|
||||
|
||||
#else
|
||||
const float x = canvas_w - m_main_toolbar.get_width();
|
||||
|
@ -6171,6 +6188,7 @@ void GLCanvas3D::_switch_toolbars_icon_filename()
|
|||
background_data.right = 16;
|
||||
background_data.bottom = 16;
|
||||
m_main_toolbar.init(background_data);
|
||||
//m_left_toolbar.init(background_data);
|
||||
m_assemble_view_toolbar.init(background_data);
|
||||
m_separator_toolbar.init(background_data);
|
||||
wxGetApp().plater()->get_collapse_toolbar().init(background_data);
|
||||
|
@ -6275,10 +6293,10 @@ bool GLCanvas3D::_init_main_toolbar()
|
|||
BOOST_LOG_TRIVIAL(error) << "Gizmos manager failed to load arrow texture.";
|
||||
}
|
||||
|
||||
m_main_toolbar.set_layout_type(GLToolbar::Layout::Horizontal);
|
||||
m_main_toolbar.set_layout_type(GLToolbar::Layout::Vertical);
|
||||
//BBS: main toolbar is at the top and left, we don't need the rounded-corner effect at the right side and the top side
|
||||
m_main_toolbar.set_horizontal_orientation(GLToolbar::Layout::HO_Right);
|
||||
m_main_toolbar.set_vertical_orientation(GLToolbar::Layout::VO_Top);
|
||||
m_main_toolbar.set_horizontal_orientation(GLToolbar::Layout::HO_Left);
|
||||
m_main_toolbar.set_vertical_orientation(GLToolbar::Layout::VO_Center);
|
||||
m_main_toolbar.set_border(5.0f);
|
||||
m_main_toolbar.set_separator_size(5);
|
||||
m_main_toolbar.set_gap_size(4);
|
||||
|
@ -7287,7 +7305,7 @@ void GLCanvas3D::_check_and_update_toolbar_icon_scale()
|
|||
//use the same value as horizon
|
||||
float new_v_scale = new_h_scale;
|
||||
#else
|
||||
float top_tb_width = = collapse_toolbar.get_width();
|
||||
float top_tb_width = collapse_toolbar.get_width();
|
||||
int items_cnt = collapse_toolbar.get_visible_items_cnt();
|
||||
float noitems_width = top_tb_width - size * items_cnt; // width of separators and borders in top toolbars
|
||||
|
||||
|
@ -7346,6 +7364,7 @@ void GLCanvas3D::_render_overlays()
|
|||
|
||||
//BBS: GUI refactor: GLToolbar
|
||||
m_main_toolbar.set_icons_size(gizmo_size);
|
||||
//m_left_toolbar.set_icons_size(gizmo_size);
|
||||
m_assemble_view_toolbar.set_icons_size(gizmo_size);
|
||||
m_separator_toolbar.set_icons_size(gizmo_size);
|
||||
wxGetApp().plater()->get_collapse_toolbar().set_icons_size(size);
|
||||
|
@ -7563,15 +7582,18 @@ void GLCanvas3D::_render_main_toolbar()
|
|||
|
||||
Size cnv_size = get_canvas_size();
|
||||
float inv_zoom = (float)wxGetApp().plater()->get_camera().get_inv_zoom();
|
||||
|
||||
auto canvas_w = float(get_canvas_size().get_width());
|
||||
#if BBS_TOOLBAR_ON_TOP
|
||||
GLToolbar& collapse_toolbar = wxGetApp().plater()->get_collapse_toolbar();
|
||||
float collapse_toolbar_width = collapse_toolbar.is_enabled() ? collapse_toolbar.get_width() : 0.0f;
|
||||
float gizmo_width = m_gizmos.get_scaled_total_width();
|
||||
float assemble_width = m_assemble_view_toolbar.get_width();
|
||||
float separator_width = m_separator_toolbar.get_width();
|
||||
float top = 0.5f * (float)cnv_size.get_height() * inv_zoom;
|
||||
float left = std::max(-0.5f * cnv_size.get_width(), -0.5f * (m_main_toolbar.get_width() + separator_width + gizmo_width + assemble_width - collapse_toolbar_width)) * inv_zoom;
|
||||
//float top = 0.5f * (float)cnv_size.get_height() * inv_zoom;
|
||||
float top = 0.5f * (float)m_main_toolbar.get_width();
|
||||
//float left = std::max(-0.5f * cnv_size.get_width(), -0.5f * (m_main_toolbar.get_width() + separator_width + gizmo_width + assemble_width - collapse_toolbar_width)) * inv_zoom;
|
||||
//float left = -0.12f * (float)cnv_size.get_width();
|
||||
float left = -0.5f * (float)cnv_size.get_width() * inv_zoom;
|
||||
#else
|
||||
float gizmo_height = m_gizmos.get_scaled_total_height();
|
||||
float space_height = GLGizmosManager::Default_Icons_Size * wxGetApp().toolbar_icon_scale();
|
||||
|
@ -7581,6 +7603,7 @@ void GLCanvas3D::_render_main_toolbar()
|
|||
float left = (0.5f * (float)cnv_size.get_width() - m_main_toolbar.get_width()) * inv_zoom;
|
||||
//BOOST_LOG_TRIVIAL(info) << __FUNCTION__ << boost::format(": top %1%, main_toolbar_height %2%, space_height %3% gizmo_height %4%") % top % main_toolbar_height % space_height % gizmo_height;
|
||||
#endif
|
||||
//m_main_toolbar.set_position(top, left);
|
||||
m_main_toolbar.set_position(top, left);
|
||||
m_main_toolbar.render(*this);
|
||||
if (m_toolbar_highlighter.m_render_arrow)
|
||||
|
@ -7762,12 +7785,14 @@ void GLCanvas3D::_render_imgui_select_plate_toolbar()
|
|||
ImTextureID btn_texture_id;
|
||||
if (all_plates_stats_item->slice_state == IMToolbarItem::SliceState::UNSLICED || all_plates_stats_item->slice_state == IMToolbarItem::SliceState::SLICING || all_plates_stats_item->slice_state == IMToolbarItem::SliceState::SLICE_FAILED)
|
||||
{
|
||||
text_clr = ImVec4(0, 174.0f / 255.0f, 66.0f / 255.0f, 0.2f);
|
||||
//text_clr = ImVec4(0, 174.0f / 255.0f, 66.0f / 255.0f, 0.2f);
|
||||
text_clr = ImVec4(33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 0.2f);
|
||||
btn_texture_id = (ImTextureID)(intptr_t)(all_plates_stats_item->image_texture_transparent.get_id());
|
||||
}
|
||||
else
|
||||
{
|
||||
text_clr = ImVec4(0, 174.0f / 255.0f, 66.0f / 255.0f, 1);
|
||||
//text_clr = ImVec4(0, 174.0f / 255.0f, 66.0f / 255.0f, 1);
|
||||
text_clr = ImVec4(33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1);
|
||||
btn_texture_id = (ImTextureID)(intptr_t)(all_plates_stats_item->image_texture.get_id());
|
||||
}
|
||||
|
||||
|
|
|
@ -520,6 +520,8 @@ private:
|
|||
GLGizmosManager m_gizmos;
|
||||
//BBS: GUI refactor: GLToolbar
|
||||
mutable GLToolbar m_main_toolbar;
|
||||
//mutable GLToolbar m_left_toolbar;
|
||||
//mutable GLToolbar m_top_toolbar;
|
||||
mutable GLToolbar m_separator_toolbar;
|
||||
mutable IMToolbar m_sel_plate_toolbar;
|
||||
mutable GLToolbar m_assemble_view_toolbar;
|
||||
|
@ -797,6 +799,7 @@ public:
|
|||
void enable_gizmos(bool enable);
|
||||
void enable_selection(bool enable);
|
||||
void enable_main_toolbar(bool enable);
|
||||
//void enable_left_toolbar(bool enable);
|
||||
//BBS: GUI refactor: GLToolbar
|
||||
void _update_select_plate_toolbar_stats_item(bool force_selected = false);
|
||||
void reset_select_plate_toolbar_selection();
|
||||
|
|
|
@ -96,6 +96,7 @@ GLToolbarItem::GLToolbarItem(GLToolbarItem::EType type, const GLToolbarItem::Dat
|
|||
, m_highlight_state(NotHighlighted)
|
||||
{
|
||||
render_left_pos = 0.0f;
|
||||
render_top_pos = 0.0f;
|
||||
}
|
||||
|
||||
void GLToolbarItem::set_state(EState state)
|
||||
|
@ -1459,12 +1460,13 @@ void GLToolbar::render_horizontal(const GLCanvas3D& parent,GLToolbarItem::EType
|
|||
if (!item->is_visible())
|
||||
continue;
|
||||
|
||||
if (item->is_separator())
|
||||
if (item->is_separator())
|
||||
left += separator_stride;
|
||||
else
|
||||
{
|
||||
//BBS GUI refactor
|
||||
item->render_left_pos = left;
|
||||
item->render_top_pos = top;
|
||||
if (!item->is_action_with_text_image()) {
|
||||
unsigned int tex_id = m_icons_texture.get_id();
|
||||
int tex_width = m_icons_texture.get_width();
|
||||
|
@ -1515,9 +1517,11 @@ void GLToolbar::render_vertical(const GLCanvas3D& parent)
|
|||
if (!item->is_visible())
|
||||
continue;
|
||||
|
||||
if (item->is_separator())
|
||||
if (item->is_separator())
|
||||
top -= separator_stride;
|
||||
else {
|
||||
item->render_left_pos = left;
|
||||
item->render_top_pos = top;
|
||||
unsigned int tex_id;
|
||||
int tex_width, tex_height;
|
||||
if (item->is_action_with_text_image()) {
|
||||
|
|
|
@ -181,6 +181,8 @@ public:
|
|||
// remember left position for rendering menu
|
||||
mutable float render_left_pos;
|
||||
|
||||
mutable float render_top_pos;
|
||||
|
||||
std::chrono::system_clock::time_point get_start_time_point() const { return start; }
|
||||
|
||||
GLToolbarItem(EType type, const Data& data);
|
||||
|
|
|
@ -416,7 +416,8 @@ public:
|
|||
int logo_margin = FromDIP(72 * m_scale);
|
||||
int logo_size = FromDIP(122 * m_scale);
|
||||
int logo_width = FromDIP(94 * m_scale);
|
||||
wxBitmap logo_bmp = *bmp_cache.load_svg("splash_logo", logo_size, logo_size);
|
||||
//wxBitmap logo_bmp = *bmp_cache.load_svg("splash_logo", logo_size, logo_size);
|
||||
wxBitmap logo_bmp = *bmp_cache.load_svg("machine_logo", logo_size, logo_size);
|
||||
int logo_y = top_margin + title_rect.GetHeight() + logo_margin;
|
||||
memDc.DrawBitmap(logo_bmp, 900, 0, true);
|
||||
|
||||
|
|
|
@ -2023,7 +2023,8 @@ void GLGizmoMeasure::show_face_face_assembly_common() {
|
|||
m_imgui->disabled_begin(!(action.can_set_to_center_coincidence));
|
||||
{
|
||||
ImGui::PushItemWidth(set_to_center_coincidence_size);
|
||||
ImGui::PushStyleColor(ImGuiCol_Button, m_is_dark_mode ? ImVec4(0 / 255.0, 174 / 255.0, 66 / 255.0, 1.0) : ImVec4(0 / 255.0, 174 / 255.0, 66 / 255.0, 1.0));
|
||||
//ImGui::PushStyleColor(ImGuiCol_Button, m_is_dark_mode ? ImVec4(0 / 255.0, 174 / 255.0, 66 / 255.0, 1.0) : ImVec4(0 / 255.0, 174 / 255.0, 66 / 255.0, 1.0));
|
||||
ImGui::PushStyleColor(ImGuiCol_Button, m_is_dark_mode ? ImVec4(33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0) : ImVec4(33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0));
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonHovered,
|
||||
m_is_dark_mode ? ImVec4(50 / 255.0f, 238 / 255.0f, 61 / 255.0f, 1.00f) : ImVec4(50 / 255.0f, 238 / 255.0f, 61 / 255.0f, 1.00f));
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonActive,
|
||||
|
|
|
@ -205,13 +205,18 @@ void GLGizmoMeshBoolean::on_render_input_window(float x, float y, float bottom_l
|
|||
|
||||
if (selected || hovered) {
|
||||
ImGui::PushStyleColor(ImGuiCol_Text, ImVec4(1.f, 1.f, 1.f, 1.0f));
|
||||
ImGui::PushStyleColor(ImGuiCol_Button, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonActive, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonHovered, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
//ImGui::PushStyleColor(ImGuiCol_Button, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_Button, { 33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0f });
|
||||
//ImGui::PushStyleColor(ImGuiCol_ButtonActive, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonActive, { 33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0f });
|
||||
//ImGui::PushStyleColor(ImGuiCol_ButtonHovered, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonHovered, { 33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0f });
|
||||
}
|
||||
else {
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonActive, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonHovered, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
//ImGui::PushStyleColor(ImGuiCol_ButtonActive, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonActive, { 33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0f });
|
||||
//ImGui::PushStyleColor(ImGuiCol_ButtonHovered, { 0, 174.0f / 255.0f, 66.0f / 255.0f, 1.0f });
|
||||
ImGui::PushStyleColor(ImGuiCol_ButtonHovered, { 33.0f / 255.0f, 95.0f / 255.0f, 154.0f / 255.0f, 1.0f });
|
||||
}
|
||||
|
||||
bool res = ImGui::Button(label.c_str(), size_arg);
|
||||
|
|
|
@ -25,7 +25,8 @@ static const ImU32 BACKGROUND_COLOR_DARK = IM_COL32(65, 65, 71, 255);
|
|||
static const ImU32 BACKGROUND_COLOR_LIGHT = IM_COL32(255, 255, 255, 255);
|
||||
static const ImU32 GROOVE_COLOR_DARK = IM_COL32(45, 45, 49, 255);
|
||||
static const ImU32 GROOVE_COLOR_LIGHT = IM_COL32(206, 206, 206, 255);
|
||||
static const ImU32 BRAND_COLOR = IM_COL32(0, 174, 66, 255);
|
||||
//static const ImU32 BRAND_COLOR = IM_COL32(0, 174, 66, 255);
|
||||
static const ImU32 BRAND_COLOR = IM_COL32(33, 95, 154, 255);
|
||||
|
||||
|
||||
static int m_tick_value = -1;
|
||||
|
|
|
@ -1987,8 +1987,10 @@ void MainFrame::update_side_button_style()
|
|||
m_slice_btn->SetBottomColour(wxColour(0x3B4446));*/
|
||||
StateColor m_btn_bg_enable = StateColor(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x0073BC, StateColor::Hovered),
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
m_publish_btn->SetMinSize(wxSize(FromDIP(125), FromDIP(24)));
|
||||
|
|
|
@ -153,11 +153,13 @@ Button* MsgDialog::add_button(wxWindowID btn_id, bool set_focus /*= false*/, con
|
|||
StateColor btn_bg_green(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor btn_bd_green(
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor btn_text_green(
|
||||
|
@ -554,7 +556,8 @@ wxBoxSizer *Newer3mfVersionDialog::get_btn_sizer()
|
|||
wxBoxSizer *horizontal_sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
horizontal_sizer->Add(0, 0, 1, wxEXPAND, 0);
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
|
||||
bool file_version_newer = (*m_file_version) > (*m_cloud_version);
|
||||
|
|
|
@ -186,7 +186,8 @@ void MultiMachineItem::doRender(wxDC& dc)
|
|||
}
|
||||
else if (state_device > 2 && state_device < 7) {
|
||||
dc.SetFont(Label::Body_12);
|
||||
dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
//dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
dc.SetTextForeground(wxColour(0x9A5F21));
|
||||
if (obj_->get_curr_stage().IsEmpty() && obj_->subtask_) {
|
||||
//wxString layer_info = wxString::Format(_L("Layer: %d/%d"), obj_->curr_layer, obj_->total_layers);
|
||||
wxString progress_info = wxString::Format("%d", obj_->subtask_->task_progress);
|
||||
|
@ -199,8 +200,10 @@ void MultiMachineItem::doRender(wxDC& dc)
|
|||
dc.SetBrush(wxBrush(wxColour(233,233,233)));
|
||||
dc.DrawRoundedRectangle(left, FromDIP(30), FromDIP(DEVICE_LEFT_PRO_INFO), FromDIP(10), 2);
|
||||
|
||||
dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetBrush(wxBrush(wxColour(0, 174, 66)));
|
||||
//dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetPen(wxPen(wxColour(0x9A5F21)));
|
||||
//dc.SetBrush(wxBrush(wxColour(0, 174, 66)));
|
||||
dc.SetBrush(wxBrush(wxColour(0x9A5F21)));
|
||||
dc.DrawRoundedRectangle(left, FromDIP(30), FromDIP(DEVICE_LEFT_PRO_INFO) * (static_cast<float>(obj_->subtask_->task_progress) / 100.0f), FromDIP(10), 2);
|
||||
}
|
||||
else {
|
||||
|
@ -226,7 +229,8 @@ void MultiMachineItem::doRender(wxDC& dc)
|
|||
}
|
||||
|
||||
if (m_hover) {
|
||||
dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
//dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetPen(wxPen(wxColour(0x9A5F21)));
|
||||
dc.SetBrush(*wxTRANSPARENT_BRUSH);
|
||||
dc.DrawRoundedRectangle(0, 0, size.x, size.y, 3);
|
||||
}
|
||||
|
@ -283,7 +287,8 @@ MultiMachineManagerPage::MultiMachineManagerPage(wxWindow* parent)
|
|||
auto m_btn_bg_enable = StateColor(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
|
||||
|
|
|
@ -36,7 +36,8 @@ MultiTaskItem::MultiTaskItem(wxWindow* parent, MachineObject* obj, int type)
|
|||
auto m_btn_bg_enable = StateColor(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
m_button_resume = new Button(this, _L("Resume"));
|
||||
|
@ -376,7 +377,8 @@ void MultiTaskItem::doRender(wxDC& dc)
|
|||
DrawTextWithEllipsis(dc, get_state_device(), FromDIP(DEVICE_LEFT_PRO_INFO), left);
|
||||
}
|
||||
else if (state_device == 1) {
|
||||
dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
//dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
dc.SetTextForeground(wxColour(0x9A5F21));
|
||||
DrawTextWithEllipsis(dc, get_state_device(), FromDIP(DEVICE_LEFT_PRO_INFO), left);
|
||||
}
|
||||
else if (state_device == 2)
|
||||
|
@ -386,7 +388,8 @@ void MultiTaskItem::doRender(wxDC& dc)
|
|||
}
|
||||
else if (state_device > 2 && state_device < 7) {
|
||||
dc.SetFont(Label::Body_12);
|
||||
dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
//dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
dc.SetTextForeground(wxColour(0x9A5F21));
|
||||
if (obj_->get_curr_stage().IsEmpty()) {
|
||||
//wxString layer_info = wxString::Format(_L("Layer: %d/%d"), obj_->curr_layer, obj_->total_layers);
|
||||
wxString progress_info = wxString::Format("%d", obj_->subtask_->task_progress);
|
||||
|
@ -398,8 +401,10 @@ void MultiTaskItem::doRender(wxDC& dc)
|
|||
dc.SetBrush(wxBrush(wxColour(233, 233, 233)));
|
||||
dc.DrawRoundedRectangle(left, FromDIP(30), FromDIP(TASK_LEFT_PRO_INFO), FromDIP(10), 2);
|
||||
|
||||
dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetBrush(wxBrush(wxColour(0, 174, 66)));
|
||||
//dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetPen(wxPen(wxColour(0x9A5F21)));
|
||||
//dc.SetBrush(wxBrush(wxColour(0, 174, 66)));
|
||||
dc.SetBrush(wxBrush(wxColour(0x9A5F21)));
|
||||
dc.DrawRoundedRectangle(left, FromDIP(30), FromDIP(TASK_LEFT_PRO_INFO) * (static_cast<float>(obj_->subtask_->task_progress) / 100.0f), FromDIP(10), 2);
|
||||
}
|
||||
else {
|
||||
|
@ -422,8 +427,10 @@ void MultiTaskItem::doRender(wxDC& dc)
|
|||
dc.SetBrush(wxBrush(wxColour(233, 233, 233)));
|
||||
dc.DrawRoundedRectangle(left, FromDIP(30), FromDIP(TASK_LEFT_PRO_INFO), FromDIP(10), 2);
|
||||
|
||||
dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetBrush(wxBrush(wxColour(0, 174, 66)));
|
||||
//dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetPen(wxPen(wxColour(0x9A5F21)));
|
||||
//dc.SetBrush(wxBrush(wxColour(0, 174, 66)));
|
||||
dc.SetBrush(wxBrush(wxColour(0x9A5F21)));
|
||||
dc.DrawRoundedRectangle(left, FromDIP(30), FromDIP(TASK_LEFT_PRO_INFO) * (static_cast<float>(m_sending_percent) / 100.0f), FromDIP(10), 2);
|
||||
}
|
||||
/*else {
|
||||
|
@ -449,7 +456,8 @@ void MultiTaskItem::doRender(wxDC& dc)
|
|||
left += FromDIP(TASK_LEFT_SEND_TIME);
|
||||
|
||||
if (m_hover) {
|
||||
dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
//dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetPen(wxPen(wxColour(0x9A5F21)));
|
||||
dc.SetBrush(*wxTRANSPARENT_BRUSH);
|
||||
dc.DrawRoundedRectangle(0, 0, size.x, size.y, 3);
|
||||
}
|
||||
|
|
|
@ -157,8 +157,10 @@ void ButtonsListCtrl::SetSelection(int sel)
|
|||
m_selection = sel;
|
||||
|
||||
StateColor bg_color = StateColor(
|
||||
std::pair{wxColour(0, 174, 66), (int) StateColor::Hovered},
|
||||
std::pair{wxColour(0,174, 66), (int) StateColor::Normal});
|
||||
//std::pair{wxColour(0, 174, 66), (int) StateColor::Hovered},
|
||||
std::pair{ wxColour(0x9A5F21), (int) StateColor::Hovered},
|
||||
//std::pair{wxColour(0,174, 66), (int) StateColor::Normal});
|
||||
std::pair{ wxColour(0x9A5F21), (int) StateColor::Normal});
|
||||
m_pageButtons[m_selection]->SetBackgroundColor(bg_color);
|
||||
|
||||
StateColor text_color = StateColor(
|
||||
|
|
|
@ -42,7 +42,8 @@ static const char g_min_cluster_color = 1;
|
|||
static const char g_max_color = 16;
|
||||
const StateColor ok_btn_bg(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
const StateColor ok_btn_disable_bg(std::pair<wxColour, int>(wxColour(205, 201, 201), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(205, 201, 201), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(205, 201, 201), StateColor::Normal));
|
||||
|
@ -52,7 +53,8 @@ wxBoxSizer* ObjColorDialog::create_btn_sizer(long flags)
|
|||
btn_sizer->AddStretchSpacer();
|
||||
|
||||
StateColor ok_btn_bd(
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
StateColor ok_btn_text(
|
||||
std::pair<wxColour, int>(wxColour(255, 255, 254), StateColor::Normal)
|
||||
|
@ -71,10 +73,12 @@ wxBoxSizer* ObjColorDialog::create_btn_sizer(long flags)
|
|||
StateColor calc_btn_bg(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
StateColor calc_btn_bd(
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
StateColor calc_btn_text(
|
||||
std::pair<wxColour, int>(wxColour(255, 255, 254), StateColor::Normal)
|
||||
|
@ -396,8 +400,10 @@ wxBoxSizer *ObjColorPanel::create_approximate_match_btn_sizer(wxWindow *parent)
|
|||
{
|
||||
auto btn_sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
StateColor calc_btn_bg(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
//StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
StateColor calc_btn_text(std::pair<wxColour, int>(wxColour(255, 255, 254), StateColor::Normal));
|
||||
//create btn
|
||||
m_quick_approximate_match_btn = new Button(parent, _L("Color match"));
|
||||
|
@ -421,8 +427,10 @@ wxBoxSizer *ObjColorPanel::create_add_btn_sizer(wxWindow *parent)
|
|||
{
|
||||
auto btn_sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
StateColor calc_btn_bg(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
//StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
StateColor calc_btn_text(std::pair<wxColour, int>(wxColour(255, 255, 254), StateColor::Normal));
|
||||
// create btn
|
||||
m_quick_add_btn = new Button(parent, _L("Append"));
|
||||
|
@ -446,8 +454,10 @@ wxBoxSizer *ObjColorPanel::create_reset_btn_sizer(wxWindow *parent)
|
|||
{
|
||||
auto btn_sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
StateColor calc_btn_bg(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
//StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor calc_btn_bd(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
StateColor calc_btn_text(std::pair<wxColour, int>(wxColour(255, 255, 254), StateColor::Normal));
|
||||
// create btn
|
||||
m_quick_reset_btn = new Button(parent, _L("Reset"));
|
||||
|
|
|
@ -62,10 +62,12 @@ TipsDialog::TipsDialog(wxWindow *parent, const wxString &title, const wxString &
|
|||
|
||||
m_confirm = new Button(this, _L("OK"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_confirm->SetBackgroundColor(btn_bg_green);
|
||||
m_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_confirm->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_confirm->SetTextColor(wxColour(255, 255, 255));
|
||||
m_confirm->SetSize(TIPS_DIALOG_BUTTON_SIZE);
|
||||
m_confirm->SetMinSize(TIPS_DIALOG_BUTTON_SIZE);
|
||||
|
|
|
@ -451,7 +451,8 @@ PlateSettingsDialog::PlateSettingsDialog(wxWindow* parent, const wxString& title
|
|||
|
||||
auto sizer_button = new wxBoxSizer(wxHORIZONTAL);
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
|
||||
|
@ -656,7 +657,8 @@ PlateNameEditDialog::PlateNameEditDialog(wxWindow *parent, wxWindowID id, const
|
|||
|
||||
auto sizer_button = new wxBoxSizer(wxHORIZONTAL);
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(*wxWHITE, StateColor::Normal));
|
||||
|
|
|
@ -845,8 +845,10 @@ Sidebar::Sidebar(Plater *parent)
|
|||
std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(107, 107, 106), StateColor::Normal));
|
||||
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
//StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Pressed),
|
||||
StateColor flush_bd_col(std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Pressed),
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(172, 172, 172), StateColor::Normal));
|
||||
|
||||
p->m_flushing_volume_btn->SetBackgroundColor(flush_bg_col);
|
||||
|
@ -9768,6 +9770,7 @@ void Plater::calib_max_vol_speed(const Calib_Params ¶ms)
|
|||
|
||||
auto new_params = params;
|
||||
auto mm3_per_mm = Flow(line_width, layer_height, nozzle_diameter).mm3_per_mm() * filament_config->option<ConfigOptionFloats>("filament_flow_ratio")->get_at(0);
|
||||
//auto mm3_per_mm = Flow(line_width, layer_height, nozzle_diameter).mm3_per_mm() * filament_config->option<ConfigOptionFloats>("fibre_feed_rate")->get_at(0);
|
||||
new_params.end = params.end / mm3_per_mm;
|
||||
new_params.start = params.start / mm3_per_mm;
|
||||
new_params.step = params.step / mm3_per_mm;
|
||||
|
@ -9782,7 +9785,6 @@ void Plater::calib_retraction(const Calib_Params ¶ms)
|
|||
js["cali_type"] = "third_cali_retraction";
|
||||
std::string filament_id = wxGetApp().preset_bundle->filaments.get_edited_preset().filament_id;
|
||||
js["filament_id"] = filament_id;
|
||||
|
||||
NetworkAgent *agent = GUI::wxGetApp().getAgent();
|
||||
if (agent) agent->track_event("third_cali", js.dump());
|
||||
} catch (...) {}
|
||||
|
@ -10216,10 +10218,12 @@ ProjectDropDialog::ProjectDropDialog(const std::string &filename)
|
|||
|
||||
m_confirm = new Button(this, _L("OK"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_confirm->SetBackgroundColor(btn_bg_green);
|
||||
m_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_confirm->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_confirm->SetTextColor(wxColour("#FFFFFE"));
|
||||
m_confirm->SetSize(PROJECT_DROP_DIALOG_BUTTON_SIZE);
|
||||
m_confirm->SetMinSize(PROJECT_DROP_DIALOG_BUTTON_SIZE);
|
||||
|
|
|
@ -67,7 +67,8 @@ PrivacyUpdateDialog::PrivacyUpdateDialog(wxWindow* parent, wxWindowID id, const
|
|||
|
||||
auto sizer_button = new wxBoxSizer(wxHORIZONTAL);
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
StateColor btn_bg_white(std::pair<wxColour, int>(wxColour(206, 206, 206), StateColor::Pressed), std::pair<wxColour, int>(wxColour(220, 220, 220), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(238, 238, 238), StateColor::Normal));
|
||||
|
|
|
@ -37,7 +37,8 @@
|
|||
#define AUFILE_GREY500 wxColour(158, 158, 158)
|
||||
#define AUFILE_GREY300 wxColour(238, 238, 238)
|
||||
#define AUFILE_GREY200 wxColour(248, 248, 248)
|
||||
#define AUFILE_BRAND wxColour(0, 174, 66)
|
||||
//#define AUFILE_BRAND wxColour(0, 174, 66)
|
||||
#define AUFILE_BRAND wxColour(0x9A5F21)
|
||||
#define AUFILE_BRAND_TRANSPARENT wxColour(215, 232, 222)
|
||||
//#define AUFILE_PICTURES_SIZE wxSize(FromDIP(300), FromDIP(300))
|
||||
//#define AUFILE_PICTURES_PANEL_SIZE wxSize(FromDIP(300), FromDIP(340))
|
||||
|
|
|
@ -95,7 +95,8 @@ PublishDialog::PublishDialog(Plater *plater)
|
|||
std::pair<wxColour, int>(TEXT_LIGHT_GRAY, StateColor::Normal));
|
||||
m_btn_cancel->SetFont(Label::Body_12);
|
||||
m_btn_cancel->SetBackgroundColor(btn_bg_green);
|
||||
m_btn_cancel->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_btn_cancel->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_btn_cancel->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_btn_cancel->SetTextColor(text_color);
|
||||
m_btn_cancel->SetSize(wxSize(FromDIP(60), FromDIP(20)));
|
||||
m_btn_cancel->SetMinSize(wxSize(FromDIP(60), FromDIP(20)));
|
||||
|
|
|
@ -35,9 +35,11 @@ RecenterDialog::RecenterDialog(wxWindow* parent, wxWindowID id, const wxString&
|
|||
m_button_confirm->SetMinSize(wxSize(-1, FromDIP(24)));
|
||||
m_button_confirm->SetCornerRadius(FromDIP(12));
|
||||
StateColor confirm_btn_bg(std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_confirm->SetBackgroundColor(confirm_btn_bg);
|
||||
m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_button_confirm->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_button_confirm->SetTextColor(*wxWHITE);
|
||||
|
||||
m_button_close = new Button(this, _L("Close"));
|
||||
|
|
|
@ -352,9 +352,11 @@ void SavePresetDialog::build(std::vector<Preset::Type> types, std::string suffix
|
|||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
StateColor btn_br_green(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_confirm->SetBackgroundColor(btn_bg_green);
|
||||
m_confirm->SetBorderColor(btn_br_green);
|
||||
m_confirm->SetTextColor(wxColour("#FFFFFE"));
|
||||
|
|
|
@ -1138,7 +1138,8 @@ SelectMachineDialog::SelectMachineDialog(Plater *plater)
|
|||
m_sizer_backup = new wxBoxSizer(wxHORIZONTAL);
|
||||
m_ams_backup_tip = new Label(this, _L("Auto Refill"));
|
||||
m_ams_backup_tip->SetFont(::Label::Head_12);
|
||||
m_ams_backup_tip->SetForegroundColour(wxColour(0x00AE42));
|
||||
//m_ams_backup_tip->SetForegroundColour(wxColour(0x00AE42));
|
||||
m_ams_backup_tip->SetForegroundColour(wxColour(0x9A5F21));
|
||||
m_ams_backup_tip->SetBackgroundColour(*wxWHITE);
|
||||
img_ams_backup = new wxStaticBitmap(this, wxID_ANY, create_scaled_bitmap("automatic_material_renewal", this, 16), wxDefaultPosition, wxSize(FromDIP(16), FromDIP(16)), 0);
|
||||
img_ams_backup->SetBackgroundColour(*wxWHITE);
|
||||
|
@ -1183,7 +1184,8 @@ SelectMachineDialog::SelectMachineDialog(Plater *plater)
|
|||
|
||||
m_sizer_printer->Add(m_comboBox_printer, 1, wxEXPAND | wxRIGHT, FromDIP(5));
|
||||
m_btn_bg_enable = StateColor(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_button_refresh = new Button(this, _L("Refresh"));
|
||||
m_button_refresh->SetBackgroundColor(m_btn_bg_enable);
|
||||
|
@ -1275,7 +1277,8 @@ SelectMachineDialog::SelectMachineDialog(Plater *plater)
|
|||
|
||||
m_statictext_finish = new wxStaticText(m_panel_finish, wxID_ANY, L("send completed"), wxDefaultPosition, wxDefaultSize, 0);
|
||||
m_statictext_finish->Wrap(-1);
|
||||
m_statictext_finish->SetForegroundColour(wxColour(0, 174, 66));
|
||||
//m_statictext_finish->SetForegroundColour(wxColour(0, 174, 66));
|
||||
m_statictext_finish->SetForegroundColour(wxColour(0x9A5F21));
|
||||
m_sizer_finish_h->Add(m_statictext_finish, 0, wxALIGN_CENTER | wxALL, FromDIP(5));
|
||||
|
||||
m_sizer_finish_v->Add(m_sizer_finish_h, 1, wxALIGN_CENTER, 0);
|
||||
|
@ -2685,7 +2688,8 @@ wxString SelectMachineDialog::format_steel_name(std::string name)
|
|||
void SelectMachineDialog::Enable_Auto_Refill(bool enable)
|
||||
{
|
||||
if (enable) {
|
||||
m_ams_backup_tip->SetForegroundColour(wxColour(0x00AE42));
|
||||
//m_ams_backup_tip->SetForegroundColour(wxColour(0x00AE42));
|
||||
m_ams_backup_tip->SetForegroundColour(wxColour(0x9A5F21));
|
||||
}
|
||||
else {
|
||||
m_ams_backup_tip->SetForegroundColour(wxColour(0x90, 0x90, 0x90));
|
||||
|
@ -4720,9 +4724,11 @@ EditDevNameDialog::EditDevNameDialog(Plater *plater /*= nullptr*/)
|
|||
|
||||
|
||||
m_button_confirm = new Button(this, _L("Confirm"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
m_button_confirm->SetBackgroundColor(btn_bg_green);
|
||||
m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
//m_button_confirm->SetBorderColor(wxColour(0, 174, 66));
|
||||
m_button_confirm->SetBorderColor(wxColour(0x9A5F21));
|
||||
m_button_confirm->SetTextColor(wxColour(255, 255, 255));
|
||||
m_button_confirm->SetSize(wxSize(FromDIP(72), FromDIP(24)));
|
||||
m_button_confirm->SetMinSize(wxSize(FromDIP(72), FromDIP(24)));
|
||||
|
|
|
@ -197,7 +197,8 @@ protected:
|
|||
#define SELECT_MACHINE_GREY900 wxColour(38, 46, 48)
|
||||
#define SELECT_MACHINE_GREY600 wxColour(144,144,144)
|
||||
#define SELECT_MACHINE_GREY400 wxColour(206, 206, 206)
|
||||
#define SELECT_MACHINE_BRAND wxColour(0, 174, 66)
|
||||
//#define SELECT_MACHINE_BRAND wxColour(0, 174, 66)
|
||||
#define SELECT_MACHINE_BRAND wxColour(0x9A5F21)
|
||||
#define SELECT_MACHINE_REMIND wxColour(255,111,0)
|
||||
#define SELECT_MACHINE_LIGHT_GREEN wxColour(219, 253, 231)
|
||||
|
||||
|
|
|
@ -207,7 +207,8 @@ void SendDeviceItem::doRender(wxDC& dc)
|
|||
|
||||
//device state
|
||||
if (state_printable <= 2) {
|
||||
dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
//dc.SetTextForeground(wxColour(0, 174, 66));
|
||||
dc.SetTextForeground(wxColour(0x9A5F21));
|
||||
}
|
||||
else {
|
||||
dc.SetTextForeground(wxColour(208, 27, 27));
|
||||
|
@ -232,7 +233,8 @@ void SendDeviceItem::doRender(wxDC& dc)
|
|||
}
|
||||
|
||||
if (m_hover) {
|
||||
dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
//dc.SetPen(wxPen(wxColour(0, 174, 66)));
|
||||
dc.SetPen(wxPen(wxColour(0x9A5F21)));
|
||||
dc.SetBrush(*wxTRANSPARENT_BRUSH);
|
||||
dc.DrawRoundedRectangle(0, 0, size.x, size.y, 3);
|
||||
}
|
||||
|
@ -1265,7 +1267,8 @@ wxPanel* SendMultiMachinePage::create_page()
|
|||
auto m_btn_bg_enable = StateColor(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
m_button_add = new Button(main_page, _L("Add"));
|
||||
|
@ -1326,7 +1329,8 @@ wxPanel* SendMultiMachinePage::create_page()
|
|||
|
||||
// add send button
|
||||
btn_bg_enable = StateColor(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_button_send = new Button(main_page, _L("Send"));
|
||||
m_button_send->SetBackgroundColor(btn_bg_enable);
|
||||
|
|
|
@ -250,7 +250,8 @@ SendToPrinterDialog::SendToPrinterDialog(Plater *plater)
|
|||
|
||||
m_sizer_printer->Add(m_comboBox_printer, 1, wxEXPAND | wxRIGHT, FromDIP(5));
|
||||
btn_bg_enable = StateColor(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
m_button_refresh = new Button(this, _L("Refresh"));
|
||||
m_button_refresh->SetBackgroundColor(btn_bg_enable);
|
||||
|
@ -314,7 +315,8 @@ SendToPrinterDialog::SendToPrinterDialog(Plater *plater)
|
|||
|
||||
m_statictext_finish = new wxStaticText(m_panel_finish, wxID_ANY, L("send completed"), wxDefaultPosition, wxDefaultSize, 0);
|
||||
m_statictext_finish->Wrap(-1);
|
||||
m_statictext_finish->SetForegroundColour(wxColour(0, 174, 66));
|
||||
//m_statictext_finish->SetForegroundColour(wxColour(0, 174, 66));
|
||||
m_statictext_finish->SetForegroundColour(wxColour(0x9A5F21));
|
||||
m_sizer_finish_h->Add(m_statictext_finish, 0, wxALIGN_CENTER | wxALL, FromDIP(5));
|
||||
|
||||
m_sizer_finish_v->Add(m_sizer_finish_h, 1, wxALIGN_CENTER, 0);
|
||||
|
|
|
@ -366,7 +366,8 @@ void Slic3r::GUI::NotificationManager::SlicingProgressNotification::render_bar(c
|
|||
|
||||
ImGuiWrapper& imgui = *wxGetApp().imgui();
|
||||
|
||||
ImColor progress_color = ImColor(0, 174, 66, (int)(255 * m_current_fade_opacity));
|
||||
//ImColor progress_color = ImColor(0, 174, 66, (int)(255 * m_current_fade_opacity));
|
||||
ImColor progress_color = ImColor(33, 95, 154, (int)(255 * m_current_fade_opacity));
|
||||
ImColor bg_color = ImColor(217, 217, 217, (int)(255 * m_current_fade_opacity));
|
||||
|
||||
ImVec2 lineStart = pos;
|
||||
|
|
|
@ -46,13 +46,15 @@ static const wxColour STATIC_BOX_LINE_COL = wxColour(238, 238, 238);
|
|||
static const wxColour BUTTON_NORMAL1_COL = wxColour(238, 238, 238);
|
||||
static const wxColour BUTTON_NORMAL2_COL = wxColour(206, 206, 206);
|
||||
static const wxColour BUTTON_PRESS_COL = wxColour(172, 172, 172);
|
||||
static const wxColour BUTTON_HOVER_COL = wxColour(0, 174, 66);
|
||||
//static const wxColour BUTTON_HOVER_COL = wxColour(0, 174, 66);
|
||||
static const wxColour BUTTON_HOVER_COL = wxColour(0x9A5F21);
|
||||
|
||||
static const wxColour DISCONNECT_TEXT_COL = wxColour(171, 172, 172);
|
||||
static const wxColour NORMAL_TEXT_COL = wxColour(48,58,60);
|
||||
static const wxColour NORMAL_FAN_TEXT_COL = wxColour(107, 107, 107);
|
||||
static const wxColour WARNING_INFO_BG_COL = wxColour(255, 111, 0);
|
||||
static const wxColour STAGE_TEXT_COL = wxColour(0, 174, 66);
|
||||
//static const wxColour STAGE_TEXT_COL = wxColour(0, 174, 66);
|
||||
static const wxColour STAGE_TEXT_COL = wxColour(0x9A5F21);
|
||||
|
||||
static const wxColour GROUP_STATIC_LINE_COL = wxColour(206, 206, 206);
|
||||
|
||||
|
@ -336,12 +338,14 @@ void PrintingTaskPanel::create_panel(wxWindow* parent)
|
|||
m_staticText_progress_percent = new wxStaticText(penel_text, wxID_ANY, "0", wxDefaultPosition, wxDefaultSize, 0);
|
||||
m_staticText_progress_percent->SetFont(::Label::Head_18);
|
||||
m_staticText_progress_percent->SetMaxSize(wxSize(-1, FromDIP(20)));
|
||||
m_staticText_progress_percent->SetForegroundColour(wxColour(0, 174, 66));
|
||||
//m_staticText_progress_percent->SetForegroundColour(wxColour(0, 174, 66));
|
||||
m_staticText_progress_percent->SetForegroundColour(wxColour(0x9A5F21));
|
||||
|
||||
m_staticText_progress_percent_icon = new wxStaticText(penel_text, wxID_ANY, "%", wxDefaultPosition, wxDefaultSize, 0);
|
||||
m_staticText_progress_percent_icon->SetFont(::Label::Body_11);
|
||||
m_staticText_progress_percent_icon->SetMaxSize(wxSize(-1, FromDIP(13)));
|
||||
m_staticText_progress_percent_icon->SetForegroundColour(wxColour(0, 174, 66));
|
||||
//m_staticText_progress_percent_icon->SetForegroundColour(wxColour(0, 174, 66));
|
||||
m_staticText_progress_percent_icon->SetForegroundColour(wxColour(0x9A5F21));
|
||||
|
||||
sizer_percent->Add(m_staticText_progress_percent, 0, 0, 0);
|
||||
|
||||
|
@ -1231,7 +1235,8 @@ wxBoxSizer *StatusBasePanel::create_misc_control(wxWindow *parent)
|
|||
m_switch_nozzle_fan->SetTextColor(StateColor(std::make_pair(DISCONNECT_TEXT_COL, (int) StateColor::Disabled), std::make_pair(NORMAL_FAN_TEXT_COL, (int) StateColor::Normal)));
|
||||
|
||||
m_switch_nozzle_fan->Bind(wxEVT_ENTER_WINDOW, [this](auto& e) {
|
||||
m_fan_panel->SetBackgroundColor(wxColour(0, 174, 66));
|
||||
//m_fan_panel->SetBackgroundColor(wxColour(0, 174, 66));
|
||||
m_fan_panel->SetBackgroundColor(wxColour(0x9A5F21));
|
||||
});
|
||||
|
||||
m_switch_nozzle_fan->Bind(wxEVT_LEAVE_WINDOW, [this, parent](auto& e) {
|
||||
|
@ -1251,7 +1256,8 @@ wxBoxSizer *StatusBasePanel::create_misc_control(wxWindow *parent)
|
|||
StateColor(std::make_pair(DISCONNECT_TEXT_COL, (int) StateColor::Disabled), std::make_pair(NORMAL_FAN_TEXT_COL, (int) StateColor::Normal)));
|
||||
|
||||
m_switch_printing_fan->Bind(wxEVT_ENTER_WINDOW, [this](auto& e) {
|
||||
m_fan_panel->SetBackgroundColor(wxColour(0, 174, 66));
|
||||
//m_fan_panel->SetBackgroundColor(wxColour(0, 174, 66));
|
||||
m_fan_panel->SetBackgroundColor(wxColour(0x9A5F21));
|
||||
});
|
||||
|
||||
m_switch_printing_fan->Bind(wxEVT_LEAVE_WINDOW, [this, parent](auto& e) {
|
||||
|
@ -1271,7 +1277,8 @@ wxBoxSizer *StatusBasePanel::create_misc_control(wxWindow *parent)
|
|||
StateColor(std::make_pair(DISCONNECT_TEXT_COL, (int)StateColor::Disabled), std::make_pair(NORMAL_FAN_TEXT_COL, (int)StateColor::Normal)));
|
||||
|
||||
m_switch_cham_fan->Bind(wxEVT_ENTER_WINDOW, [this](auto& e) {
|
||||
m_fan_panel->SetBackgroundColor(wxColour(0, 174, 66));
|
||||
//m_fan_panel->SetBackgroundColor(wxColour(0, 174, 66));
|
||||
m_fan_panel->SetBackgroundColor(wxColour(0x9A5F21));
|
||||
});
|
||||
|
||||
m_switch_cham_fan->Bind(wxEVT_LEAVE_WINDOW, [this, parent](auto& e) {
|
||||
|
|
|
@ -14,7 +14,8 @@ EVT_PAINT(TabButton::paintEvent)
|
|||
|
||||
END_EVENT_TABLE()
|
||||
|
||||
static wxColour BORDER_HOVER_COL = wxColour(0, 174, 66);
|
||||
//static wxColour BORDER_HOVER_COL = wxColour(0, 174, 66);
|
||||
static wxColour BORDER_HOVER_COL = wxColour(0x9A5F21);
|
||||
|
||||
const static wxColour TAB_BUTTON_BG = wxColour("#FEFFFF");
|
||||
const static wxColour TAB_BUTTON_SEL = wxColour(219, 253, 213, 255);
|
||||
|
|
|
@ -976,7 +976,8 @@ void UnsavedChangesDialog::build(Preset::Type type, PresetCollection *dependent_
|
|||
// Add Buttons
|
||||
wxFont btn_font = this->GetFont().Scaled(1.4f);
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed), std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
|
||||
auto add_btn = [this, m_sizer_button, btn_font, dependent_presets, btn_bg_green](Button **btn, int &btn_id, const std::string &icon_name, Action close_act, const wxString &label,
|
||||
bool focus, bool process_enable = true) {
|
||||
|
@ -984,7 +985,8 @@ void UnsavedChangesDialog::build(Preset::Type type, PresetCollection *dependent_
|
|||
|
||||
if (focus) {
|
||||
(*btn)->SetBackgroundColor(btn_bg_green);
|
||||
(*btn)->SetBorderColor(wxColour(0, 174, 66));
|
||||
//(*btn)->SetBorderColor(wxColour(0, 174, 66));
|
||||
(*btn)->SetBorderColor(wxColour(0x9A5F21));
|
||||
(*btn)->SetTextColor(wxColour("#FFFFFE"));
|
||||
} else {
|
||||
(*btn)->SetTextColor(wxColour(107, 107, 107));
|
||||
|
|
|
@ -9,7 +9,8 @@
|
|||
namespace Slic3r {
|
||||
namespace GUI {
|
||||
|
||||
static const wxColour TEXT_NORMAL_CLR = wxColour(0, 174, 66);
|
||||
//static const wxColour TEXT_NORMAL_CLR = wxColour(0, 174, 66);
|
||||
static const wxColour TEXT_NORMAL_CLR = wxColour(0x9A5F21);
|
||||
static const wxColour TEXT_FAILED_CLR = wxColour(255, 111, 0);
|
||||
|
||||
enum FIRMWARE_STASUS
|
||||
|
@ -208,9 +209,12 @@ MachineInfoPanel::MachineInfoPanel(wxWindow* parent, wxWindowID id, const wxPoin
|
|||
|
||||
m_button_upgrade_firmware = new Button(this, _L("Update firmware"));
|
||||
StateColor btn_bg(std::pair<wxColour, int>(wxColour(255, 255, 255), StateColor::Disabled), std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
StateColor btn_bd(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled));
|
||||
//std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Enabled),
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal));
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal));
|
||||
//StateColor btn_bd(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled), std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Enabled));
|
||||
StateColor btn_bd(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled), std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Enabled));
|
||||
StateColor btn_text(std::pair<wxColour, int>(wxColour(144, 144, 144), StateColor::Disabled), std::pair<wxColour, int>(wxColour(255, 255, 255), StateColor::Enabled));
|
||||
m_button_upgrade_firmware->SetBackgroundColor(btn_bg);
|
||||
m_button_upgrade_firmware->SetBorderColor(btn_bd);
|
||||
|
|
|
@ -2446,7 +2446,8 @@ AMSControl::AMSControl(wxWindow *parent, wxWindowID id, const wxPoint &pos, cons
|
|||
//backup tips
|
||||
m_ams_backup_tip = new Label(m_amswin, _L("Auto Refill"));
|
||||
m_ams_backup_tip->SetFont(::Label::Head_12);
|
||||
m_ams_backup_tip->SetForegroundColour(wxColour(0x00AE42));
|
||||
//m_ams_backup_tip->SetForegroundColour(wxColour(0x00AE42));
|
||||
m_ams_backup_tip->SetForegroundColour(wxColour(0x9A5F21));
|
||||
m_ams_backup_tip->SetBackgroundColour(*wxWHITE);
|
||||
m_img_ams_backup = new wxStaticBitmap(m_amswin, wxID_ANY, create_scaled_bitmap("automatic_material_renewal", this, 16), wxDefaultPosition, wxSize(FromDIP(16), FromDIP(16)), 0);
|
||||
m_img_ams_backup->SetBackgroundColour(*wxWHITE);
|
||||
|
|
|
@ -13,7 +13,8 @@
|
|||
#include <wx/animate.h>
|
||||
#include <wx/dynarray.h>
|
||||
|
||||
#define AMS_CONTROL_BRAND_COLOUR wxColour(0, 174, 66)
|
||||
//#define AMS_CONTROL_BRAND_COLOUR wxColour(0, 174, 66)
|
||||
#define AMS_CONTROL_BRAND_COLOUR wxColour(0x9A5F21)
|
||||
#define AMS_CONTROL_GRAY700 wxColour(107, 107, 107)
|
||||
#define AMS_CONTROL_GRAY800 wxColour(50, 58, 61)
|
||||
#define AMS_CONTROL_GRAY500 wxColour(172, 172, 172)
|
||||
|
|
|
@ -9,7 +9,8 @@ StateColor blank_bg(StateColor(std::make_pair(wxColour("#FFFFFF"), (int)StateCol
|
|||
static const wxColour BUTTON_BG_COL = wxColour("#EEEEEE");
|
||||
static const wxColour BUTTON_IN_BG_COL = wxColour("#CECECE");
|
||||
|
||||
static const wxColour bd = wxColour(0, 174, 66);
|
||||
//static const wxColour bd = wxColour(0, 174, 66);
|
||||
static const wxColour bd = wxColour(0x9A5F21);
|
||||
static const wxColour text_num_color = wxColour(0x898989);
|
||||
static const wxColour BUTTON_PRESS_COL = wxColour(172, 172, 172);
|
||||
static const double sqrt2 = std::sqrt(2);
|
||||
|
|
|
@ -29,8 +29,8 @@ Button::Button()
|
|||
background_color = StateColor(
|
||||
std::make_pair(0xF0F0F1, (int) StateColor::Disabled),
|
||||
std::make_pair(0x37EE7C, (int) StateColor::Hovered | StateColor::Checked),
|
||||
std::make_pair(0x00AE42, (int) StateColor::Checked),
|
||||
//std::make_pair(0x009FF3, (int) StateColor::Checked),
|
||||
//std::make_pair(0x00AE42, (int) StateColor::Checked),
|
||||
std::make_pair(0x215F9A, (int) StateColor::Checked),
|
||||
std::make_pair(*wxLIGHT_GREY, (int) StateColor::Hovered),
|
||||
std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
text_color = StateColor(
|
||||
|
|
|
@ -52,7 +52,8 @@ ComboBox::ComboBox(wxWindow *parent,
|
|||
GetTextCtrl()->Hide();
|
||||
TextInput::SetFont(Label::Body_14);
|
||||
TextInput::SetBorderColor(StateColor(std::make_pair(0xDBDBDB, (int) StateColor::Disabled),
|
||||
std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
//std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
std::make_pair(0x215F9A, (int) StateColor::Hovered),
|
||||
std::make_pair(0xDBDBDB, (int) StateColor::Normal)));
|
||||
TextInput::SetBackgroundColor(StateColor(std::make_pair(0xF0F0F1, (int) StateColor::Disabled),
|
||||
std::make_pair(0xEDFAF2, (int) StateColor::Focused),
|
||||
|
|
|
@ -39,7 +39,8 @@ DropDown::DropDown(std::vector<wxString> &texts,
|
|||
, state_handler(this)
|
||||
, border_color(0xDBDBDB)
|
||||
, text_color(0x363636)
|
||||
, selector_border_color(std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
//, selector_border_color(std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
, selector_border_color(std::make_pair(0x215F9A, (int) StateColor::Hovered),
|
||||
std::make_pair(*wxWHITE, (int) StateColor::Normal))
|
||||
, selector_background_color(std::make_pair(0xEDFAF2, (int) StateColor::Checked),
|
||||
std::make_pair(*wxWHITE, (int) StateColor::Normal))
|
||||
|
|
|
@ -26,7 +26,8 @@ EVT_PAINT(FanSwitchButton::paintEvent)
|
|||
|
||||
END_EVENT_TABLE()
|
||||
|
||||
static const wxColour DEFAULT_HOVER_COL = wxColour(0, 174, 66);
|
||||
//static const wxColour DEFAULT_HOVER_COL = wxColour(0, 174, 66);
|
||||
static const wxColour DEFAULT_HOVER_COL = wxColour(0x9A5F21);
|
||||
static const wxColour DEFAULT_PRESS_COL = wxColour(238, 238, 238);
|
||||
|
||||
ImageSwitchButton::ImageSwitchButton(wxWindow *parent, ScalableBitmap &img_on, ScalableBitmap &img_off, long style)
|
||||
|
|
|
@ -30,7 +30,8 @@ public:
|
|||
double m_radius = {7};
|
||||
double m_proportion = {0};
|
||||
wxColour m_progress_background_colour = {233, 233, 233};
|
||||
wxColour m_progress_colour = {0, 174, 66};
|
||||
//wxColour m_progress_colour = {0, 174, 66};
|
||||
wxColour m_progress_colour = {33, 95, 154};
|
||||
wxColour m_progress_colour_disable = {255, 111, 0};
|
||||
wxString m_disable_text;
|
||||
|
||||
|
|
|
@ -31,7 +31,8 @@ SideButton::SideButton(wxWindow* parent, wxString text, wxString icon, long stly
|
|||
border_color.append(0x6B6B6B, StateColor::Disabled);
|
||||
border_color.append(wxColour(23, 129, 63), StateColor::Pressed);
|
||||
border_color.append(wxColour(48,221,112), StateColor::Hovered);
|
||||
border_color.append(0x00AE42, StateColor::Normal);
|
||||
//border_color.append(0x00AE42, StateColor::Normal);
|
||||
border_color.append(0x215F9A, StateColor::Normal);
|
||||
border_color.setTakeFocusedAsHovered(false);
|
||||
|
||||
text_color.append(0xACACAC, StateColor::Disabled);
|
||||
|
@ -41,8 +42,10 @@ SideButton::SideButton(wxWindow* parent, wxString text, wxString icon, long stly
|
|||
|
||||
background_color.append(0x6B6B6B, StateColor::Disabled);
|
||||
background_color.append(wxColour(23, 129, 63), StateColor::Pressed);
|
||||
background_color.append(wxColour(48, 221, 112), StateColor::Hovered);
|
||||
background_color.append(0x00AE42, StateColor::Normal);
|
||||
//background_color.append(wxColour(48, 221, 112), StateColor::Hovered);
|
||||
background_color.append(0x0073BC, StateColor::Hovered);
|
||||
//background_color.append(0x00AE42, StateColor::Normal);
|
||||
background_color.append(0x215F9A, StateColor::Normal);
|
||||
background_color.setTakeFocusedAsHovered(false);
|
||||
|
||||
SetBottomColour(wxColour("#3B4446"));
|
||||
|
|
|
@ -523,8 +523,10 @@ void SideTools::show_status(int status)
|
|||
else if ((status & (int)MonitorStatus::MONITOR_CONNECTING) != 0) {
|
||||
m_hyperlink->Hide();
|
||||
m_connection_info->SetLabel(_L("Connecting..."));
|
||||
m_connection_info->SetBackgroundColor(0x00AE42);
|
||||
m_connection_info->SetBorderColor(0x00AE42);
|
||||
//m_connection_info->SetBackgroundColor(0x00AE42);
|
||||
m_connection_info->SetBackgroundColor(0x9A5F21);
|
||||
//m_connection_info->SetBorderColor(0x00AE42);
|
||||
m_connection_info->SetBorderColor(0x9A5F21);
|
||||
m_connection_info->Show();
|
||||
m_more_button->Hide();
|
||||
m_side_error_panel->Hide();
|
||||
|
|
|
@ -14,7 +14,8 @@
|
|||
#define SIDE_TOOLS_GREY900 wxColour(38, 46, 48)
|
||||
#define SIDE_TOOLS_GREY600 wxColour(144, 144, 144)
|
||||
#define SIDE_TOOLS_GREY400 wxColour(206, 206, 206)
|
||||
#define SIDE_TOOLS_BRAND wxColour(0, 174, 66)
|
||||
//#define SIDE_TOOLS_BRAND wxColour(0, 174, 66)
|
||||
#define SIDE_TOOLS_BRAND wxColour(0x9A5F21)
|
||||
#define SIDE_TOOLS_LIGHT_GREEN wxColour(219, 253, 231)
|
||||
|
||||
enum WifiSignal {
|
||||
|
|
|
@ -26,7 +26,8 @@ SpinInput::SpinInput()
|
|||
{
|
||||
radius = 0;
|
||||
border_width = 1;
|
||||
border_color = StateColor(std::make_pair(0xDBDBDB, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
//border_color = StateColor(std::make_pair(0xDBDBDB, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
border_color = StateColor(std::make_pair(0xDBDBDB, (int) StateColor::Disabled), std::make_pair(0x0073BC, (int) StateColor::Hovered),
|
||||
std::make_pair(0xDBDBDB, (int) StateColor::Normal));
|
||||
background_color = StateColor(std::make_pair(0xF0F0F1, (int) StateColor::Disabled), std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
}
|
||||
|
|
|
@ -23,7 +23,8 @@ StepCtrlBase::StepCtrlBase(wxWindow * parent,
|
|||
, font_tip(Label::Body_14)
|
||||
, clr_bar(0xACACAC)
|
||||
, clr_step(0xACACAC)
|
||||
, clr_text(std::make_pair(0x00AE42, (int) StateColor::Checked),
|
||||
//, clr_text(std::make_pair(0x00AE42, (int) StateColor::Checked),
|
||||
, clr_text(std::make_pair(0x215F9A, (int) StateColor::Checked),
|
||||
std::make_pair(0x6B6B6B, (int) StateColor::Normal))
|
||||
, clr_tip(0x828280)
|
||||
{
|
||||
|
@ -256,7 +257,8 @@ StepIndicator::StepIndicator(wxWindow *parent, wxWindowID id, const wxPoint &pos
|
|||
clr_bar = 0xE1E1E1;
|
||||
clr_step = StateColor(
|
||||
std::make_pair(0xACACAC, (int) StateColor::Disabled),
|
||||
std::make_pair(0x00AE42, 0));
|
||||
//std::make_pair(0x00AE42, 0));
|
||||
std::make_pair(0x215F9A, 0));
|
||||
clr_text = StateColor(
|
||||
std::make_pair(0xACACAC, (int) StateColor::Disabled),
|
||||
std::make_pair(0x323A3D, (int) StateColor::Checked),
|
||||
|
|
|
@ -303,7 +303,8 @@ void TabCtrl::doRender(wxDC& dc)
|
|||
#else
|
||||
dc.SetPen(wxPen(border_color.colorForStates(states), border_width));
|
||||
dc.DrawLine(0, size.y - BS2, size.x, size.y - BS2);
|
||||
wxColor c(0x42AE00);
|
||||
//wxColor c(0x42AE00);
|
||||
wxColor c(0x9A5F21);
|
||||
dc.SetPen(wxPen(c, 1));
|
||||
dc.SetBrush(c);
|
||||
dc.DrawRoundedRectangle(x1 - radius, size.y - BS2 - border_width * 3, x2 + radius * 2 - x1, border_width * 3, radius);
|
||||
|
|
|
@ -25,7 +25,8 @@ TempInput::TempInput()
|
|||
{
|
||||
hover = false;
|
||||
radius = 0;
|
||||
border_color = StateColor(std::make_pair(*wxWHITE, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Focused), std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
//border_color = StateColor(std::make_pair(*wxWHITE, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Focused), std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
border_color = StateColor(std::make_pair(*wxWHITE, (int) StateColor::Disabled), std::make_pair(0x215F9A, (int) StateColor::Focused), std::make_pair(0x215F9A, (int) StateColor::Hovered),
|
||||
std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
background_color = StateColor(std::make_pair(*wxWHITE, (int) StateColor::Disabled), std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
SetFont(Label::Body_12);
|
||||
|
@ -371,8 +372,10 @@ void TempInput::render(wxDC &dc)
|
|||
if (warning_mode) {
|
||||
border_color = wxColour(255, 111, 0);
|
||||
} else {
|
||||
border_color = StateColor(std::make_pair(*wxWHITE, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Focused),
|
||||
std::make_pair(0x00AE42, (int) StateColor::Hovered), std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
//border_color = StateColor(std::make_pair(*wxWHITE, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Focused),
|
||||
border_color = StateColor(std::make_pair(*wxWHITE, (int) StateColor::Disabled), std::make_pair(0x215F9A, (int) StateColor::Focused),
|
||||
//std::make_pair(0x00AE42, (int) StateColor::Hovered), std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
std::make_pair(0x215F9A, (int) StateColor::Hovered), std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
}
|
||||
|
||||
dc.SetBrush(*wxTRANSPARENT_BRUSH);
|
||||
|
|
|
@ -25,7 +25,8 @@ TextInput::TextInput()
|
|||
{
|
||||
radius = 0;
|
||||
border_width = 1;
|
||||
border_color = StateColor(std::make_pair(0xDBDBDB, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
//border_color = StateColor(std::make_pair(0xDBDBDB, (int) StateColor::Disabled), std::make_pair(0x00AE42, (int) StateColor::Hovered),
|
||||
border_color = StateColor(std::make_pair(0xDBDBDB, (int) StateColor::Disabled), std::make_pair(0x215F9A, (int) StateColor::Hovered),
|
||||
std::make_pair(0xDBDBDB, (int) StateColor::Normal));
|
||||
background_color = StateColor(std::make_pair(0xF0F0F1, (int) StateColor::Disabled), std::make_pair(*wxWHITE, (int) StateColor::Normal));
|
||||
SetFont(Label::Body_12);
|
||||
|
|
|
@ -61,11 +61,13 @@ wxBoxSizer* WipingDialog::create_btn_sizer(long flags)
|
|||
StateColor ok_btn_bg(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor ok_btn_bd(
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor ok_btn_text(
|
||||
|
@ -90,11 +92,13 @@ wxBoxSizer* WipingDialog::create_btn_sizer(long flags)
|
|||
StateColor calc_btn_bg(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor calc_btn_bd(
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor calc_btn_text(
|
||||
|
@ -146,11 +150,13 @@ wxBoxSizer* WipingPanel::create_calc_btn_sizer(wxWindow* parent) {
|
|||
StateColor calc_btn_bg(
|
||||
std::pair<wxColour, int>(wxColour(27, 136, 68), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(61, 203, 115), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor calc_btn_bd(
|
||||
std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
//std::pair<wxColour, int>(wxColour(0, 174, 66), StateColor::Normal)
|
||||
std::pair<wxColour, int>(wxColour(0x9A5F21), StateColor::Normal)
|
||||
);
|
||||
|
||||
StateColor calc_btn_text(
|
||||
|
|
|
@ -108,8 +108,10 @@ PA_Calibration_Dlg::PA_Calibration_Dlg(wxWindow* parent, wxWindowID id, Plater*
|
|||
m_btnStart = new Button(this, _L("OK"));
|
||||
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(23, 129, 63), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x0073BC, StateColor::Hovered),
|
||||
//std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
std::pair<wxColour, int>(0x215F9A, StateColor::Normal));
|
||||
|
||||
m_btnStart->SetBackgroundColor(btn_bg_green);
|
||||
m_btnStart->SetBorderColor(wxColour(0, 150, 136));
|
||||
|
@ -317,8 +319,10 @@ Temp_Calibration_Dlg::Temp_Calibration_Dlg(wxWindow* parent, wxWindowID id, Plat
|
|||
v_sizer->Add(0, FromDIP(10), 0, wxEXPAND, 5);
|
||||
m_btnStart = new Button(this, _L("OK"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(23, 129, 63), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x0073BC, StateColor::Hovered),
|
||||
//std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
std::pair<wxColour, int>(0x215F9A, StateColor::Normal));
|
||||
|
||||
m_btnStart->SetBackgroundColor(btn_bg_green);
|
||||
m_btnStart->SetBorderColor(wxColour(0, 150, 136));
|
||||
|
@ -489,8 +493,10 @@ MaxVolumetricSpeed_Test_Dlg::MaxVolumetricSpeed_Test_Dlg(wxWindow* parent, wxWin
|
|||
v_sizer->Add(0, FromDIP(10), 0, wxEXPAND, 5);
|
||||
m_btnStart = new Button(this, _L("OK"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(23, 129, 63), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x0073BC, StateColor::Hovered),
|
||||
//std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
std::pair<wxColour, int>(0x215F9A, StateColor::Normal));
|
||||
|
||||
m_btnStart->SetBackgroundColor(btn_bg_green);
|
||||
m_btnStart->SetBorderColor(wxColour(0, 150, 136));
|
||||
|
@ -594,8 +600,10 @@ VFA_Test_Dlg::VFA_Test_Dlg(wxWindow* parent, wxWindowID id, Plater* plater)
|
|||
v_sizer->Add(0, FromDIP(10), 0, wxEXPAND, 5);
|
||||
m_btnStart = new Button(this, _L("OK"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(23, 129, 63), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x0073BC, StateColor::Hovered),
|
||||
//std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
std::pair<wxColour, int>(0x215F9A, StateColor::Normal));
|
||||
|
||||
m_btnStart->SetBackgroundColor(btn_bg_green);
|
||||
m_btnStart->SetBorderColor(wxColour(0, 150, 136));
|
||||
|
@ -700,8 +708,10 @@ Retraction_Test_Dlg::Retraction_Test_Dlg(wxWindow* parent, wxWindowID id, Plater
|
|||
v_sizer->Add(0, FromDIP(10), 0, wxEXPAND, 5);
|
||||
m_btnStart = new Button(this, _L("OK"));
|
||||
StateColor btn_bg_green(std::pair<wxColour, int>(wxColour(23, 129, 63), StateColor::Pressed),
|
||||
std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
//std::pair<wxColour, int>(wxColour(48, 221, 112), StateColor::Hovered),
|
||||
std::pair<wxColour, int>(0x0073BC, StateColor::Hovered),
|
||||
//std::pair<wxColour, int>(0x00AE42, StateColor::Normal));
|
||||
std::pair<wxColour, int>(0x215F9A, StateColor::Normal));
|
||||
|
||||
m_btnStart->SetBackgroundColor(btn_bg_green);
|
||||
m_btnStart->SetBorderColor(wxColour(0, 150, 136));
|
||||
|
|
|
@ -867,6 +867,7 @@ void CalibUtils::calib_max_vol_speed(const CalibInfo &calib_info, wxString &erro
|
|||
|
||||
auto new_params = params;
|
||||
auto mm3_per_mm = Flow(line_width, layer_height, nozzle_diameter).mm3_per_mm() * filament_config.option<ConfigOptionFloats>("filament_flow_ratio")->get_at(0);
|
||||
//auto mm3_per_mm = Flow(line_width, layer_height, nozzle_diameter).mm3_per_mm() * filament_config.option<ConfigOptionFloats>("fibre_feed_rate")->get_at(0);
|
||||
new_params.end = params.end / mm3_per_mm;
|
||||
new_params.start = params.start / mm3_per_mm;
|
||||
new_params.step = params.step / mm3_per_mm;
|
||||
|
|
Loading…
Reference in New Issue