• 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: [NEWBIE] how to.. ? drawing problems !!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [NEWBIE] how to.. ? drawing problems !!


  • Subject: Re: [NEWBIE] how to.. ? drawing problems !!
  • From: "John C. Randolph" <email@hidden>
  • Date: Sat, 28 Jul 2001 03:39:05 -0700

On Saturday, July 28, 2001, at 02:55 AM, Tommaso Pecorella wrote:

Hi, just a very newbie question: I know how to draw a NSBezierPath (even a complex path), however I still can't figure out how to draw a *single* point and a "hairline" line.

For my own purposes, I need o draw in non-antialias mode, so I disabled it, however no matter how I stroke the line or I set it's lineWidth (even 0.0), it's minimal width is 2 pixels.

In the default coordinate system the integer values are between the pixels, so if you draw a line from (10,10) to (10,20), the line touches the pixels on both sides. If you draw from (10.5, 10), to (10.5, 20), the line should fall exactly in the center of the pixels.

Give it a try.

-jcr

"These kids today don't know the simple joy of saving four bytes of page-0 memory on a 6502" - unknown


  • Follow-Ups:
    • Re: [NEWBIE] how to.. ? drawing problems !!
      • From: Tommaso Pecorella <email@hidden>
References: 
 >[NEWBIE] how to.. ? drawing problems !! (From: Tommaso Pecorella <email@hidden>)

  • Prev by Date: [NEWBIE] how to.. ? drawing problems !!
  • Next by Date: Re: NSTableView setDrawsGrid: YES doesn't result in Grid being drawn
  • Previous by thread: [NEWBIE] how to.. ? drawing problems !!
  • Next by thread: Re: [NEWBIE] how to.. ? drawing problems !!
  • Index(es):
    • Date
    • Thread