• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Changing order of views dynamically
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Changing order of views dynamically


  • Subject: Re: Changing order of views dynamically
  • From: Michael Watson <email@hidden>
  • Date: Tue, 20 Mar 2007 07:07:27 -0400

I'd just like to say that this is a really succinct example of a bug that could be difficult to track down. Precisely why you listen to the API documentation! :-)


-- m-s

On 20 Mar, 2007, at 06:29, Andreas Mayer wrote:

(1) OK, I'll make up a scenario in which your app might break:

Note that I'm *not* saying this is how thing work; they *might* work this way. Or they might not. We just don't know.

1. Assume that all subviews are ordered from left to right, lowest to topmost.
2. Assume view A < view B, i.e. B should be on top of A.
3. Assume view A.x+A.width > B.x, i.e. view B overlaps the rightmost part of A.
4. Assume the control has to redraw a rectangle, X.
5. Assume X.x >= A.x, A.x < X.x+X.width < A.x+A.width, X.x+X.width > B.x.
6. Now the superview might intersect each subviews rectangle with the rectangle that is to be redrawn, find that A covers X completely and therefore, as an optimization, stops the redraw loop after drawing A.


==> You have a redraw problem.

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Re: Changing order of views dynamically (From: Sergey Shapovalov <email@hidden>)
 >Re: Changing order of views dynamically (From: Andreas Mayer <email@hidden>)

  • Prev by Date: Re: Changing order of views dynamically
  • Next by Date: Re: Fullscreen Window
  • Previous by thread: Re: Changing order of views dynamically
  • Next by thread: Re: Changing order of views dynamically
  • Index(es):
    • Date
    • Thread