FreeCAD Qt5 plan for deprecated WebKit?

Here's the place for discussion related to coding in FreeCAD, C++ or Python. Design, interfaces and structures.
blacey
Posts: 338
Joined: Tue Dec 08, 2015 11:28 pm

FreeCAD Qt5 plan for deprecated WebKit?

Postby blacey » Sat Jan 21, 2017 8:08 pm

As of Qt 5.6, QtWebKit has been deprecated and is not included in any Qt5.6 distribution by default. While one can manually include it, it's days are clearly numbered...

Webkit and Qt Quick 1 Removed

We have removed WebKit and Qt Quick 1 from Qt 5.6 release content. The source code is still available in the repositories, but these are not packaged with Qt 5.6 any more. Qt Script remains deprecated, but is included in Qt 5.6 release.


It seems that Mod/Web depends upon it causing FreeCAD to not launch properly unless it is included and the unit test that tries to load the WebGui workbench fails...

Code: Select all

Traceback (most recent call last):
  File "/usr/local/FreeCAD.app/Contents/lib/python2.7/unittest/case.py", line 329, in run
    testMethod()
  File "/usr/local/FreeCAD.app/Contents/Mod/Test/Workbench.py", line 46, in testActivate
    self.failUnless(False, "Loading of workbench '%s' failed: %s" % (i, e.message))
  File "/usr/local/FreeCAD.app/Contents/lib/python2.7/unittest/case.py", line 612, in deprecated_func
    return original_func(*args, **kwargs)
  File "/usr/local/FreeCAD.app/Contents/lib/python2.7/unittest/case.py", line 422, in assertTrue
    raise self.failureException(msg)
AssertionError: Loading of workbench 'WebWorkbench' failed: Test on activating workbench failed


@f3nix and @wmayer, I couldn't glean a plan from prior forum posts so I am wondering if anyone has discussed or planned to port from QtWebKit to QtWebKitEngine or some other alternative. https://wiki.qt.io/Porting_from_QtWebKit_to_QtWebEngine
triplus
Posts: 5013
Joined: Mon Dec 12, 2011 4:45 pm

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby triplus » Sat Jan 21, 2017 8:21 pm

AFAIK it was mentioned in the past a few times but the discussion didn't get much traction.

In addition i did a bit of research and if i am not mistaken we use Quarter (QuarterWidget) currently subclass of QGLWidget. This is another thing that will likely cause issues for us in the future.

https://groups.google.com/forum/#!topic ... SVG6ZxOWy4

Therefore in Qt 4 world things worked OK. Qt 5 will likely introduce some real challenges to tackle.
blacey
Posts: 338
Joined: Tue Dec 08, 2015 11:28 pm

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby blacey » Sat Jan 21, 2017 8:34 pm

Ok, thanks. Issue 2868 filed.
triplus
Posts: 5013
Joined: Mon Dec 12, 2011 4:45 pm

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby triplus » Fri Jan 27, 2017 5:20 pm

I see that @ickby already did something similar in the past:

Port QuarterWidget to QGraphicsView

Derive from QGraphicsView instead of QGLWidget to allow to add widgets as overlay over the 3d scene later on.


https://github.com/FreeCAD/FreeCAD/comm ... 50763bfe39

To bad additional QOpenGLWidget port doesn’t exist for testing purposes. What i do imagine is the UX @ickby was working on doesn't have the famous Mac 3D Window overlap issue.
triplus
Posts: 5013
Joined: Mon Dec 12, 2011 4:45 pm

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby triplus » Fri Jan 27, 2017 5:46 pm

User avatar
f3nix
Posts: 213
Joined: Sat May 30, 2015 11:58 am

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby f3nix » Fri Jan 27, 2017 6:07 pm

triplus wrote:To bad additional QOpenGLWidget port doesn’t exist for testing purposes. What i do imagine is the UX @ickby was working on doesn't have the famous Mac 3D Window overlap issue.


Hi,
I've been working on QOpenGLWidget port during past few days. I think I will have something shareable in the near future.

Cheers,
Mateusz
triplus
Posts: 5013
Joined: Mon Dec 12, 2011 4:45 pm

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby triplus » Fri Jan 27, 2017 6:13 pm

f3nix wrote:Hi,
I've been working on QOpenGLWidget port during past few days. I think I will have something shareable in the near future.

Cheers,
Mateusz


Fantastic news!

P.S. As for the QGraphicsView. If i remember correctly @ickby was hoping to get a performance boost in Qt 5. But if i read the blog it doesn’t look like that will happen.
User avatar
Kunda1
Posts: 689
Joined: Thu Jan 05, 2017 9:03 pm

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby Kunda1 » Fri Jan 27, 2017 9:50 pm

f3nix wrote:
triplus wrote:To bad additional QOpenGLWidget port doesn’t exist for testing purposes. What i do imagine is the UX @ickby was working on doesn't have the famous Mac 3D Window overlap issue.


Hi,
I've been working on QOpenGLWidget port during past few days. I think I will have something shareable in the near future.

Cheers,
Mateusz


re: QOpenGLWidget
linking issue #1401
wmayer
Site Admin
Posts: 11355
Joined: Thu Feb 19, 2009 10:32 am

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby wmayer » Sat Jan 28, 2017 10:32 am

f3nix wrote:I've been working on QOpenGLWidget port during past few days. I think I will have something shareable in the near future.

At the moment we use the old QGLWidget in two places: the view port of the 3d view and in the image module to render images. A few weeks ago I started to port the image viewer to QOpenGLWidget which was quite straightforward and everything worked correctly.

However, the problems started when opening a 3d view at the same time. The image view becomes black and for every new image view you create it never goes back to normal.
triplus
Posts: 5013
Joined: Mon Dec 12, 2011 4:45 pm

Re: FreeCAD Qt5 plan for deprecated WebKit?

Postby triplus » Sat Jan 28, 2017 10:41 am

And if you close (all) 3D View(s) and open new image view? Or if you make sub-window tiles and for 3D View to only cover a portion of MDI area.

After opening new image view (that doesn't overlap completely) does it behave differently?