FreeCAD UI Bible?

A forum for research and development of the user interface of FreeCAD
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
ChrisWesley
Posts: 46
Joined: Mon Nov 20, 2017 11:31 am

FreeCAD UI Bible?

Post by ChrisWesley »

Hey guys, I was referred here by Kunda1 in https://forum.freecadweb.org/viewtopic. ... 56#p496656.

I would like to contribute to the creation and adoptiopn of a "UI Bible". That would be a set of guidelines which FreeCAD developers make and maintain and follow, which lead to a much easier FreeeCAD learning curve, greatly increased FreeCAD productivity through a task-directed UI, and global adoption of FreeCAD because of these attributes.

Please read that thread then let me know what you think about the proposal here.

Thanks
Chris
User avatar
vanuan
Posts: 539
Joined: Wed Oct 24, 2018 9:49 pm

Re: FreeCAD UI Bible?

Post by vanuan »

I think there's a lot of proposals to improve UI but not a lot of effort to actually follow any of the proposals. It's stems from the fact that FreeCAD is more of a Bazaar rather than a Cathedral.

Proposals that win are those which have actual pull requests.
ChrisWesley
Posts: 46
Joined: Mon Nov 20, 2017 11:31 am

Re: FreeCAD UI Bible?

Post by ChrisWesley »

I didn't know that Vanuan - thank you. But then I just landed so I don't know anything. Of course, how things are is something which can be changed if it does not serve the purpose well. What would you say would be a better way to control development?
chrisb
Veteran
Posts: 54216
Joined: Tue Mar 17, 2015 9:14 am

Re: FreeCAD UI Bible?

Post by chrisb »

Many of the functions are there, because someone needs exactly that: the function. And often the UI is, well, so that it works; somehow. It is probably a mix of things to be found somewhere.
What would be helpful is a set of good examples or templates where a developer can benefit from.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
onekk
Veteran
Posts: 6208
Joined: Sat Jan 17, 2015 7:48 am
Contact:

Re: FreeCAD UI Bible?

Post by onekk »

Having used FreeCAD and other pieces of software, I think that FreeCAD, is decently usable, in many ways, as an example I write my GUI interfaces by hand, and they are working as expected.

They are in Pyside2 with some quirks given that the Pyside2 thing is not exposed as the "original" Pyside2 but in a Hybrud manner to be compatible with the Old (Qt4) PySide for compatibility reason (that's a good thing, IMHO).

Once accustomed with this things, You could write interface, in a decent manner even by hand:

Code: Select all

from PySide import QtGui, QtCore
At this page you will find a decent explanation of how things are done

https://wiki.freecadweb.org/PySide

Here You will find the documentation for Qt (Links in the FreeCAD page point to Qt6 so are not in sync with the used version when Qt6 became the actual version )

https://doc.qt.io/qtforpython-5/

Obviously you have to "translate things" using the table in the FreeCAD wiki page, but it's a matter of being accustomed.

Regards

Carlo D.
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.

Blog: https://okkmkblog.wordpress.com/
ChrisWesley
Posts: 46
Joined: Mon Nov 20, 2017 11:31 am

Re: FreeCAD UI Bible?

Post by ChrisWesley »

chrisb wrote: Sun Apr 18, 2021 9:24 am Many of the functions are there, because someone needs exactly that: the function. And often the UI is, well, so that it works; somehow. It is probably a mix of things to be found somewhere.
What would be helpful is a set of good examples or templates where a developer can benefit from.
So you are responding request-by-request to give specific user what they want. (and it's worth noting you are doing it for free in your own time).
It's a great way to be highly responsive to a specific customer, but it may not be the best way for a large complex software package to develop.
But I guess doing it in a planned, structured way immediately adds delay and overhead. You'd need to collect requests, sort them, try to see some underlying development strategy which addresses them in a coherent way and implement according to that. That may be totally unworkable for the resources you have. Chris - are you able to say how many develpers there are?

How can your set of good examples or templates for developers be made?
chrisb
Veteran
Posts: 54216
Joined: Tue Mar 17, 2015 9:14 am

Re: FreeCAD UI Bible?

Post by chrisb »

ChrisWesley wrote: Sun Apr 18, 2021 5:04 pm So you are responding request-by-request to give specific user what they want.
No, not really. It's not that a user can create some feature request and one after one they will be implemented. Why should this ever happen? You may have to forget most of what you used to do managing projects, because it will not work. You have to motivate someone to implement a certain feature, and as he (or she) does it usually without payment you have to find other means to do so. That's why we have implemented a certain process, where feature requests are to be discussed here in the forum first.

If you look through the more recent improvements you see that there are some developers who mainly do what serves themselves. Some are even almost stubborn and think their view is the only one possible.

And there are developers who seem to be happy to contribute to a great programand they are happy if it serves others. And of course there is development in between these two extremes where new things serves the developers and the community as well.

But I guess doing it in a planned, structured way immediately adds delay and overhead. You'd need to collect requests, sort them, try to see some underlying development strategy which addresses them in a coherent way and implement according to that. That may be totally unworkable for the resources you have.
[/quote]
It's not only delay and overhead, not only collecting and sorting, and it's not only a question of resources. If nobody implements what you have planed, collected and sorted it is worth nothing.
Chris - are you able to say how many develpers there are?
In the about dialog is a list of all developers who have a certain number of contributions, but they not all active. So you better have a look at github and check the recent contributions.
How can your set of good examples or templates for developers be made?
E.g. by providing a mini example workbench with Qt templates and excellent documentation including tutorials how to use it. This could be done for C++ and Python.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
onekk
Veteran
Posts: 6208
Joined: Sat Jan 17, 2015 7:48 am
Contact:

Re: FreeCAD UI Bible?

Post by onekk »

FreeCAD is not at the "stable" 1.0 version, on which generally there is a solid block of features that could lead to a "long term stability".

But FreeCAD is not a commercial program, so it's state of "work in progress" more or less permanent, is a sort of "feature" itself.

No one will "force you" to accept something as you could "everytime" proposed some changes, and if they are accepted they wil be intergrated in the "next release" (if it has some sense as most of us use the "permanent changing" "developer" version, or at least his "releases" as in Github release page).

Wiriting a "bible" generally means to things:

1) a god (not to abuse the capital letter)
2) a prophet that interpreters the god wills and "reveal" them to human

