You are not logged in.

pavlacki

Beginner

  • "pavlacki" started this thread

Posts: 26

Location: Belgium - Bruxelles

Occupation: developer

  • Send private message

1

Friday, December 23rd 2005, 1:03pm

integrate a QT4 application in a MDI delphi application

Hello,

I have written a QT4 application.
my application is QWidget and I draw a QPixmap inside of the QWidget.


I want to transform my exe in a dll.
The purpose is to integrate the QT application as a Form in a MDI delphi application.
So is it possible to redirect the paint of the QWidget to be to the Graphical device of the Delphi Form.


As final I want to display QWidet inside of a Delphi window
My QT application become a pluggin for other windows applications

Thanks

  • "wysota" is male

Posts: 4,276

Location: Warsaw, POLAND

  • Send private message

2

Friday, December 23rd 2005, 1:50pm

RE: integrate a QT4 application in a MDI delphi application

So can't you just program the window in delphi? You can't just get rid of Qt's paining mechanism, it is the heart of this library.

pavlacki

Beginner

  • "pavlacki" started this thread

Posts: 26

Location: Belgium - Bruxelles

Occupation: developer

  • Send private message

3

Friday, December 23rd 2005, 2:22pm

RE: integrate a QT4 application in a MDI delphi application

Sorry I don't realy understand...
what do you mean by
"get rid of Qt's paining mechanism, it is the heart of this library."

I can ask the delphi's programmer to do anything I want.

What do you mean by "get rid of Qt's paining mechanism"

I am beginning with QT, I choose it because it is very powerfull and easy to draw in Pixmap.

chickenblood

Professional

Posts: 657

Location: Mountain View, CA

Occupation: Data Monkey

  • Send private message

4

Friday, December 23rd 2005, 4:48pm

RE: integrate a QT4 application in a MDI delphi application

Quoted

Originally posted by pavlacki
As final I want to display QWidet inside of a Delphi window
My QT application become a pluggin for other windows applications
Thanks


Sounds like you might want to write an ActiveX control. Have a look at the QAxServer module.
I have enough sense to know that "common sense" is an oxymoron.

  • "wysota" is male

Posts: 4,276

Location: Warsaw, POLAND

  • Send private message

5

Friday, December 23rd 2005, 6:11pm

RE: integrate a QT4 application in a MDI delphi application

Quoted

Originally posted by pavlacki
I can ask the delphi's programmer to do anything I want.

I meant you can't delagate Qt's painting routines to Delphi easily.

Either don't use Qt's GUI system at all (you can still paint on QImages) or paint Qt widgets using Qt painting engine. I guess you can implement a painter (using the abstract paining engine) that uses Delphi functions, but you still have to use Qt's event queue -- unless you find a way to transfer Qt events to delphi (for example by calling QApplication::processEvents now and then). An alternative is, as mentioned, to use Qt-made widget as an ActiveX server.

It is probably simpler to use Qt just for painting on images, if you need that functionality and do all the drawing in Delphi without mixing technologies.

pavlacki

Beginner

  • "pavlacki" started this thread

Posts: 26

Location: Belgium - Bruxelles

Occupation: developer

  • Send private message

6

Friday, December 23rd 2005, 10:26pm

I read in the QAxServer Module page doc

Source code

1
2
3
4
5
6
Unsupported Clients

We have not managed to make ActiveQt based COM objects work with the following client applications.

    * Borland C++ Builder (Versions 5 and 6)
    * Borland Delphi


does it mean that my QAxserver module will not work in a Delphi application?