Glass

A forum for research and development of the user interface of FreeCAD

Moderator: agryson

adrianinsaval
Posts: 48
Joined: Thu Apr 05, 2018 5:15 pm

Re: Glass

Post by adrianinsaval » Fri May 17, 2019 3:58 am

adrianinsaval wrote:
Sun May 12, 2019 6:05 pm
Hi, I'm currently using it on windows 10 with the Tree view and it works great! However, I have to manually press q+1 or q+2 every time I startup Freecad, can this be automated? It does not show at all unless you press q+1 or q+2.

On a side note, can this be used simultaneously in more than one panel? Anyway, thanks for such a great addon!

EDIT:
Got it how I wanted with a few twitches. It automatically gets in Glass mode by adding setMode() after line 176 in GlassGui.py (use setVisibility instead if you want it to show but not in Glass mode).

I got it to work on 2 panels by copy/pasting GlassGui.py and importing the copy in InitGui.py. Had to twitch the positioning so they don't overlap and change the key combinations on the copy. Also changed LeftDockWidgetArea for RightDockWidgetArea at line 146 for personal preference.

There probably is a better way to do this since right now the tree view can be out of view if the window is resized. Sadly, I don´t really know any python to fix this. Attached are my modified files for anyone interested, they go into the Mod/Glass folder.

On a different note, anyone knows how to get rid of the tree in the combo view? or how to permanently move the navigation cube a little to the left?
Solved the positioning issue! I might be better to adapt some numbers to the screen, they're at lines 161 to 166. Attached the fixed copy.
Attachments
GlassGui2.py
(4.66 KiB) Downloaded 22 times

User avatar
Kunda1
Posts: 5479
Joined: Thu Jan 05, 2017 9:03 pm

Re: Glass

Post by Kunda1 » Fri May 17, 2019 11:45 am

Have you ever tried to use Github ? FreeCAD repository lives on it. So does Glass. It's easier/ 'more convenient' to review code using it.
Check out the FC wiki github page
Want to contribute back to FC? Checkout:
#lowhangingfruit | Use the Source, Luke. | How to Help FreeCAD | How to report FC bugs and features

adrianinsaval
Posts: 48
Joined: Thu Apr 05, 2018 5:15 pm

Re: Glass

Post by adrianinsaval » Fri May 24, 2019 4:03 am

Kunda1 wrote:
Fri May 17, 2019 11:45 am
Have you ever tried to use Github ? FreeCAD repository lives on it. So does Glass. It's easier/ 'more convenient' to review code using it.
Check out the FC wiki github page
I just don't think my little twitches justify a pull request or a fork. It's just my taste and I shared in case someone liked it.

triplus
Posts: 8676
Joined: Mon Dec 12, 2011 4:45 pm

Re: Glass

Post by triplus » Fri May 24, 2019 9:29 am

OficineRobotica wrote:
Sat May 11, 2019 4:48 am
Hello @Triplus. Any news on the glass addon side? i've been waiting for a bump in version and now i'm on kubunrtu 19.04 and freecad-daily from the ppa but it seems that the problem with the black background persists.
Hi @OficineRobotica

I didn't have much free time for Glass module in the past few weeks. Before that i did a bit of research and narrowed the issue down a bit. On KDE, when applying a stylesheet, an issue (black background) emerges. Didn't determine yet if it's a KDE or Qt related issue, or something else is involved, and if a possible workaround exists. Will try to determine that in the following days.

Hi @adrianinsaval

Yes, the change could be made persistent (cross restart) and i did actually implemented a few toggle modes already. But due to not yet resolving KDE issue i didn't have much motivation to push the changes just yet. Will work on that in the following days and in addition i will review your proposals more in depth. Thanks for contributing.

User avatar
Kunda1
Posts: 5479
Joined: Thu Jan 05, 2017 9:03 pm

Re: Glass

Post by Kunda1 » Thu Jun 13, 2019 5:56 pm

X-post New macro, Vision1, check it out thread. This macro uses a different approach to the FreeCAD viewing experience. May well be a useful methodology for the Glass WB.
Want to contribute back to FC? Checkout:
#lowhangingfruit | Use the Source, Luke. | How to Help FreeCAD | How to report FC bugs and features

OficineRobotica
Posts: 54
Joined: Thu Feb 21, 2019 8:17 am

Re: Glass

Post by OficineRobotica » Wed Sep 04, 2019 9:12 am

I'm having problems setting the things as i want them to with the latest dev appimage. My laptop gave up and it needs to go to be repaired and i had to re set up everything on my tower pc. When I try to activate glass , but with the "tree view" modification it gives me this error

Code: Select all

Traceback (most recent call last):
  File "/home/flo/.FreeCAD/Mod/Glass/GlassGui.py", line 137, in setMode
    dock.setParent(mdi)
AttributeError: 'NoneType' object has no attribute 'setParent'


Strangely , even the View>Pannels menu is missing the tree view option to be activated.
I remember using the same version on my laptop and the tree view option was present. I'm confused and i might be wrong but pls help. I was so accustomed to that layout that it feels so awkward now with only the combo view

Code: Select all

OS: KDE neon User Edition 5.16 (KDE//usr/share/xsessions/plasma)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.18009 (Git) AppImage
Build type: Release
Branch: master
Hash: 0641ca0d1e020d18f23d2adb49959195266f04f7
Python version: 3.7.3
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: Italian/Italy (it_IT)

triplus
Posts: 8676
Joined: Mon Dec 12, 2011 4:45 pm

Re: Glass

Post by triplus » Wed Sep 04, 2019 9:28 am

Hi @OficineRobotica

Currently i am investing my free time in addressing some of the remaining oppressing issues with the AppImage. It will take a few more days. After i will take a look.

OficineRobotica
Posts: 54
Joined: Thu Feb 21, 2019 8:17 am

Re: Glass

Post by OficineRobotica » Wed Sep 04, 2019 9:43 am

@triplus

No worries and no rush. I'm aware that this is a really busy time for the devs with the merge and all that it is surrounding it. This is really a minor minor issue.

The thing is that I don't think that it is a glass module problem. It's just that the app image is missing the tree view option in the view>panels menu. I remember this was a issue some time ago and it was reintroduced( I don't remember if it was a regression or if it was eliminated as an option) . Going forward towards assemblies a clear view of the tree view is always welcomed.

Thank you for always being present.
Cheers

triplus
Posts: 8676
Joined: Mon Dec 12, 2011 4:45 pm

Re: Glass

Post by triplus » Wed Sep 04, 2019 10:56 am

I took a quick look and indeed there is no Tree and Property view by default anymore:

https://forum.freecadweb.org/viewtopic. ... 13#p331713

If you will read the discussion, there likely still is a way to enable both (using parameter). I didn't test it yet, as best to hear some rationale first, on why they got disabled by default.

realthunder
Posts: 1164
Joined: Tue Jan 03, 2017 10:55 am

Re: Glass

Post by realthunder » Wed Sep 04, 2019 2:01 pm

Use Parameter editor to create an 'Enable' parameter under User->Preferences->DocWindows->TreeView (PropertyView), and set it the True. Restart FreeCAD. I think it is wmayer disabled it? Not sure though.
Screenshot from 2019-09-04 21-56-10.png
Screenshot from 2019-09-04 21-56-10.png (52.37 KiB) Viewed 415 times
Try Assembly3 (latest version 0.10.2) along with my custom build of FreeCAD at here.
And if you'd like to show your support, you can donate through patreon, liberapay, or paypal

Post Reply