• 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: Drawing: The Right place to keep bounds
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Drawing: The Right place to keep bounds


  • Subject: Re: Drawing: The Right place to keep bounds
  • From: Jens Alfke <email@hidden>
  • Date: Wed, 25 Nov 2009 08:24:06 -0800

On Nov 25, 2009, at 7:27 AM, Paul Bruneau wrote:

> I think I recognize, and I am pretty sure I have read that Sketch does things Wrong. I see that the shape objects keep their own bounds (and frame?) information. It seems clear to me that this is Wrong. What does Sketch do if it ever can have two views of the same objects?

The bounding box is an intrinsic property of a geometric object, independent of how it's viewed.

Unless you're talking about something like a bounding box transformed into view coordinates; I'm not familiar with the Sketch code. That would definitely be part of the view, not the model. That sort of design is often done by having a parallel per-view model that's been transformed for use in the view, and code that keeps the per-view model synced with changes to the master. Core Animation uses this sort of design.

—Jens_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please 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

  • Follow-Ups:
    • Re: Drawing: The Right place to keep bounds
      • From: Paul Bruneau <email@hidden>
References: 
 >Drawing: The Right place to keep bounds (From: Paul Bruneau <email@hidden>)

  • Prev by Date: Re: Drawing: The Right place to keep bounds
  • Next by Date: Re: Re: URLWithString fails to fails with bad string
  • Previous by thread: Re: Drawing: The Right place to keep bounds
  • Next by thread: Re: Drawing: The Right place to keep bounds
  • Index(es):
    • Date
    • Thread