Get a QWidget to take up the entire QMainWindow
Posted
by Bad Man
on Stack Overflow
See other posts from Stack Overflow
or by Bad Man
Published on 2010-04-08T02:17:51Z
Indexed on
2010/04/08
2:23 UTC
Read the original article
Hit count: 394
I have a class that inherits QMainWindow and I just want it to have a webview widget and nothing else,
so here's what I tried doing for constructor:
MyWindow::MyWindow(QWidget *parent) : QMainWindow(parent)
{
this->_webView = new QWebView(this);
this->setCentralWidget(this->_webView);
}
This didnt work do I have to use some kind of layout to make this fill?
© Stack Overflow or respective owner