Not take in account the religious meaning, I see no god an no prophet on the forum.

As chrisb as perfectly explained,
there are some developers who mainly do what serves themselves. Some are even almost stubborn and think their view is the only one possible.
Said so, a good help would be to "improve documentation", maybe with the help of some "good fellow" that has some more knowledge than you but less time tio invest in writing and mantaining a proper documentation.

So rather that write "A bible" maybe a "notebook" will be "better than nothing", submit some code, that work and ask for some review, maybe (probably) someone will step in and tell you "it's a good work" and maybe with some "guidance" this could lead to a more useful "wiki page".

If you are brave enough, you could write some PDF text more organic, providing that it is not "sculpted in stone" as the "never ending" state of FreeCAD, it has to be update from time to time, (GUI is relatively stable, so not much frequently).

One thing has to be put in place, and this is already "in discussion" in other place, is a "review" or a coaching to the new "wiki" contributor, mainly to avoid spam and other changes.

Maybe discussing a "peer review" strategy or some sandbox for "wiki pages" where a "future contributor" could learn and test some content prior to put the page on the wiki, will be a good improvement.

Said so, it is not difficult to put in place some GUI thing, many "corners" are slightly complicated, not at "GUI creation" but rather at the "GUI interacting with FreeCAD" level, as managing selections and doing other thing to selected objects and so on.

But GUI is not the only thing that FreeCAD have to "develop his power" there are other areas, Macro is a subset of the GUI things, and many could be learned about GUI and FreeCAD studying the Macros that many people will develop.

I personally write the GUI part very limited to my needs without using any helpers like QtCreator or whatever is named today.

I have learned some basics long time ago with Qt4 and now it is rather simple to interact with the GUI, provided you know the basics, of Qt and signals and so on.

Usually if you ask someone will answer you, maybe not immediately, but in short time.

Said so however the scope of GUI could be different and different could be the code, a Macro is one aspect, integrating something in the FreeCAD Gui as when you develop a workbench, is a slightly different thing, so the "scenarios" are slightly different, and so are the structure of the GUI.

A Macro could be a simple thing, like adding a button to launch a "program" that create his own QtDialog and manage it all in the Macro itself, so the relation with FreeCAD is minimal.

A WB could be more challenging, as you mayb have to interact with menu, toolbar, treeview, comboview and so on, so it may be more challenging.

That said I have done some limited work on a WB (with the old QT4 that not surprisingli work even with the "new" Qt5 due to the way FreeCAD manage the transition between Qt4 and Qt5).

Currently I have developed for my use (and a little for other people) some simple "script" that bring up a GUI, create some model on FreeCAD and then let the user to cope with subsequent operation on created model.

I have only used the page I've reported in my precedent post, both the FreeCAD reference and the Qt5 pages, the only drawback I've found is that many examples around refer to the QtWidget that in FreeCAD, is managed as said in the wiki page:
The only unusual aspect is that the PySide2.QtWidgets classes are placed in the PySide.QtGui namespace.
so:

Code: Select all

PySide2.QtWidgets.QCheckBox -> PySide.QtGui.QCheckBox
That is, there are many way to do a thing, difficult thinga, are mostly managing signals, when something change in the interface to act accordingly, and doing Layout things, that could be difficult to manage manually at the first try.

With some "trial and error" then it become "not very difficult", and the overload is not heavy, you could put in place a decent interface, to input data and interact with a rather complex "program" (a script) with around 1000 lines of code, many of them are quite repetitive, and very reusable across different "programs" as you have to set many things "by hand" if you are no using helpers like QtCreator (or it is QtDesigner?).

But this is a my biased "point of view", maybe someone much involved with FreeCAD developing like chrisb could drive you to a more "orthodox" approach.

Hoping not being OT or having bothered anyone.

Regards

Carlo D.
GitHub page: https://github.com/onekk/freecad-doc.
- In deep articles on FreeCAD.
- Learning how to model with scripting.
- Various other stuffs.

Blog: https://okkmkblog.wordpress.com/
ChrisWesley
Posts: 46
Joined: Mon Nov 20, 2017 11:31 am

Re: FreeCAD UI Bible?

Post by ChrisWesley »

onekk wrote: Sun Apr 18, 2021 1:57 pm
At this page you will find a decent explanation of how things are done

Carlo D.
Thanks Carlo!
ChrisWesley
Posts: 46
Joined: Mon Nov 20, 2017 11:31 am

Re: FreeCAD UI Bible?

Post by ChrisWesley »

chrisb wrote: Sun Apr 18, 2021 7:27 pm
ChrisWesley wrote: Sun Apr 18, 2021 5:04 pm So you are responding request-by-request to give specific user what they want.
No, not really. It's not that a user can create some feature request and one after one they will be implemented. Why should this ever happen? You may have to forget most of what you used to do managing projects, because it will not work. You have to motivate someone to implement a certain feature, and as he (or she) does it usually without payment you have to find other means to do so. That's why we have implemented a certain process, where feature requests are to be discussed here in the forum first.

If you look through the more recent improvements you see that there are some developers who mainly do what serves themselves. Some are even almost stubborn and think their view is the only one possible.

And there are developers who seem to be happy to contribute to a great programand they are happy if it serves others. And of course there is development in between these two extremes where new things serves the developers and the community as well.

But I guess doing it in a planned, structured way immediately adds delay and overhead. You'd need to collect requests, sort them, try to see some underlying development strategy which addresses them in a coherent way and implement according to that. That may be totally unworkable for the resources you have.
It's not only delay and overhead, not only collecting and sorting, and it's not only a question of resources. If nobody implements what you have planed, collected and sorted it is worth nothing.
Chris - are you able to say how many develpers there are?
In the about dialog is a list of all developers who have a certain number of contributions, but they not all active. So you better have a look at github and check the recent contributions.
How can your set of good examples or templates for developers be made?
E.g. by providing a mini example workbench with Qt templates and excellent documentation including tutorials how to use it. This could be done for C++ and Python.
[/quote]

Chris, most of what I used to do when I mnanaged projects WAS to movtivate people. Granted, if you have "staff" on a salary, with career aspirations, and a personnel department, then there's a framework to keep people in line and showing up for work. But that's not where great success lies. People can be compliant without being ahppy or productive. The magic happens when they don't comply, they embrace and contribute to a common goal which they were part of creating.

Having said that, this environment is certainly very different and I note your comments - born of actual FreeCAD reality. I think the key is to have more contributors and the key to that is to raise the FreeCAD profile and change its image so that people really want to be a part of it. This is another example of a task which has nothing to do with coding or knowing how FreeCAD works. But it's a task which could end up being extremely transformative for the future of FreeCAD. What if some action someone took brought 50 developers knocking on your IN box, asking for work?

You asked how templates might be made. So I think the first thing is never to "impose rules" - that whole mindset turns people off. They think about "jobsworth", beaurocracy, management, loss of creative freedom, and so on. The design principles should come from the community and be living and growing with the evolving product and the with world it sits in. So - exactly how? Start with a place for people to go to talk about it. I guess that's a forum thread (this one?) or maybe a few. Probably there would be an area somewhere - as you have for your other documentation - where the current version of the standards are kept, can be viewed, distributed and editted. Maybe there are some design videos. Whoever would spearhead that could try to recruit some people to help.

Getting buy-in from existing developers would be essential, so I guess that's some forum-internal mailshot? Maybe the list of developers would be stratified into active, marginal, inactive, etc. When we know explicitly who we have and what we can expect from those folks (you probably already know) we might look explicitly at recruiting. How to get more people. Ideas might be flash notices in the software adn on the support site and in the forums, a newsletter, etc. Maybe there are ways to leverage the broader open source community. We coudl ASK the folks in all these places for their ideas, and then do those as well. I don't know where it would go - but I do know where we could start.
Post Reply