Workbench drop down list is long, too long.

Here's the place for discussion related to coding in FreeCAD, C++ or Python. Design, interfaces and structures.
User avatar
PrzemoF
Posts: 3060
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Workbench drop down list is long, too long.

Postby PrzemoF » Wed May 06, 2015 3:40 pm

There are 23 workbenches including None, Complete, Start and Web. For 90% of the time I use Part, Part Design, Draft and FEM. I'm thinking about including a 23 positions long checkbox list in a separate tab in the General preferences, called Workbenches. It would allow to switch on/off not used workbenches and it also could be used to handle loading external modules in the future. All I want to get is a shorter list, that could possibly be converted into a bar (again, in the future) to allow easier switching between workbenches. What do you think about that idea?
User avatar
yorik
Site Admin
Posts: 12070
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels, Belgium
Contact:

Re: Workbench drop down list is long, too long.

Postby yorik » Wed May 06, 2015 3:55 pm

It might be a good idea, and also help a lot to speed up freecad startup... The problem will be that the list of available workbenches is variable, and scanned at each freecad startup, so it'll not be easy to keep a preference widget up to date... I'm not too sure how that could be done.
User avatar
microelly2
Posts: 4690
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Workbench drop down list is long, too long.

Postby microelly2 » Wed May 06, 2015 9:48 pm

yorik wrote:I'm not too sure how that could be done.
It will be easy to reintegrate core workbenches into the pluginloader.
The default configuation file can be modifed to get a slim list of functionality to the end user.

example (for a non core workbench)
viewtopic.php?f=8&t=10556&start=10#p87178

Code: Select all


  assembly animation:
     name: ExplodedAssemblyAnimation
     status: noignore
     source:  https://github.com/JMG1/FreeCAD_ExplodedAssemblyAnimationWorkbench/archive/master.zip
     author: JMG
     timestamp: 
     sourcedir: FreeCAD_ExplodedAssemblyAnimationWorkbench-master
     destdir: UserAppData/Mod/ExplodedAssemblyAnimation
     menu: Assembly Animation Workbench
     exec: FreeCADGui.activateWorkbench("ExplodedAnimation")
     icon: /usr/lib/freecad/Mod/plugins/icons/icon_createroute.png
I only have to set status = ignore to hide this workbench from the menu
I can do a reintegration of the core workbenches to test the concept (with a simplified syntax)
wmayer
Site Admin
Posts: 16666
Joined: Thu Feb 19, 2009 10:32 am

Re: Workbench drop down list is long, too long.

Postby wmayer » Wed May 06, 2015 9:54 pm

A few years ago we were discussing about replacing the combo box with a special menu, IIRC. There it was planned to show only the most important workbenches by default but the user has the option to customize everything.

EDIT:
viewtopic.php?t=5467
viewtopic.php?t=7339&start=10
viewtopic.php?f=8&t=2191

A bit off-topic:
viewtopic.php?t=6192
User avatar
microelly2
Posts: 4690
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Workbench drop down list is long, too long.

Postby microelly2 » Wed May 06, 2015 10:06 pm

wmayer wrote: but the user has the option to customize everything.
how?

is there a (simple) way to modify the "workbench list" on the fly?

EDIT:
oh, I have to read the EDIT's of werner maybe there are the answers.
wmayer
Site Admin
Posts: 16666
Joined: Thu Feb 19, 2009 10:32 am

Re: Workbench drop down list is long, too long.

Postby wmayer » Wed May 06, 2015 10:20 pm

This has never been implemented but I can image it works like this:
As Jürgen said the very first menu item would be called "Start". The first entries are the important workbenches (e.g. by default Part, Sketcher, PartDesign, Draft). Afterwards an entry "Customize" comes. When invoking the latter a dialog with a list view comes up. The list view shows all available workbenches and for every item a check box is available. Now the user can set a check box to make a workbench visible or unset it to hide the workbench.
Additionally, there should be also a way to change the order of the workbenches in this dialog.
User avatar
PrzemoF
Posts: 3060
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Workbench drop down list is long, too long.

Postby PrzemoF » Thu May 07, 2015 8:14 am

Lot of discussion... My C++ is not good enough to go for a substantial changes, so I'm going to to start small to alleviate the problem. New tab in General Preferences, hard coded checkbox list with all workbenches. A wb found -> checkbox enabled, a wb not found -> checkbox disabled. Then the dropdown list will be generated only with workbenches that have corresponding checkbox enabled & checked. Any changes by the user on the tab wil regenerate the dropdown list. We'll see if I can do it and if it''s useful.

Future plans: the list would be generated, not hardcoded. Allow moving items to change the order of the dropdown list.

@all: thanks for your input!
User avatar
microelly2
Posts: 4690
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Workbench drop down list is long, too long.

Postby microelly2 » Thu May 07, 2015 8:55 am

wb-dialog.jpg
wb-dialog.jpg (21.98 KiB) Viewed 1855 times
I think its a useful feature (for me too) and
its not a big task to extend my pluginloader to this:

A dockable window with 3 tabs:
your configurable favorites
all the other standard wbs
and additional plugins

some menu and button and further tab infrastructure (if needed around)

the window can be open during work and you can switch between the workbenches by button click
the configuration will be a yaml file (implemeting check boxes is more time consuming)
User avatar
r-frank
Posts: 2181
Joined: Thu Jan 24, 2013 6:26 pm
Location: Möckmühl, Germany
Contact:

Re: Workbench drop down list is long, too long.

Postby r-frank » Thu May 07, 2015 10:48 am

What about being able to assign Keyboard Shortcuts to the different Workbenches ?

As a user my aim would be to get a working speed advantage.
Choosing from a pull-down-menu or clicking in a dockable window is imho no speed advantage
(in that case i even would prefer the pull-down-menu as i am used to it).

Roland
Deutsche FreeCAD Tutorials auf Youtube
My GrabCAD FreeCAD-Projects
FreeCAD lessons for beginners in english

Native german speaker - so apologies for my english, no offense intended :)
User avatar
PrzemoF
Posts: 3060
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Workbench drop down list is long, too long.

Postby PrzemoF » Thu May 07, 2015 11:02 am

r-frank wrote:What about being able to assign Keyboard Shortcuts to the different Workbenches ?

As a user my aim would be to get a working speed advantage.
Choosing from a pull-down-menu or clicking in a dockable window is imho no speed advantage
(in that case i even would prefer the pull-down-menu as i am used to it).

Roland
A simple Alt+number for the 10 most used workbenches would be a big improvement...