QMdiArea:subWindowList method not available

32 views
Skip to first unread message

Ralf Van Bogaert

unread,
Apr 25, 2012, 3:03:25 AM4/25/12
to lqt-bi...@googlegroups.com
Hi,

I found another method which does not seem to be implemented in lqt currently;

QList<QMdiSubWindow *> QMdiArea::subWindowList ( WindowOrder order = CreationOrder ) const

Returns a list of all subwindows in the MDI area. If order is CreationOrder (the default), the windows are sorted in the order in which they were inserted into the workspace. If order is StackingOrder, the windows are listed in their stacking order, with the topmost window as the last item in the list. If order is ActivationHistoryOrder, the windows are listed according to their recent activation history.


I was hoping to be able to circumvent this using QMdiArea:findChildren() but that method is not implemented either :/

QMdiArea:children() works but is not useful since it doesn't return any QMdiSubWindows that may be contained.

Would you like me to create a case on Github for every missing method?

Regards

Ralf

Michal Kottman

unread,
Apr 25, 2012, 3:17:53 AM4/25/12
to lqt-bi...@googlegroups.com
On 25 April 2012 09:03, Ralf Van Bogaert <ralf.va...@gmail.com> wrote:
> Hi,
>
> I found another method which does not seem to be implemented in lqt
> currently;
>
> QList<QMdiSubWindow *> QMdiArea::subWindowList ( WindowOrder order =
> CreationOrder ) const
>
> Returns a list of all subwindows in the MDI area. If order is CreationOrder
> (the default), the windows are sorted in the order in which they were
> inserted into the workspace. If order is StackingOrder, the windows are
> listed in their stacking order, with the topmost window as the last item in
> the list. If order is ActivationHistoryOrder, the windows are listed
> according to their recent activation history.
>
> I was hoping to be able to circumvent this using QMdiArea:findChildren() but
> that method is not implemented either :/


This one is easy, modidy generator/qtemplates.lua and change it as follows:

diff --git a/generator/qtemplates.lua b/generator/qtemplates.lua
index 83c46b5..55a7d2a 100644
--- a/generator/qtemplates.lua
+++ b/generator/qtemplates.lua
@@ -12,7 +12,7 @@ return {
["QList<T>"] = { "QList<QGraphicsItem*>",
"QList<int>", "QList<qreal>",
"QList<QModelIndex>", "QList<QSize>",
"QList<QPolygonF>", "QList<QKeySequence>",
"QList<QUrl>", "QList<QRectF>",
"QList<QImageTextKeyLang>", "QList<QTableWidgetItem*>",
- "QList<QAction*>" },
+ "QList<QAction*>", "QList<QMdiSubWindow*>" },
["QVector<T>"] = { "QVector<QPointF>",
"QVector<QPoint>", "QVector<QRgb>", "QVector<QLine>",
"QVector<QRectF>", "QVector<QRect>",
"QVector<QTextLength>", "QVector<QGradientStop>",
"QVector<qreal>", "QVector<QColor>",
"QVector<QTextFormat>", "QVector<QLineF>" },


> Would you like me to create a case on Github for every missing method?

That would be great, I have created a tag "missing", so please mark
every missing method/class issue with this tag.

Reply all
Reply to author
Forward
0 new messages