Trolltech Home | Qt-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 3

Qt-interest Archive, August 2007
No resize flicker in QT 4.4


Message 1 in thread

Hi,

I just read the article explaing how QT 4.4 won't have any resize 
flicker because you moved away from having a separate native window for 
each widget:

http://labs.trolltech.com/blogs/2007/08/09/qt-invaded-by-aliens-the-end-of-all-flicker/

I have a question regarding this:

* How did you implement drag and drop for alien widgets onto an embedded 
native window (which is still necessary)? I mean, if you have stuff like 
an embedded QGLWidget widget and you have a want to have a treeview next 
to it with some icon which you can drag onto the open GL surface. How 
could you then get the dragged alien widget/icon to be rendered on top 
of the native openGL window?

I'm asking this because I ran into a similar problem with Microsoft 
Windows Presentation Foundation (WPF) and I would be very interested in 
how you worked around this. Basically, in WPF everything is "alien" to 
use your terminology, except old WinForms controls which can be 
integrated into the WPF XAML code using a special WinFormsHost XAML tag. 
The problem is that you can never get a WPF element to render above a 
WinForms widget (in terms of Z-order).

So, to reformulate my question; would it be possible to render an 
"alien" QT widget above an embedded native window (such as QGLWidget)? 
And if so, how did you accomplish this? Do you apply some special 
clipping mask (computed from the overlayed shape of the "alien" widget) 
  to the embedded native window?





Martin

--
 [ signature omitted ] 

Message 2 in thread

I feel like I'm missing something obvious here: Is there a Qt- 
approved way to make a *deep* copy of an object? If it helps, in my  
case I'm looking to make a copy of a QGraphicsItem, which has all of  
its member data tucked away in its private implementation class.

Thanks!
- Rob

--
 [ signature omitted ] 

Message 3 in thread

On 10.08.07 15:46:35, Rob Winchester wrote:
> I feel like I'm missing something obvious here: Is there a Qt-approved way to 
> make a *deep* copy of an object? If it helps, in my case I'm looking to make a 
> copy of a QGraphicsItem, which has all of its member data tucked away in its 
> private implementation class.

Well, as QGraphicsItem has getters and setters it should be relatively
easy to create a new object and set all its properties to the values of
an existing one. 

Andreas

-- 
 [ signature omitted ] 

Message 4 in thread

On Saturday 11 August 2007, Martin Olsson wrote:
> Hi,
>
> I just read the article explaing how QT 4.4 won't have any resize
> flicker because you moved away from having a separate native window for
> each widget:
-----------[ SNIP ]------------------------

Qt 4.4? Did I miss something? Was 4.3.1 just released?

-- 
 [ signature omitted ] 

Message 5 in thread

Peter M. Groen wrote:
> Qt 4.4? Did I miss something? Was 4.3.1 just released?

Yes, yes, and yes. :)

Qt 4.4 development moves forward, while bugs are fixed in the 4.3 branch.

--Dave

--
 [ signature omitted ] 

Message 6 in thread

On søndag den 12. August 2007, Peter M. Groen wrote:
> On Saturday 11 August 2007, Martin Olsson wrote:
> > Hi,
> >
> > I just read the article explaing how QT 4.4 won't have any resize
> > flicker because you moved away from having a separate native window for
> > each widget:
>
> -----------[ SNIP ]------------------------
>
> Qt 4.4? Did I miss something? Was 4.3.1 just released?

He is referring to this:

http://labs.trolltech.com/blogs/2007/08/09/qt-invaded-by-aliens-the-end-of-all-flicker/

Bo.

-- 
 [ signature omitted ] 

Message 7 in thread

Hi Martin,

> So, to reformulate my question; would it be possible to render an 
> "alien" QT widget above an embedded native window (such as QGLWidget)? 
> And if so, how did you accomplish this? Do you apply some special 
> clipping mask (computed from the overlayed shape of the "alien" widget) 
>   to the embedded native window?

Mixing of native and non-native windows is a bit tricky. The problem 
you're describing above is one of the things that is not yet solved. I'm 
working on it these days actually. An easy solution would be to enforce 
a native window for the alien widget as soon as it overlaps. However, 
unless you're application is MDI based, overlapping siblings will rarely 
occur.


-- 
 [ signature omitted ] 

Message 8 in thread

Hi Björn,

I first experienced this when I tried to embed the Microsoft Visio 
ActiveX into a WPF application. Pretty late in the game we discovered 
this awkward problem (we couldn't drag WPF UIElement's onto the Visio 
surface). We tried to pretend for a while that there was a way to 
"solve" it but in the end we had to crap Visio from the project. This 
redesign was quite costly and annyoing (even though I disliked the 
activeX crap all along). Now we're on track with a pure WPF canvas 
instead, but it always sucks in a way when the technology/framework 
forces you to make certain decisions.

What about applying some kind of custom clipping mask to the native 
window? Maybe that could work?

If you find some magic way to solve this problem, please do tell me how 
you did it. I bet a ton of people are running into this problem with 
win32/WPF, AWT/Swing, QT/opengl etc etc.



Martin

Bjoern Erik Nilsen wrote:
> Hi Martin,
> 
>> So, to reformulate my question; would it be possible to render an 
>> "alien" QT widget above an embedded native window (such as QGLWidget)? 
>> And if so, how did you accomplish this? Do you apply some special 
>> clipping mask (computed from the overlayed shape of the "alien" 
>> widget)   to the embedded native window?
> 
> Mixing of native and non-native windows is a bit tricky. The problem 
> you're describing above is one of the things that is not yet solved. I'm 
> working on it these days actually. An easy solution would be to enforce 
> a native window for the alien widget as soon as it overlaps. However, 
> unless you're application is MDI based, overlapping siblings will rarely 
> occur.
> 
> 

--
 [ signature omitted ]