PDA

View Full Version : open dialog from center to full screen size



vivek.panchal
23rd August 2012, 05:24
hi,

i want to open a dialog from center point to screen size ... first when i open dialog it will in center of screen with small size and gradually it increase its size and fit to window size ... i want zoom in effect initially and when i press escape it will zoom out...... is it possible in limited resources embedded device?

mvuori
23rd August 2012, 19:22
"Limited resources" can mean just about anything nowadays. Best way to find out is to try it... There may be a compromise needed to how good the effect looks. I would do it by defining how long the effect should take and how many steps (in-between sizes of the dialog) would be needed for the effect (just a first guess) -- perhaps only 4 or 5. Then I'd add a QTimer()-triggered routine to the dialog's opening process. After that it is a process of iterating the parameters until it looks good -- or deciding that it sucks and forgetting about it.

vivek.panchal
24th August 2012, 06:19
hi mvuori,

i have tried that approach but it will take much more time of cpu and it loads very slowly on that ....

ChrisW67
24th August 2012, 06:39
Assuming you have not tried to grow the dialog in 500 steps over 200 milliseconds then the answer to your original question is no.

You would typically use QPropertyAnimation to do this for a widget UI.