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

List:       koffice-devel
Subject:    Re: kword frameUnderMouse bug ?
From:       Thomas Zander <zander () planescape ! com>
Date:       2002-02-27 15:17:37
[Download RAW message or body]

On Wed, Feb 27, 2002 at 05:35:57AM +0100, Frank Dekervel wrote:
> hello,
> 
> I am slowly digging my way thru the kword sources.
> I think i found a bug:
> 
> kwdoc::frameUnderMouse returns the first match, iterating over all framesets.
> now suppose we have a frame containing a bigger frame (inlined).
> Suppose we click outside the outer frame, the bigger (inlined) frame should 
> not even be considered for selecting. but right now it is, and you actually 
> can select a frame in that way (and it gets painted outside and so on).
> Maybe that's related to the clipping bug david was talking about @ fosdem, 
> but at that moment things went waay to fast for me.

That bug was also fixed (by David) at Fosdem :)

The second problem I see in the frame selection code is that you can't select 
a frame that is behind another.

I think a better way to fix this is to get the first frame (like we do now)
and then keep searching for a possibly selected frame.
If no selected frame is found at that same position then the first is returned.
If we find a selected frame then we unselect it and then return the first 
frame we find after the one that was selected.

This way you have a state based selection algoritm that cycles through all 
frames, and the inline frames will be shown, but will not pose a problem since
you can still select the other frame.

This will have to be solved partly kwframe.[cc|h] probably with adding a 
boolean (with default=off) to the 2 search methods called from the method 
you state above.


Please give it a try.

Sorry for the slow reply, and the (IMO incorrect) fix you allready made...
But thanx for the attenttion!!

-- 
Thomas Zander                                            zander@earthling.net
The only thing worse than failure is the fear of trying something new

[Attachment #3 (application/pgp-signature)]
_______________________________________________
koffice-devel mailing list
koffice-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/koffice-devel

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

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