PDA

View Full Version : Opening a web browser within (inside) a window on a button-click



dkj5
20th March 2013, 13:41
Hi All,

My requirement is to open a web browser "within" a window on a button-click, i.e; initially only a button is visible inside the window. On clicking the button, the browser should become visible in the window and load the given url.

I thought of placing a gridlayout widget first in window and on top of that will place the QWebView widget for the browser. But, don't know how to hide the browser. Is this approach correct ? If yes, please guide me further steps. If not, please let me know the correct approach.

I am using Qt 4.8.0 with designer IDE on Ubuntu 11.04.

Thanks in advance.

anda_skoa
20th March 2013, 19:38
Just call hide() on the web view after creating it. It will remain hidden until you explicitly call show() on it again.

Cheers,
_