Ondsel-Development / FreeCAD

This is the official source code of FreeCAD, a free and opensource multiplatform 3D parametric modeler.
https://www.freecad.org
Other
180 stars 7 forks source link

Ondsel does not apply its "gray out unsuitable tools" policy in some cases, which leads to avoidable errors #75

Open raindropsfromsky opened 4 months ago

raindropsfromsky commented 4 months ago

Is there an existing issue for this?

Problem description

After we close a sketch, Ondsel shows many tools in the top toolbar and side panels. Many of these tools are actually not usable at this stage. But Ondsel shows them all, without graying the unrelated tools (see buttons marked 1 and 2 in the screenshot). image

But if we select any of the unsuitable tools, Ondsel shows an error.

For example, my sketch contains a circle. If I click on the Fillet tool without padding the sketch first, Ondsel shows this error: Fillet: Base feature's shape is not a solid

Although this is logically correct, Ondsel should not allow chances of such errors in the first place!

Desired behavior: Gray out the unsuitable tools (the tools should have state-dependent behavior)

In fact, Ondsel already follows the policy of graying out unsuitable tools. For example, in this screenshot, the toolbr is grayed out. (this is a good example for comparison)

image

But Ondsel does not apply that policy in this case.

Full version info

OS: Windows 11 build 22631
Word size of Ondsel: 64-bit
Version: 2024.2.0dev.37608 (Git)
Build type: Release
Branch: flavor
Hash: cbb758c5dc79fd4c016a9cd45a007d3c7ce1a689
Python 3.11.9, Qt 5.15.13, Coin 4.0.2, Vtk 9.2.6, OCC 7.7.2
Locale: English/India (en_IN)
Installed mods: 
  * Ondsel-Lens 2024.3.26.01

Subproject(s) affected?

None

Anything else?

No response

Code of Conduct

sliptonic commented 4 months ago

There's an issue here that need discussion with the DWG.

If the GUI gets too fancy enabling and disabling tools based on selection, current state of the document, current point in a workflow, etc, it can cause significant slowdown. There's a balance to strike between guiding the user and keeping the GUI responsive.

Since this doesn't throw errors in the console, I'm not tagging it for the bughunt. I'm tempted to close it and ask OP to raise the issue with the DWG on discord. Then open an issue in the upstream tracker so it can be addressed in core.