Cocoa Objective-c line drawing


Whenever I draw lines in NSView, the lines appear blurred and are not sharp.
What can I do to avoid this?

I have seen many links regarding this topic ... but none worked.
So, a sample xcode project for this would be great..
LVL 12
Who is Participating?
Have you tried turning off the antialiasing? You can do this by invoking the following call before doing the drawing:

[[NSGraphicsContext currentContext] setShouldAntialias:NO];

venkateshwarrAuthor Commented:

It worked! Thanks for ur help
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.