panels and popups sliding effect
Marco Martin
notmart at gmail.com
Mon Jul 20 21:52:40 CEST 2009
On Monday 20 July 2009, Martin Gräßlin wrote:
> Am Montag 20 Juli 2009 18:18:48 schrieb Marco Martin:
> > Hi all,
> > At the plasma&kwin bof at akademy one of the things we talked about was a
> > new effect that can make popups and panels appear with a slide animation.
> > today i decided to give it a try here is the result, it seems to work
> > quite well.
>
> great :-D
> I just had a look on the code and it looks good. I will try it later on.
>
> Some things I noticed:
yeah, some whoopsie, the attached patch corrects it
> * in postPaintWindow you probably want to trigger repaints for
> disappearing windows as well. And you could trigger a full repaint for the
> complete screen. Well does not really matter as you set
> PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS
> * Resetting the curve shape in each frame looks like overkill :-)
indeed :)
by the way, i did copy the thing from scale in effect, that will have to be
corrected as well :p
> * Do you really need the clippedRegion?
windows should be clipped to look as they come from the panel, and not slide
over it, is there another way to achieve that?
maybe if it slides under the panel could make sense, not sure,hmm
in the experiments i done they always looked as if the windows are always
painted over the panel..
> * when the window get's closed you have to w->refWindow(). When your
> animation finishes for that window you have to w->unrefWindow(). Without
> that you cannot use a window which has been closed. That code only worked
> because you had fade effect activated with same animation time ;-)
oh, good to know :)
> * would excluding minimized windows from closing make sense? When
> restricting to only Plasma dialogs it probably doesn't matter.
>
> > Now it applies to every window and this is of course bad++, what is
> > needed is some way to apply the thing only on windows we want.
> > that could be the dock type and, if it's on all of popups is way too
> > much, so what we need? an atom to apply on windows we need? (for us
> > basically just Plasma::Dialog)
> > or, a new window type? (would it be a type outside Netwm? is this
> > acceptable?) anyways, how does this patch look? is on the right track?
>
> IIRC we said that adding a special window type would be better. That one
> would of course be outside netwm - nevertheless could be added to netwm
> later on.
yep, i'm wondering if we could want the effect for other types too, hmm
adding (another) new type could also solve my issue with the netbook shell,
where kwin thinks that window is fullscreen just because has the full size but
not the fullscreen flag, i'm knda hesitant to add non netwm types but yeah, if
they aren't up to the job why not :D
--
Marco Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: slidingpopups.diff
Type: text/x-patch
Size: 10532 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/plasma-devel/attachments/20090720/d0222bd7/attachment.diff
More information about the Plasma-devel
mailing list