Commit Graph

262 Commits

Author SHA1 Message Date
Kacper Donat
78a6891dae Gui: Remove shortcuts for overlay toggles
Using these commands by mistake can result in broken interface and the
shortcuts are way too easy to hit by mistake. The feature is rarely (if
at all) used - so there is no need to have easy to hit shortcuts.
2025-12-22 13:09:15 +01:00
Max Wilfinger
e70c516774 Gui: Add icon to Clarify Selection tool (#24844) 2025-11-25 11:35:28 +01:00
Roy-043
26615ea5d8 GUI: Restore view items and some dialog titles to Title Case (#24222) 2025-11-14 12:31:26 +00:00
Roy-043
4417f501a5 GUI: DrawStyle submenu to Title Case (#24220) 2025-11-14 12:12:41 +00:00
pre-commit-ci[bot]
25c3ba7338 All: Reformat according to new standard 2025-11-11 13:49:01 +01:00
Kacper Donat
9d61aeb04b Compiler warning cleanup (#22997)
* Part: Remove unused arguments from isLinearEdge

* Gui: For Qt 6.5 and later, use ParseOptions in xml

* Gui: Remove unused variable from fuzzyMatch()

* Sketcher: Remove unused parameter from *ReferenceSelection

* PD: Remove unused parameter from *ReferenceSelection

* Part: Rename layout to avoid conflict

* FEM: remove unused variable from handlePropertyChange

* CAM: Eliminate C++11 compiler warning by explicitly defaulting copy
2025-09-29 18:05:58 +02:00
tetektoza
68b754effd Gui: Fix clarify selection menu HiDPI positioning issues
On HiDPI screens, the Clarify Selection context menu appears
far to the right of the intended position when triggered via
right-click, which was making it really problematic to select entities.

So the easiest solution is to apply `devicePixeLRatio` scaling when
converting the stored right-click postiion from device pixels to Qt
logical coordinates before calling `mapToGlobal()`.
2025-09-26 19:19:04 -05:00
Markus Reitböck
6ef07bb358 Gui: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-14 09:47:03 +02:00
tetektoza
06f0a6a428 Gui: Correct linter problems 2025-09-06 17:13:05 +02:00
tetektoza
f44bb78faa Gui: Remember right click position before menu pop-up for ClarifySelect 2025-09-06 15:55:35 +02:00
tetektoza
214e68db99 Gui: Add Clarify Selection radius multiplier option 2025-09-06 12:09:36 +02:00
tetektoza
52a64aa5b7 Gui: Check for nullptr in activeWindow in CommandView directly 2025-09-03 01:24:58 +02:00
tetektoza
2905476491 Gui: Use freecad_cast where possible in CommandView for ClarifySelection 2025-09-03 01:24:58 +02:00
tetektoza
c3c0644020 Gui: Use designated initializer in CommandView 2025-09-03 01:24:58 +02:00
tetektoza
72008cb7f6 Gui: Initialize SbVec2s point directly in CommandView 2025-09-03 01:24:58 +02:00
tetektoza
6f0dd99819 Part/Gui: Rename Pick Geometry tool to Clarify Selection
Co-authored-by: realthunder <realthunder@users.noreply.github.com>
2025-09-03 01:24:58 +02:00
tetektoza
edfeff975e Core/Gui: Render primitives on top of the scene in PickGeometry
+ added some better grouping for items, which are assigned per object
  right now. For example, if we exceed 10 items per object it gets an
  additional group.

Co-authored-by: realthunder <realthunder@users.noreply.github.com>
2025-09-03 01:24:58 +02:00
realthunder
c52bfd37de Gui: Add a context menu to select obstructed items (from RT fork)
As the title says, this is from RT's fork. I only adjusted it a little
bit and removed pie selection which was previously in the
implementation.

To activate context menu - "G, G", then if it can't resolve edges vs
faces, it adds QMenus on top to let user decide which one to select.

Co-authored-by: tetektoza <tetektoza@users.noreply.github.com>
2025-09-03 01:24:57 +02:00
luzpaz
13c9f5da83 Fix various typos
Found via codespell
2025-08-29 10:03:57 +02:00
Chris Hennes
3f85cf14d3 Gui: For Qt 6.5 and later, use ParseOptions in xml 2025-08-28 18:30:22 -05:00
Max Wilfinger
70f4221993 Fix missed strings for UI consistency
Fix ellipsis rendering
2025-08-08 06:37:59 -05:00
Max Wilfinger
ecf02b7878 Gui: Update UI strings for consistency
Closes: #22135
2025-08-04 20:14:45 +02:00
jffmichi
450846c4bc Gui: enable dock/undock/fullscreen for all MDI widgets 2025-07-21 00:44:18 +02:00
Chris Hennes
edca310fd3 Gui: Make narrowing conversion float->int explicit 2025-06-22 17:11:22 -05:00
Chris Hennes
f8ba2f6615 Gui: Mark widget as [[maybe_unused]] 2025-06-22 17:06:51 -05:00
Max Wilfinger
3c1e197115 Gui: Add toggle overlay icons 2025-06-20 22:36:40 +02:00
wmayer
0ea02d60c1 Gui: Add Action::setBlockedChecked
Remove the second parameter of Action::setChecked and
provide Action::setBlockedChecked instead.
2025-05-30 14:21:53 +02:00
Chris Hennes
f0e183b20b Gui: Make variable more local
Eliminate a compiler warning about an unused variable by making the
variable more local to the point-of-use.
2025-05-12 18:16:56 +02:00
bofdahof
998f4e4d45 Console: rename PascalCase named methods to camelCase 2025-05-06 17:50:21 +02:00
Kacper Donat
6e2583cdcd Gui: Use freecad_cast whenever possible 2025-04-26 14:23:25 +02:00
captain0xff
08381b1d18 remove some code setting pixel density ratio for pixmaps
update
2025-04-03 19:55:27 +05:30
Chris Hennes
5f623390fb Merge pull request #20142 from bofdahof/ranges
Apply C++20 std::ranges (mainly to std::find)
2025-03-17 03:08:27 -05:00
bofdahof
e5b06ae736 Gui: apply std::ranges 2025-03-16 17:15:14 -05:00
Luz Paz
17102251e5 Fix various typos 2025-03-14 12:37:12 -04:00
Andrea
5464ada40c Remove old qt code
new round of removal following the report of @benj5378  .

.
2025-03-05 09:46:35 +01:00
Benjamin Bræstrup Sayoc
f647d4a1eb Gui: Use QStringLiteral 2025-02-10 18:34:57 +01:00
tritao
48f0f07176 Gui: Reorganize the navigation files into a top Navigation folder. 2025-02-05 20:21:00 -06:00
Benjamin Nauck
dd6aa9f3c7 Prefer to use BaseClass's isDerivedFrom<T> over non template or Base::Type's
Regex based changes, manually verified
2025-01-27 16:08:18 +01:00
tritao
8aa50c4380 Gui: Reorganize the dialog files into a top Dialogs folder. 2025-01-24 16:28:02 -06:00
Syres916
32f7d08602 [Gui] Allow power users to set their own max toggle transparency 2025-01-20 11:43:18 -05:00
Snow Faerie
8bc062b6e8 Fix and add menu accelerators (#15532)
* Fix and add menu accelerators: menus common to all workbenches

I use menu accelerators fairly often, so I find it very frustrating when
they are missing, or worse, they don't work due to the same letter being
assigned to several commands.

This patch adds accelerators to lots of menu entries missing them and
fixes broken accelerators.

Wherever possible, standard accelerator keys are used:
https://doc.qt.io/qt-5/accelerators.html

This commit covers accelerator fixes that are common to all workbenches.
Accelerator fixes for specific workbenches will be done in separate
commits.

* Add missing accelerators: Spreadsheet workbench
2024-12-13 10:39:30 -06:00
Chris Hennes
64f63ae97e Merge pull request #15528 from ppphp/move_some_inventor
refactor: move some nodes to Inventor folder
2024-11-22 12:20:50 -05:00
Hannu Koivisto
a55fc950da Fix crash when using box selection with Arch Survey
doSelect() loops over document's object vector.  It can happen that, within
the loop, Gui::Selection().addSelection() gets called and that ends up
calling App::Document::addObject() which pushes an object to the vector that
the loop is traversing.  If the vector is full, its storage is reallocated
and this means that later iterations of the loop are using invalid iterators.
Thus, one ends up with a bogus obj pointer and there will be a crash within
getGroupOfObject().  The problem was observed when using Arch Survey.
2024-08-26 17:33:55 +02:00
Chris Hennes
e52ef2a525 GUI: Update MacOS detection macros
For GUI-specific things use Q_OS_MACOS, and for other things use
Q_OS_APPLE.
2024-08-12 11:34:39 -04:00
liukaiwen
4c6b7dadeb refactor: move some nodes to Inventor folder 2024-07-20 01:07:04 +08:00
Chris Hennes
de3579bf7c Merge pull request #15190 from hlorus/measure_dependency_violation
MeasureGui: Fix measure dependency violation
2024-07-13 19:56:23 -05:00
Roy-043
c7f712844e Gui: fix icon name conflict related to Std_ViewScreenShot
The image Std_ViewScreenShot.svg was not used in the GUI. The command Std_ViewScreenShot used a different icon. This caused a name conflict in the Wiki.
2024-07-13 19:32:14 -05:00
Max Wilfinger
7d21d9edb8 Fix source string typos mentioned on Crowdin (#15261) 2024-07-08 17:18:31 -05:00
hlorus
8ab537863a [MeasureGui] Move measure cmd and task into measure module
...to avoid core depending on modules
2024-07-04 14:56:49 +02:00
Chris Hennes
d45cf8507b Merge pull request #13810 from hlorus/replace_measuredistance
Integrate Std_MeasureDistance into unified measurement facility
2024-06-17 10:55:40 -05:00