mirror of
https://git.mirrors.martin98.com/https://github.com/bambulab/BambuStudio.git
synced 2025-04-22 13:50:06 +08:00
ENH: sync some missing codes between branches
Change-Id: I9c9dcd366bfb25ed787cd85b9a5f7001bc751ab9
This commit is contained in:
parent
34d02aa07f
commit
1c8763b17d
@ -49,11 +49,6 @@
|
|||||||
"pattern": "bbl/i18n/ja/BambuStudio_ja.po",
|
"pattern": "bbl/i18n/ja/BambuStudio_ja.po",
|
||||||
"lang": "ja"
|
"lang": "ja"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"type": "po",
|
|
||||||
"pattern": "bbl/i18n/uk/BambuStudio_uk.po",
|
|
||||||
"lang": "uk"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "po",
|
"type": "po",
|
||||||
"pattern": "bbl/i18n/ja/BambuStudio_ko.po",
|
"pattern": "bbl/i18n/ja/BambuStudio_ko.po",
|
||||||
|
@ -179,10 +179,10 @@ void GLGizmoMeshBoolean::on_render_input_window(float x, float y, float bottom_l
|
|||||||
GizmoImguiSetNextWIndowPos(x, y, ImGuiCond_Always, 0.0f, 0.0f);
|
GizmoImguiSetNextWIndowPos(x, y, ImGuiCond_Always, 0.0f, 0.0f);
|
||||||
GizmoImguiBegin("MeshBoolean", ImGuiWindowFlags_AlwaysAutoResize | ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoCollapse | ImGuiWindowFlags_NoTitleBar);
|
GizmoImguiBegin("MeshBoolean", ImGuiWindowFlags_AlwaysAutoResize | ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoCollapse | ImGuiWindowFlags_NoTitleBar);
|
||||||
|
|
||||||
const int max_tab_length = 2 * ImGui::GetStyle().FramePadding.x + std::max(ImGui::CalcTextSize(_L("Union").c_str()).x,
|
const int max_tab_length = 2 * ImGui::GetStyle().FramePadding.x + std::max(ImGui::CalcTextSize(_u8L("Union").c_str()).x,
|
||||||
std::max(ImGui::CalcTextSize(_L("Difference").c_str()).x, ImGui::CalcTextSize(_L("Intersection").c_str()).x));
|
std::max(ImGui::CalcTextSize(_u8L("Difference").c_str()).x, ImGui::CalcTextSize(_u8L("Intersection").c_str()).x));
|
||||||
const int max_cap_length = ImGui::GetStyle().WindowPadding.x + ImGui::GetStyle().ItemSpacing.x + std::max(ImGui::CalcTextSize(_L("Source Volume").c_str()).x, ImGui::CalcTextSize(_L("Tool Volume").c_str()).x);
|
const int max_cap_length = ImGui::GetStyle().WindowPadding.x + ImGui::GetStyle().ItemSpacing.x + std::max(ImGui::CalcTextSize(_u8L("Source Volume").c_str()).x, ImGui::CalcTextSize(_u8L("Tool Volume").c_str()).x);
|
||||||
const int select_btn_length = 2 * ImGui::GetStyle().FramePadding.x + std::max(ImGui::CalcTextSize(("1 " + _L("selected")).c_str()).x, ImGui::CalcTextSize(_L("Select").c_str()).x);
|
const int select_btn_length = 2 * ImGui::GetStyle().FramePadding.x + std::max(ImGui::CalcTextSize(("1 " + _u8L("selected")).c_str()).x, ImGui::CalcTextSize(_u8L("Select").c_str()).x);
|
||||||
|
|
||||||
auto selectable = [this](const wxString& label, bool selected, const ImVec2& size_arg) {
|
auto selectable = [this](const wxString& label, bool selected, const ImVec2& size_arg) {
|
||||||
ImGui::PushStyleVar(ImGuiStyleVar_WindowPadding, { 0,0 });
|
ImGui::PushStyleVar(ImGuiStyleVar_WindowPadding, { 0,0 });
|
||||||
@ -240,15 +240,15 @@ void GLGizmoMeshBoolean::on_render_input_window(float x, float y, float bottom_l
|
|||||||
};
|
};
|
||||||
|
|
||||||
ImGui::PushStyleVar(ImGuiStyleVar_FrameRounding, 0);
|
ImGui::PushStyleVar(ImGuiStyleVar_FrameRounding, 0);
|
||||||
if (selectable(_L("Union").c_str(), m_operation_mode == MeshBooleanOperation::Union, ImVec2(max_tab_length, 0.0f))) {
|
if (selectable(_u8L("Union").c_str(), m_operation_mode == MeshBooleanOperation::Union, ImVec2(max_tab_length, 0.0f))) {
|
||||||
m_operation_mode = MeshBooleanOperation::Union;
|
m_operation_mode = MeshBooleanOperation::Union;
|
||||||
}
|
}
|
||||||
ImGui::SameLine(0, 0);
|
ImGui::SameLine(0, 0);
|
||||||
if (selectable(_L("Difference").c_str(), m_operation_mode == MeshBooleanOperation::Difference, ImVec2(max_tab_length, 0.0f))) {
|
if (selectable(_u8L("Difference").c_str(), m_operation_mode == MeshBooleanOperation::Difference, ImVec2(max_tab_length, 0.0f))) {
|
||||||
m_operation_mode = MeshBooleanOperation::Difference;
|
m_operation_mode = MeshBooleanOperation::Difference;
|
||||||
}
|
}
|
||||||
ImGui::SameLine(0, 0);
|
ImGui::SameLine(0, 0);
|
||||||
if (selectable(_L("Intersection").c_str(), m_operation_mode == MeshBooleanOperation::Intersection, ImVec2(max_tab_length, 0.0f))) {
|
if (selectable(_u8L("Intersection").c_str(), m_operation_mode == MeshBooleanOperation::Intersection, ImVec2(max_tab_length, 0.0f))) {
|
||||||
m_operation_mode = MeshBooleanOperation::Intersection;
|
m_operation_mode = MeshBooleanOperation::Intersection;
|
||||||
}
|
}
|
||||||
ImGui::PopStyleVar();
|
ImGui::PopStyleVar();
|
||||||
@ -257,7 +257,7 @@ void GLGizmoMeshBoolean::on_render_input_window(float x, float y, float bottom_l
|
|||||||
std::string cap_str1 = m_operation_mode != MeshBooleanOperation::Difference ? _u8L("Part 1") : _u8L("Subtract from");
|
std::string cap_str1 = m_operation_mode != MeshBooleanOperation::Difference ? _u8L("Part 1") : _u8L("Subtract from");
|
||||||
m_imgui->text(cap_str1);
|
m_imgui->text(cap_str1);
|
||||||
ImGui::SameLine(max_cap_length);
|
ImGui::SameLine(max_cap_length);
|
||||||
wxString select_src_str = m_src.mv ? "1 " + _L("selected") : _L("Select");
|
wxString select_src_str = m_src.mv ? "1 " + _u8L("selected") : _u8L("Select");
|
||||||
select_src_str << "##select_source_volume";
|
select_src_str << "##select_source_volume";
|
||||||
ImGui::PushItemWidth(select_btn_length);
|
ImGui::PushItemWidth(select_btn_length);
|
||||||
if (selectable(select_src_str.c_str(), m_selecting_state == MeshBooleanSelectingState::SelectSource, ImVec2(select_btn_length, 0)))
|
if (selectable(select_src_str.c_str(), m_selecting_state == MeshBooleanSelectingState::SelectSource, ImVec2(select_btn_length, 0)))
|
||||||
@ -285,7 +285,7 @@ void GLGizmoMeshBoolean::on_render_input_window(float x, float y, float bottom_l
|
|||||||
std::string cap_str2 = m_operation_mode != MeshBooleanOperation::Difference ? _u8L("Part 2") : _u8L("Subtract with");
|
std::string cap_str2 = m_operation_mode != MeshBooleanOperation::Difference ? _u8L("Part 2") : _u8L("Subtract with");
|
||||||
m_imgui->text(cap_str2);
|
m_imgui->text(cap_str2);
|
||||||
ImGui::SameLine(max_cap_length);
|
ImGui::SameLine(max_cap_length);
|
||||||
wxString select_tool_str = m_tool.mv ? "1 " + _L("selected") : _L("Select");
|
wxString select_tool_str = m_tool.mv ? "1 " + _u8L("selected") : _u8L("Select");
|
||||||
select_tool_str << "##select_tool_volume";
|
select_tool_str << "##select_tool_volume";
|
||||||
ImGui::PushItemWidth(select_btn_length);
|
ImGui::PushItemWidth(select_btn_length);
|
||||||
if (selectable(select_tool_str.c_str(), m_selecting_state == MeshBooleanSelectingState::SelectTool, ImVec2(select_btn_length, 0)))
|
if (selectable(select_tool_str.c_str(), m_selecting_state == MeshBooleanSelectingState::SelectTool, ImVec2(select_btn_length, 0)))
|
||||||
|
@ -161,9 +161,6 @@ wxBoxSizer *PreferencesDialog::create_item_language_combobox(
|
|||||||
else if (vlist[i] == wxLocale::GetLanguageInfo(wxLANGUAGE_UKRAINIAN)) {
|
else if (vlist[i] == wxLocale::GetLanguageInfo(wxLANGUAGE_UKRAINIAN)) {
|
||||||
language_name = wxString::FromUTF8("\xD1\x83\xD0\xBA\xD1\x80\xD0\xB0\xD1\x97\xD1\x9D\xD1\x81\xD1\x8C\xD0\xBA\xD0\xB0");
|
language_name = wxString::FromUTF8("\xD1\x83\xD0\xBA\xD1\x80\xD0\xB0\xD1\x97\xD1\x9D\xD1\x81\xD1\x8C\xD0\xBA\xD0\xB0");
|
||||||
}
|
}
|
||||||
else if (vlist[i] == wxLocale::GetLanguageInfo(wxLANGUAGE_UKRAINIAN)) {
|
|
||||||
language_name = wxString::FromUTF8("Ukrainian");
|
|
||||||
}
|
|
||||||
|
|
||||||
if (language == vlist[i]->CanonicalName) {
|
if (language == vlist[i]->CanonicalName) {
|
||||||
m_current_language_selected = i;
|
m_current_language_selected = i;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user