qmdiarea

qt positioning controls in QMdiSubWindow

你离开我真会死。 提交于 2021-02-17 01:53:13
问题 I have problem with positioning controls in QMdiSubWindow derivate. I designed my window using QtDesigner, and it looks like this: When I run the app it looks like this (button on the title bar): It gets ok only in maximized mode: But I would like it to always look OK. Here's a part of .ui file: <widget class="QPushButton" name="btnToggleEdit"> <property name="geometry"> <rect> <x>10</x> <y>10</y> <width>75</width> <height>23</height> </rect> </property> <property name="text"> <string>Edit<

qt positioning controls in QMdiSubWindow

烂漫一生 提交于 2021-02-17 01:52:21
问题 I have problem with positioning controls in QMdiSubWindow derivate. I designed my window using QtDesigner, and it looks like this: When I run the app it looks like this (button on the title bar): It gets ok only in maximized mode: But I would like it to always look OK. Here's a part of .ui file: <widget class="QPushButton" name="btnToggleEdit"> <property name="geometry"> <rect> <x>10</x> <y>10</y> <width>75</width> <height>23</height> </rect> </property> <property name="text"> <string>Edit<

Does Qt Qml Have QMdiArea?

坚强是说给别人听的谎言 提交于 2020-02-05 04:04:36
问题 Does Qml have QMdiArea and QMdiSubWindow? If so can you show me a little example? I have a cool idea for a program design that I would like to create. 回答1: QML does not have something like QMdiArea. But you can place your qml file in a QMdiArea widget. It's enought to set a QDeclarativeView as viewport widget of the QMdiArea or by putting the QDeclarativeView inside QMdiArea(It's just a QWidget subclass like any other). 来源: https://stackoverflow.com/questions/22682057/does-qt-qml-have

Does Qt Qml Have QMdiArea?

二次信任 提交于 2020-02-05 04:04:28
问题 Does Qml have QMdiArea and QMdiSubWindow? If so can you show me a little example? I have a cool idea for a program design that I would like to create. 回答1: QML does not have something like QMdiArea. But you can place your qml file in a QMdiArea widget. It's enought to set a QDeclarativeView as viewport widget of the QMdiArea or by putting the QDeclarativeView inside QMdiArea(It's just a QWidget subclass like any other). 来源: https://stackoverflow.com/questions/22682057/does-qt-qml-have

A FigureCanvasQTAgg nested in a QMdiSubWindow segfaults when i minimize the QMdiSubWindow

寵の児 提交于 2019-12-13 00:56:24
问题 I am trying to have FigureCanvasQTAgg inside QMdiSubWindow such that the user can create his/her own plots on the fly. I have made this very small self contained code: from PyQt4 import QtGui from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas from matplotlib.figure import Figure import sys class ExampleApp(QtGui.QMainWindow): def __init__(self): super(self.__class__, self).__init__() self.mdiarea = QtGui.QMdiArea() self.setCentralWidget(self.mdiarea) sub = QtGui

How can I add a “new tab” button next to the tabs of a QMdiArea in tabbed view mode?

你说的曾经没有我的故事 提交于 2019-11-30 06:44:47
I'd like to have a "new tab" button much like Chrome or Firefox has for my QMdiArea . I can make a button or menu item somewhere that adds a new subdocument to the MDI thing, but how can I make it a visually appealing tiny tab with a "+" as label? Alternatively, I would be happy enough with a QTabWidget with such a button. You will have to write your own class for the QTabBar. The plus button can be added by using absolute positioning. I have some code here for PySide; it should give you the basic idea. class TabBarPlus(QtGui.QTabBar): """Tab bar that has a plus button floating to the right of

How can I add a “new tab” button next to the tabs of a QMdiArea in tabbed view mode?

时光毁灭记忆、已成空白 提交于 2019-11-29 06:25:39
问题 I'd like to have a "new tab" button much like Chrome or Firefox has for my QMdiArea . I can make a button or menu item somewhere that adds a new subdocument to the MDI thing, but how can I make it a visually appealing tiny tab with a "+" as label? Alternatively, I would be happy enough with a QTabWidget with such a button. 回答1: You will have to write your own class for the QTabBar. The plus button can be added by using absolute positioning. I have some code here for PySide; it should give you