You are not logged in.

ckult2

Unregistered

1

Friday, September 3rd 2004, 7:09pm

mdi-like window

Can I create a child window, say, QVBox, with window decorations ? Which can be moved, resized, etc. ?

djanubis

Beginner

Posts: 29

Location: Moulins France

Occupation: Software ingeneering

  • Send private message

2

Friday, September 3rd 2004, 8:23pm

RE: mdi-like window

Yes, have a look to http://doc.trolltech.com/3.3/qworkspace.html the QWorkspace class wich tells you the pros and cons of the thing.
Never patch not working code. Rewrite it !
Never patch badly designed classes. Recreate them cleanly.
(Excerpts from Computing Bible)

Home of the Lab project

ckult2

Unregistered

3

Saturday, September 4th 2004, 9:48am

No, I need/t QWorkspace. For example, I create a child of QGLWidget (QWorkspace by itself is a widget too)

djanubis

Beginner

Posts: 29

Location: Moulins France

Occupation: Software ingeneering

  • Send private message

4

Saturday, September 4th 2004, 10:33am

Does your child need to really be MDI? If yes, use the QWorkspace as place holder for other windows. If not give the widget the Qt::WType_TopLevel flag (as well as other needed flags).
A QGLWidget is a widget as others, as it inherits QWidget and can be used in a QWorkspace as a child window.
Never patch not working code. Rewrite it !
Never patch badly designed classes. Recreate them cleanly.
(Excerpts from Computing Bible)

Home of the Lab project

anda_skoa

Professional

Posts: 1,273

Location: Graz, Austria

Occupation: Software Developer

  • Send private message

5

Saturday, September 4th 2004, 1:44pm

In a KDE program you can alternatively use the more advanced KMdi framework
http://api.kde.org/3.3-api/kmdi/html/classes.html

If you just need another window, you just pass 0 as the widget parent.
Or use it as a child in a QDialog, etc

Cheers,
_
Qt/KDE Developer
Debian User

ckult2

Unregistered

6

Saturday, September 4th 2004, 3:24pm

djanubis: QWokrspace maximezes all windows, but I have maximized QGLWidget and little QVBox (like WinRar's archiving progress)

For Example:
http://sniger25.narod.ru/aa.png