[ Fixed ] Draft GUI: Shortcuts do not display in sub-menus?

A forum dedicated to the Draft, Arch and BIM workbenches development.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
Roy_043
Veteran
Posts: 8550
Joined: Thu Dec 27, 2018 12:28 pm

[ Fixed ] Draft GUI: Shortcuts do not display in sub-menus?

Post by Roy_043 »

I notice that keyboard shortcuts do not display in the Draft sub-menus.
Example: Drafting > Arc tools > Arc
Shortcut: A, R
The shortcut exists and works.

Code: Select all

OS: Windows 8.1 (6.3)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24219 (Git)
Build type: Release
Branch: master
Hash: 8c26baebab320b8c1c3279bc8eb34a1eb6c7a363
Python version: 3.6.8
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: Dutch/Netherlands (nl_NL)
Last edited by Roy_043 on Tue Oct 05, 2021 1:46 pm, edited 1 time in total.
User avatar
Roy_043
Veteran
Posts: 8550
Joined: Thu Dec 27, 2018 12:28 pm

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by Roy_043 »

Hmm, this is more complex. If you start with the Draft WB the "A, R" shortcut actually does not work. You have to load the BIM WB first.

The issue seems to be related to toolbuttons on flyouts.

The menu nesting does not seem to cause it. F.e.: if you start with the Arch WB the "C, I" shortcut works fine even though the tool sits in a nested menu.
User avatar
bitacovir
Veteran
Posts: 1570
Joined: Sat Apr 19, 2014 6:23 am
Contact:

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by bitacovir »

Roy_043 wrote: Sun May 02, 2021 8:45 am Hmm, this is more complex. If you start with the Draft WB the "A, R" shortcut actually does not work. You have to load the BIM WB first.

The issue seems to be related to toolbuttons on flyouts.

The menu nesting does not seem to cause it. F.e.: if you start with the Arch WB the "C, I" shortcut works fine even though the tool sits in a nested menu.
What happen if you don't have BIM WB installed?
::bitacovir::
==================
One must be absolutely modern.
Arthur Rimbaud (A Season in Hell -1873)

Canal Youtube Grupo Telegram de FreeCAD Español

My personal web site
My GitHub repository
Mini Airflow Tunnel Project
User avatar
Roy_043
Veteran
Posts: 8550
Joined: Thu Dec 27, 2018 12:28 pm

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by Roy_043 »

The issue is not cause by the BIM WB, if that is what you mean. After removing it the problem remains.
User avatar
turn211
Posts: 162
Joined: Mon Feb 01, 2021 11:37 pm

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by turn211 »

bitacovir wrote: Sun May 02, 2021 2:14 pm
Roy_043 wrote: Sun May 02, 2021 8:45 am Hmm, this is more complex. If you start with the Draft WB the "A, R" shortcut actually does not work. You have to load the BIM WB first.

The issue seems to be related to toolbuttons on flyouts.

The menu nesting does not seem to cause it. F.e.: if you start with the Arch WB the "C, I" shortcut works fine even though the tool sits in a nested menu.
What happen if you don't have BIM WB installed?
All shortcuts work as intended from Arch, Draft or Bim installed or not on my machine. Windows 8.1 reach Mainstream End of Life Jan 8th 2018. Could contribute to problems in these newer FreeCAD releases.

OS: Windows 10 Version 2009
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24291 (Git)
Build type: Release
Branch: releases/FreeCAD-0-19
Hash: 7b5e18a0759de778b74d3a5c17eba9cb815035ac
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.0
Locale: English/Canada (en_CA)
User avatar
Roy_043
Veteran
Posts: 8550
Joined: Thu Dec 27, 2018 12:28 pm

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by Roy_043 »

turn211 wrote: Mon May 03, 2021 2:48 am All shortcuts work as intended
Have you tested the case where Draft is the only WB you have loaded after Start? If I load BIM the "A, R" works for me as well, but that is because the Draft_Arc tool is directly accessible in a toolbar from that WB. At least I currently think that tools on flyouts suffer from this bug.

turn211 wrote: Mon May 03, 2021 2:48 am Windows 8.1 reach Mainstream End of Life Jan 8th 2018. Could contribute to problems in these newer FreeCAD releases.
That seems unlikely to me.

Code: Select all

OS: Windows 8.1 Version 6.3 (Build 9600)
Word size of FreeCAD: 64-bit
Version: 0.20.24720 (Git)
Build type: Release
Branch: master
Hash: 8b0c58d1b45017ad42bf0fa8f827f1cf22a398e7
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.0
Locale: Dutch/Netherlands (nl_NL)
The image shows the Drafting menu from the Draft WB.
Attachments
draft-shortcuts-missing.png
draft-shortcuts-missing.png (23.07 KiB) Viewed 2572 times
User avatar
turn211
Posts: 162
Joined: Mon Feb 01, 2021 11:37 pm

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by turn211 »

Roy_043 wrote: Mon May 03, 2021 7:06 am Have you tested the case where Draft is the only WB you have loaded after Start? If I load BIM the "A, R" works for me as well, but that is because the Draft_Arc tool is directly accessible in a toolbar from that WB. At least I currently think that tools on flyouts suffer from this bug.
Yes you are correct. Using Create New on my machine loads BIM WB by default. Loading Draft WB only on startup the following shortcuts do not work:

Fillet
Arc Tools
Bezier Tools
Point

That to me shows the nesting is not the problem as Fillet and Point are not nested. The Labels don't show up either but maybe they never did. Good catch. 8-)
User avatar
Roy_043
Veteran
Posts: 8550
Joined: Thu Dec 27, 2018 12:28 pm

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by Roy_043 »

turn211 wrote: Mon May 03, 2021 3:24 pm That to me shows the nesting is not the problem as Fillet and Point are not nested
You also have to check the code. Not all commands have a shortcut. Look for "Accel". That word is missing in gui_points.py and gui_fillets.py.

Thanks for confirming.
matthijskooijman
Posts: 72
Joined: Thu Mar 25, 2021 10:59 am

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by matthijskooijman »

This sounds a bit like a bug I noticed where the draft preferences are not shown when you load Arch before BIM. That's the reverse, but maybe there is a similar problem in the code that causes this where the Arch/BIM and Draft workbenches have some code duplication (but with differences in shortcuts, maybe) for loading these commands and loading one prevents the other from also loading? See https://forum.freecadweb.org/viewtopic.php?f=23&t=57663 for the other issue.
User avatar
Roy_043
Veteran
Posts: 8550
Joined: Thu Dec 27, 2018 12:28 pm

Re: Draft GUI: Shortcuts do not display in sub-menus?

Post by Roy_043 »

Looking through my 'archive' I see that I have started a similar topic ca. 1 year ago:
https://forum.freecadweb.org/viewtopic.php?f=23&t=45826
Post Reply