[Qt-interest] Widget promotion feature

Patric userqt at gmail.com
Mon Jun 1 22:12:17 CEST 2009


I have created a widget with QT Designer and promoted it in my Main Window. 
And it's there when I run the program. :)
But unfortunately, there is no visualization of my widget contents in Main 
Window, when I'm just looking at it from the Designer.

I hope you understood what I meaned here...

Regards,
Patric

----- Original Message ----- 
From: "Paul Dixon" <lordelph at gmail.com>
To: <qt-interest at trolltech.com>
Sent: Monday, June 01, 2009 10:42 PM
Subject: Re: [Qt-interest] Widget promotion feature


>> I am reading this article
>> http://doc.trolltech.com/4.5/designer-using-custom-widgets.html
>> and I can't understand it very well...
>> Can somebody explain me what is this Promotion for, after all ?
>
> Let's say you made a cool widget called FooWidget, and wanted to use
> it in Qt Designer - you could drop a regular Widget object into your
> layout, then "promote" it to a FooWidget, which enables the generated
> code to include the relevant header and create a FooWidget rather than
> a Widget.
>
> If your FooWidget is a specialised version of a widget Qt Designer
> already knows about, e.g. a QSlider, you can tell it to use that as a
> base class when you promote it, which will allow more access to its
> custom properties in Qt Designer.
>
> To put it another way, it's a quick way of getting Qt Designer to work
> with *your* widget classes rather than the Qt defaults.
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>
> __________ Information from ESET NOD32 Antivirus, version of virus 
> signature database 4098 (20090522) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>
>
> 


__________ Information from ESET NOD32 Antivirus, version of virus signature database 4098 (20090522) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com






More information about the Qt-interest-old mailing list