Re: [Interest] QWebEnginePage acceptNavigationRequest leads to empty page

2019-01-29 Thread Allan Jensen
Hi, The problem is the semantics of anchor is: Go the given window (or open a new one), then navigate to the given URL. You are blocking the second stop, leaving a newly opened window on its initial blank page, you could probably also block the first stop by overloading QWebEnginePage::createWi

Re: [Interest] QWebEnginePage acceptNavigationRequest leads to empty page

2019-01-29 Thread Sven Bergner
Hi Allan, thanks for your suggestion. I think I've found the root of the behavior. The link has a target="_blank" and that calls createWindow() which leads to an empty window. If I remove the target="_blank" I can intercept the link. But for me that feels also like an error. What sense does it make

Re: [Interest] QWebEnginePage acceptNavigationRequest leads to empty page

2019-01-28 Thread Allan Sandfeld Jensen
On Montag, 28. Januar 2019 13:11:45 CET Sven Bergner wrote: > Hi there, > I have an app that uses QWebEngine to show a webpage that has a link to a > pdf document. > Now I want to handle a click on that link by > implementing QWebEnginePage::acceptNavigationRequest(). > The method is called an I ca

[Interest] QWebEnginePage acceptNavigationRequest leads to empty page

2019-01-28 Thread Sven Bergner
Hi there, I have an app that uses QWebEngine to show a webpage that has a link to a pdf document. Now I want to handle a click on that link by implementing QWebEnginePage::acceptNavigationRequest(). The method is called an I can check if the link leads to a pdf and if so I handle the url by myself