Revert "Disable function "face to camera""

This reverts commit 47dd1106b4dc356f4f50681d3053a4e205ec3e0d.
This commit is contained in:
Filip Sykala - NTB T15p 2023-10-24 09:59:07 +02:00
parent c63f0d2870
commit 7324d032a1
2 changed files with 3 additions and 7 deletions

View File

@ -2952,7 +2952,6 @@ void GLGizmoEmboss::draw_advanced()
process();
}
/*
if (ImGui::Button(_u8L("Set text to face camera").c_str())) {
assert(get_selected_volume(m_parent.get_selection()) == m_volume);
const Camera &cam = wxGetApp().plater()->get_camera();
@ -2966,7 +2965,6 @@ void GLGizmoEmboss::draw_advanced()
} else if (ImGui::IsItemHovered()) {
ImGui::SetTooltip("%s", _u8L("Orient the text towards the camera.").c_str());
}
*/
//ImGui::SameLine(); if (ImGui::Button("Re-emboss")) GLGizmoEmboss::re_emboss(*m_volume);
@ -3717,9 +3715,9 @@ GuiCfg create_gui_configuration()
+ 2 * (cfg.icon_width + space);
cfg.minimal_window_size = ImVec2(window_width, window_height);
// 9 = useSurface, charGap, lineGap, bold, italic, surfDist, rotation, keepUp
// 9 = useSurface, charGap, lineGap, bold, italic, surfDist, rotation, keepUp, textFaceToCamera
// 4 = 1px for fix each edit image of drag float
float advance_height = input_height * 9 + 9;
float advance_height = input_height * 10 + 9;
cfg.minimal_window_size_with_advance =
ImVec2(cfg.minimal_window_size.x,
cfg.minimal_window_size.y + advance_height);

View File

@ -1349,14 +1349,12 @@ void GLGizmoSVG::draw_window()
draw_rotation();
draw_mirroring();
/*
if (ImGui::Button(_u8L("Face the camera").c_str())) {
const Camera &cam = wxGetApp().plater()->get_camera();
if (face_selected_volume_to_camera(cam, m_parent) &&
m_volume->emboss_shape->projection.use_surface)
process();
}
*/
ImGui::Unindent(m_gui_cfg->icon_width);
@ -2144,7 +2142,7 @@ GuiCfg create_gui_configuration() {
cfg.texture_max_size_px + 2 * style.FramePadding.y + // preview (-- not sure with padding -> fix retina height)
line_height_with_spacing + // filename
separator_height + // separator - orange line
input_height * 6 + // depth + size + use_surface + FromSurface + Rotation + Mirror
input_height * 7 + // depth + size + use_surface + FromSurface + Rotation + Mirror + FaceTheCamera
2 * style.WindowPadding.y;
cfg.window_size_for_object = ImVec2(std::max(window_input_width, window_image_width), window_height);
float change_type_height = separator_height + line_height_with_spacing + input_height;