Skip to content

Free, open-source 3D sculpting for Linux, macOS and Windows: dense meshes, remeshing, painting, built-in AI (image/text to 3D), Send to Unreal, game-ready LODs, Gaussian splats and OpenUSD.

Merge by Distance scrolls the tray / drop-down to Check Mesh (below the fold at 1024 px); the 1024 test scrolls the Tool drop-down down to them first

islandmed2af1a0b3dd8d
diff --git a/src/app/App.h b/src/app/App.h
index 21fb1f38..0bab4b94 100644
--- a/src/app/App.h
+++ b/src/app/App.h
@@ -1828,7 +1828,7 @@ private:
std::vector<glm::vec3> weldPoints_; // a sample (<= 20000) of the points that would merge, for the preview
MeshReport meshReport_;
uint64_t meshReportKey_ = 0; // 0 = not checked yet
- int meshReportScroll_ = 0; // frames left to scroll the tray down to a new report's rows (below the fold)
+ int meshReportScroll_ = 0; // frames left to scroll the tray down to Check Mesh (after Merge) or a new report's rows (below the fold)
void runMeshCheck();
void runExtract(); // Extract with the palette's settings (a preview; Accept keeps it)
static std::string axesText(const bool axes[3]); // "x", "xz", "" (the axis argument of mirror commands)
diff --git a/src/app/PanelMeshCheck.cpp b/src/app/PanelMeshCheck.cpp
index 79f41ece..508ab42f 100644
--- a/src/app/PanelMeshCheck.cpp
+++ b/src/app/PanelMeshCheck.cpp
@@ -52,6 +52,7 @@ void App::drawMeshCheckContents() {
if (ImGui::Button(tr("Merge##weld_points"), ImVec2(button, 0))) {
runCommand("weld_points", {{"distance", double(weldDistance_)}});
weldKey_ = 0;
+ meshReportScroll_ = 2; // Check Mesh is next: its row comes into view (below the fold in a 1024 px drop-down)
}
ImGui::EndDisabled();
ui::HelpText("Merge", nullptr,
@@ -143,7 +144,7 @@ void App::drawMeshCheckContents() {
ImGui::PopID();
}
}
- if (meshReportScroll_ > 0) { // the report's last line just above the tray's bottom edge
+ if (meshReportScroll_ > 0) { // Check Mesh's last line (the report's, or "check again") above the bottom edge
--meshReportScroll_;
if (ImGui::GetCursorScreenPos().y > ImGui::GetWindowPos().y + ImGui::GetWindowHeight()) ImGui::SetScrollHereY(1.0f);
}
diff --git a/tests/ui/sizes/parts_tools_1024.sfui b/tests/ui/sizes/parts_tools_1024.sfui
index 2840f981..b30ca560 100644
--- a/tests/ui/sizes/parts_tools_1024.sfui
+++ b/tests/ui/sizes/parts_tools_1024.sfui
@@ -28,6 +28,9 @@ key ctrl+z
run open path=$SCRIPT_DIR/../../data/check_mesh_cube.obj
expect_value vertices == 24
click "Geometry##tool.geometry"
+# The drop-down is taller than the window: a middle-drag on it scrolls down to Merge by Distance and Check Mesh.
+button_drag middle 0.7 0.8 0.7 0.2 0.3
+expect_value panel_drag_scrolls >= 1
expect_text 16 points will merge
shot weld-preview
click "Merge##weld_points"