diff --git a/examples/python/simple.py b/examples/python/simple.py deleted file mode 100644 index fd0a95296..000000000 --- a/examples/python/simple.py +++ /dev/null @@ -1,42 +0,0 @@ -import sys - -from PyQt5.QtWidgets import QApplication, QMainWindow, QTextEdit, QLabel -from PyQt5.QtCore import Qt - -from PyQtAds import ads - - -def makewindow(ex, area, name, tabbed=True): - txt = QTextEdit() - txt.setText(name) - child = ads.CDockWidget(name) - child.setWidget(txt) - if tabbed: - ex.addDockWidgetTab(area, child) - else: - ex.addDockWidget(area, child) - - - - - -app = QApplication(sys.argv) -wnd = QMainWindow() -ex = ads.CDockManager(wnd) - -label = QLabel(text="Welcome") -label.setAlignment(Qt.AlignCenter) -central = ads.CDockWidget("CentralWidget") -central.setWidget(label) -central.setFeature(ads.CDockWidget.NoTab, True) -centralDockArea = ex.setCentralWidget(central) - -makewindow(ex, ads.CenterDockWidgetArea, "Center1") -makewindow(ex, ads.CenterDockWidgetArea, "Center2") -makewindow(ex, ads.CenterDockWidgetArea, "Center3") -makewindow(ex, ads.LeftDockWidgetArea, "Left") -makewindow(ex, ads.LeftDockWidgetArea, "Left2") -makewindow(ex, ads.RightDockWidgetArea, "Right") -makewindow(ex, ads.RightDockWidgetArea, "Right2") -wnd.show() -sys.exit(app.exec_()) diff --git a/project.py b/project.py index cd6526b36..89c471b0c 100644 --- a/project.py +++ b/project.py @@ -1,12 +1,8 @@ - import os from pyqtbuild import PyQtBindings, PyQtProject from sipbuild import Option -log=open("/tmp/project.log","w") -print("project py running") - class PyQtAds(PyQtProject): def __init__(self): """ Initialise the project. """ diff --git a/pyproject.toml b/pyproject.toml index 3b6d17cc9..9da629787 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,9 +14,7 @@ description-file = "README.md" requires-dist = "PyQt5 (>=5.15.4)" description-content-type = "text/markdown" - [tool.sip.project] -#sip-files-dir = "sip" tag-prefix = "QtAds" [tool.sip.bindings.ads] diff --git a/src/DockManager.cpp b/src/DockManager.cpp index b85049de5..ecb558cb0 100644 --- a/src/DockManager.cpp +++ b/src/DockManager.cpp @@ -858,10 +858,6 @@ CDockAreaWidget* CDockManager::addDockWidgetTab(DockWidgetArea area, { return addDockWidget(ads::CenterDockWidgetArea, Dockwidget, AreaWidget); } - /*else if (!openedDockAreas().isEmpty()) - { - return addDockWidget(area, Dockwidget, openedDockAreas().last()); - }*/ else { return addDockWidget(area, Dockwidget, nullptr);