• 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: Removing or ignoring "lineWidth" property of an NSBezierPath instance
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Removing or ignoring "lineWidth" property of an NSBezierPath instance


  • Subject: Re: Removing or ignoring "lineWidth" property of an NSBezierPath instance
  • From: Tobias Zimmerman <email@hidden>
  • Date: Mon, 27 Apr 2009 13:54:11 -0400
  • Thread-topic: Removing or ignoring "lineWidth" property of an NSBezierPath instance

Thanks Alastair and Graham for responding, and apologies for the delay in
following up.

I think that, at best, the documentation is ambiguous.  It would be clearer
specifically saying "If no value was set explicitly for the receiver, this
method [lineWidth] returns the default line width ->at the time the receiver
was created<-"  I may file a RADR on that.

It is further confusing because the actual effect of the lineWidth property
is dependent on the view in which the drawing takes place -- that is, a line
width of "1.0" in one view will not necessarily appear the same width in a
separate view that has a different dot-pitch, pixel ratio, etc.


> From: Graham Cox <email@hidden>
> Date: Thu, 23 Apr 2009 10:27:25 +1000
> To: Tobias Zimmerman <email@hidden>
> Cc: "email@hidden" <email@hidden>
> Subject: Re: Removing or ignoring "lineWidth" property of an NSBezierPath
> instance
>
>
> On 23/04/2009, at 7:19 AM, Tobias Zimmerman wrote:
>
>> (By way of further explanation, the project this arises in involves
>> a set of
>> bezier paths that are generated in one program and archived for use
>> in a
>> separate program.  I would like the lineWidth and other drawing
>> specifics
>> such as line/fill colors to be controlled by the view where the
>> reusable
>> paths are drawn, rather than a property of the paths themselves).
>
>
> I don't think that's going to work.
>
> My take on what +setDefaultLineWidth: means is that this establishes
> the value for a path's -lineWidth when it is first created. From that
> instant on, the path itself has a defined line width, a copy of the
> default value. If you never set the default I believe it defaults to
> 1.0.
>
> When you dearchive the paths the line width of each will be whatever
> is recorded for them, which came from the default on the source
> machine at the time they were created. Changing the default line width
> on your machine will have no effect on these values.
>
> If you want to change the line width when the paths are drawn, you'll
> have to set each one individually prior to drawing.
>
> --Graham
>
>


_______________________________________________

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: Removing or ignoring "lineWidth" property of an NSBezierPath instance
      • From: Graham Cox <email@hidden>
References: 
 >Re: Removing or ignoring "lineWidth" property of an NSBezierPath instance (From: Graham Cox <email@hidden>)

  • Prev by Date: Re: Clicking through a NSView with CALayers
  • Next by Date: 10.4.x install for testing...
  • Previous by thread: Re: Removing or ignoring "lineWidth" property of an NSBezierPath instance
  • Next by thread: Re: Removing or ignoring "lineWidth" property of an NSBezierPath instance
  • Index(es):
    • Date
    • Thread