Re: drawAtPoint rendering thin, light text?
Re: drawAtPoint rendering thin, light text?
- Subject: Re: drawAtPoint rendering thin, light text?
- From: Jörn Salewski <email@hidden>
- Date: Thu, 30 Oct 2003 19:14:06 +0100
am 30.10.2003 17:40 Uhr schrieb Ev unter email@hidden:
>
I've noticed a difference in my string drawing from almost all other
>
text drawing in the OS...
>
>
Calling [NSString drawAtPoint: attributes:] with these attributes
>
(declared earlier):
>
>
rulerTextAttributes = [[NSDictionary alloc] initWithObjectsAndKeys:
>
[NSFont fontWithName:@"Lucida Grande" size:9.],
>
NSFontAttributeName,
>
[NSColor darkGrayColor], NSForegroundColorAttributeName,
>
nil];
>
>
...makes the text look very thin and badly rendered, compared to the
>
same attributes when the font is drawn in TextEdit
>
>
check out this small screen shot:
>
>
http://www.triplo.com/ev/drawAtPointIssue.gif
>
>
On the top and behind is TextEdit's interpretation of darkGray Lucida
>
Grande 9
I could imagine that it has nothing to do with the attributes, but rather
with the location where you' re drawing.
Maybe your x and y coordinates of your NSPoint are uneven numbers. In this
case the drawing could fall in between the actual screen pixels and causing
unwanted 'antialiasing.' If so, you could try to round the NSPoint
coordinates to the nearest decimal.
Just a thought.
Cheers,
JS
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.