[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-panel-devel
Subject:    Re: QGraphicsLayout,
From:       Alexis_Ménard <menard () kde ! org>
Date:       2009-01-28 18:54:45
Message-ID: 81941aea0901281054g6219a249hbb1991eb766b63f4 () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


On Wed, Jan 28, 2009 at 5:46 PM, Sebastian K=FCgler <sebas@kde.org> wrote:

> On Tuesday 27 January 2009 23:37:07 Alexis M=E9nard wrote:
> > On Tue, Jan 27, 2009 at 8:26 PM, Sebastian K=FCgler <sebas@kde.org> wro=
te:
> > > SVN commit 917381 by sebas:
> > >
> > > updateGeometry() works much better for layout size changes than
> > > invalidating the layout.
> >
> > invalidate just clear the cache of sizes internally, so of course after
> > that it will do nothing. Calling updateGeometry will compute all sizes
> > again according to the content and update the size. But with 4.5 it
> should
> > be less painfull to do that since a tons of bugs regarding that has bee=
n
> > fixed (updating the parent size if the layout change, update parents
> > layouts if one child grow/shrink,...). We can talk about that on tokama=
k,
> > hopefully 4.5 RC will be out and KDE trunk will be switch. Some of line=
s
> > can be removed i am confident.
>
> Ah, thanks for the explanation.
>
> I don't want to completely rely on Qt 4.5 though, since we'd like to
> release
> the networkmanager applet also for distros that rely on Qt 4.4. From what=
 I
> can see though, I need to get the ExtenderItem to understand that its siz=
e
> has
> changed, and pass that information up to ExtenderApplet?


Yes, you can invalidate the ExtenderItem cache and then call updateGeometry
on it, and call manually a resize of the parent.
You can catch the layout request on the event method. That is fix in 4.5 yo=
u
shouldn't do that but we 4.4 it should work.


>
>
> > > This fixes one part of the sizing problems, the extenderitem's size i=
s
> > > updated when you move the extender around. Next step would be to make
> > > the extenderapplet update its geometry after the extenderitem's size
> > > changes. Is there a signal I should use, or what is the best way to d=
o
> > > this?
> --
> sebas
>
>  http://www.kde.org | http://vizZzion.org |  GPG Key ID: 9119 0EF9
>
>

[Attachment #5 (text/html)]

<br><br><div class="gmail_quote">On Wed, Jan 28, 2009 at 5:46 PM, Sebastian Kügler \
<span dir="ltr">&lt;<a href="mailto:sebas@kde.org">sebas@kde.org</a>&gt;</span> \
wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, \
204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"> On Tuesday 27 January 2009 \
23:37:07 Alexis Ménard wrote:<br> &gt; On Tue, Jan 27, 2009 at 8:26 PM, Sebastian \
Kügler &lt;<a href="mailto:sebas@kde.org">sebas@kde.org</a>&gt; wrote:<br> &gt; &gt; \
SVN commit 917381 by sebas:<br> &gt; &gt;<br>
&gt; &gt; updateGeometry() works much better for layout size changes than<br>
&gt; &gt; invalidating the layout.<br>
&gt;<br>
&gt; invalidate just clear the cache of sizes internally, so of course after<br>
&gt; that it will do nothing. Calling updateGeometry will compute all sizes<br>
&gt; again according to the content and update the size. But with 4.5 it should<br>
&gt; be less painfull to do that since a tons of bugs regarding that has been<br>
&gt; fixed (updating the parent size if the layout change, update parents<br>
&gt; layouts if one child grow/shrink,...). We can talk about that on tokamak,<br>
&gt; hopefully 4.5 RC will be out and KDE trunk will be switch. Some of lines<br>
&gt; can be removed i am confident.<br>
<br>
Ah, thanks for the explanation.<br>
<br>
I don&#39;t want to completely rely on Qt 4.5 though, since we&#39;d like to \
release<br> the networkmanager applet also for distros that rely on Qt 4.4. From what \
I<br> can see though, I need to get the ExtenderItem to understand that its size \
has<br> changed, and pass that information up to \
ExtenderApplet?</blockquote><div><br>Yes, you can invalidate the ExtenderItem cache \
and then call updateGeometry on it, and call manually a resize of the parent.<br>You \
can catch the layout request on the event method. That is fix in 4.5 you \
shouldn&#39;t do that but we 4.4 it should work.<br> &nbsp;</div><blockquote \
class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt \
0pt 0.8ex; padding-left: 1ex;"><br> <br>
&gt; &gt; This fixes one part of the sizing problems, the extenderitem&#39;s size \
is<br> &gt; &gt; updated when you move the extender around. Next step would be to \
make<br> &gt; &gt; the extenderapplet update its geometry after the \
extenderitem&#39;s size<br> &gt; &gt; changes. Is there a signal I should use, or \
what is the best way to do<br> &gt; &gt; this?<br>
<font color="#888888">--<br>
sebas<br>
<br>
&nbsp;<a href="http://www.kde.org" target="_blank">http://www.kde.org</a> | <a \
href="http://vizZzion.org" target="_blank">http://vizZzion.org</a> | &nbsp;GPG Key \
ID: 9119 0EF9<br> <br>
</font></blockquote></div><br>



_______________________________________________
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic