Expand QTextBroswer in QTabWidget
-
How do I get my QTextBrowser widget to auto expand to the tab widget it is within? I want this to happen for each component in each of the tabs. I don't want to do it with code. I want to be able to do this all in QT Designer.
Initially my tab QTabWidget in QDialog widget did not expand to fit the QDialog , but I found that if right clicked on it in the form and set Lay Out to Lay Out in a Grid that expanded it, but that option is grayed out for QTextBrowser when I try that.
-
@LukeThe3rd Use layouts: https://doc.qt.io/qt-6/layout.html
"but that option is grayed out for QTextBrowser when I try that" - should work like with any other widgets, but you should right click on the widget where you placed QTextBrowser and then select a layout. -
@jsulm Wow. Thanks. That worked.
I guess I was not paying close attention that when I did it before, I right clicked on the container (QDialog) and not the widget (QTabWidget) in the container to get the QTabWidget to expand. So right clicking on the QTabWidget and selecting Lay Out in a Grid expanded the QTextBrowser.
Was a long day and I guess my attention span was waning.