Re: Text blurred in application
Make sure the PDF is not larger than the button and that it does not contain bitmaps. On 28 Nov 2008, at 23:44:41, Richard Somers wrote: On Nov 28, 2008, at 3:06AM, Adil Saleem wrote: But the static text is not readable when application is launched. It is too blurred. I have been using pdf files for NSButton images. Sometimes the images will be blurred. I have not figured it out yet. Richard ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: Text blurred in application
The pdf canvas size is 25 points x 25 points and displayed full size in the button. It contains only vector graphics. I thought pdf would be the best thing for the simple graphics but it is hard to get it pixel perfect. Many of the paths have pixel exact boundaries within the graphics application. But when these are used in Interface Builder for a NSButton image the pdf output is inconsistent. It seems to have a mind of its own. On Nov 29, 2008, at 4:32AM, Benjamin Dobson wrote: Make sure the PDF is not larger than the button and that it does not contain bitmaps. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: Text blurred in application
I just discovered part of my problem. The pdf image was being scaled down slightly even though there was plenty of room for it inside the NSButton. The default scaling is Proportionally Down. Change this to None and the image now is always sharp, at least for a User Interface Resolution of 1.0. Change the User Interface Resolution to 1.25 or 1.5 and the pdf image is ok but not great. This is apparently because A shape is scan- converted by painting any pixel whose square region intersects the shape, no matter how small the intersection is. according to the Scan Conversion Rules in the pdf standard. I think this is why it looks less sharp at these resolutions. Note that fonts get special treatment and will render more precisely because they are hinted. Anyway, perhaps this is why the final image used for many Apple widgets are bitmapped tiff files and not vector pdf. You can tweak each and every pixel in a tiff file if you want to. For me I just wanted to make single vector image and be done with it. On Nov 29, 2008, at 7:33AM, Richard Somers wrote: The pdf canvas size is 25 points x 25 points and displayed full size in the button. It contains only vector graphics. I thought pdf would be the best thing for the simple graphics but it is hard to get it pixel perfect. Many of the paths have pixel exact boundaries within the graphics application. But when these are used in Interface Builder for a NSButton image the pdf output is inconsistent. It seems to have a mind of its own. On Nov 29, 2008, at 4:32AM, Benjamin Dobson wrote: Make sure the PDF is not larger than the button and that it does not contain bitmaps. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: Text blurred in application
On Nov 29, 2008, at 10:57 AM, Richard Somers wrote: I just discovered part of my problem. The pdf image was being scaled down slightly even though there was plenty of room for it inside the NSButton. The default scaling is Proportionally Down. Change this to None and the image now is always sharp, at least for a User Interface Resolution of 1.0. Change the User Interface Resolution to 1.25 or 1.5 and the pdf image is ok but not great. This is apparently because A shape is scan-converted by painting any pixel whose square region intersects the shape, no matter how small the intersection is. according to the Scan Conversion Rules in the pdf standard. I think this is why it looks less sharp at these resolutions. Note that fonts get special treatment and will render more precisely because they are hinted. Anyway, perhaps this is why the final image used for many Apple widgets are bitmapped tiff files and not vector pdf. You can tweak each and every pixel in a tiff file if you want to. For me I just wanted to make single vector image and be done with it. YMMV, but over 99% of my apps images are all vector-based PDF. They scale beautifully at any scaling factor between 0.5 and 3.0 (to include the non-integral ones). Artwork is anything from very simple to very complex (to include vectorized versions of original artwork from Poser). I created a class to manage drawing of such images. When drawing, you must normalize the destination rect such that it will always fall on integral boundaries: + (void)makeIntegralRectForScaling_II:(NSRect*)aRect { if (scalingFactor_II != 1.0) { aRect-origin.x *= scalingFactor_II; aRect-origin.y *= scalingFactor_II; aRect-size.width *= scalingFactor_II; aRect-size.height *= scalingFactor_II; *aRect = NSIntegralRect (*aRect); aRect-origin.x /= scalingFactor_II; aRect-origin.y /= scalingFactor_II; aRect-size.width /= scalingFactor_II; aRect-size.height /= scalingFactor_II; } } ___ Ricky A. Sharp mailto:[EMAIL PROTECTED] Instant Interactive(tm) http://www.instantinteractive.com ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: Text blurred in application
Hi, My scenario is a little different than what you have described. I don't have images on buttons. I have my custom window (which is a black colored image) and on it are the static texts. These texts are displaying blurred. Although i have not been able to figure out why is this happening, but i got a work around by using a different color shade of window image. So my problem is solved, but if anyone could explain the reason for that, it would be nice. It would come in handy for future use. Thank you --- On Sat, 11/29/08, Richard Somers [EMAIL PROTECTED] wrote: From: Richard Somers [EMAIL PROTECTED] Subject: Re: Text blurred in application To: cocoa-dev@lists.apple.com Date: Saturday, November 29, 2008, 8:57 AM I just discovered part of my problem. The pdf image was being scaled down slightly even though there was plenty of room for it inside the NSButton. The default scaling is Proportionally Down. Change this to None and the image now is always sharp, at least for a User Interface Resolution of 1.0. Change the User Interface Resolution to 1.25 or 1.5 and the pdf image is ok but not great. This is apparently because A shape is scan-converted by painting any pixel whose square region intersects the shape, no matter how small the intersection is. according to the Scan Conversion Rules in the pdf standard. I think this is why it looks less sharp at these resolutions. Note that fonts get special treatment and will render more precisely because they are hinted. Anyway, perhaps this is why the final image used for many Apple widgets are bitmapped tiff files and not vector pdf. You can tweak each and every pixel in a tiff file if you want to. For me I just wanted to make single vector image and be done with it. On Nov 29, 2008, at 7:33AM, Richard Somers wrote: The pdf canvas size is 25 points x 25 points and displayed full size in the button. It contains only vector graphics. I thought pdf would be the best thing for the simple graphics but it is hard to get it pixel perfect. Many of the paths have pixel exact boundaries within the graphics application. But when these are used in Interface Builder for a NSButton image the pdf output is inconsistent. It seems to have a mind of its own. On Nov 29, 2008, at 4:32AM, Benjamin Dobson wrote: Make sure the PDF is not larger than the button and that it does not contain bitmaps. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/adilsaleem01%40yahoo.com This email sent to [EMAIL PROTECTED] ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Text blurred in application
Hi, I am having a problem with the way my application displays text. In my application, i have some NSTextFields (static text) on a custom window of mine. But the static text is not readable when application is launched. It is too blurred. At first i thought it was because the text size is small, but then i checked it for larger text size and different fonts. But they all show same results. What is really strange is that the same appliation displays perfectly when an external monitor is connected with the MacBook, but text displays horribly when running on MacBook. I have verified this 3-4 MacBooks. It is not a problem with my MacBook. Any suggestions why it is happening and how can i remove this problem? Maybe it has got something to do with the drawing within the application, not sure. Please guide. Thank You ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: Text blurred in application
On 28 Nov 2008, at 10:06:28, Adil Saleem wrote: Hi, I am having a problem with the way my application displays text. In my application, i have some NSTextFields (static text) on a custom window of mine. But the static text is not readable when application is launched. It is too blurred. At first i thought it was because the text size is small, but then i checked it for larger text size and different fonts. But they all show same results. What is really strange is that the same appliation displays perfectly when an external monitor is connected with the MacBook, but text displays horribly when running on MacBook. I have verified this 3-4 MacBooks. It is not a problem with my MacBook. Any suggestions why it is happening and how can i remove this problem? Maybe it has got something to do with the drawing within the application, not sure. Please guide. Thank You make sure that Core Animation is turned off if you're running Leopard. Other than that, I don't know what advice I can give you. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: Text blurred in application
I am running it on Leopard and Core animation is turned off. --- On Fri, 11/28/08, Benjamin Dobson [EMAIL PROTECTED] wrote: From: Benjamin Dobson [EMAIL PROTECTED] Subject: Re: Text blurred in application To: cocoa-dev@lists.apple.com Date: Friday, November 28, 2008, 1:54 PM On 28 Nov 2008, at 10:06:28, Adil Saleem wrote: Hi, I am having a problem with the way my application displays text. In my application, i have some NSTextFields (static text) on a custom window of mine. But the static text is not readable when application is launched. It is too blurred. At first i thought it was because the text size is small, but then i checked it for larger text size and different fonts. But they all show same results. What is really strange is that the same appliation displays perfectly when an external monitor is connected with the MacBook, but text displays horribly when running on MacBook. I have verified this 3-4 MacBooks. It is not a problem with my MacBook. Any suggestions why it is happening and how can i remove this problem? Maybe it has got something to do with the drawing within the application, not sure. Please guide. Thank You make sure that Core Animation is turned off if you're running Leopard. Other than that, I don't know what advice I can give you. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/adilsaleem01%40yahoo.com This email sent to [EMAIL PROTECTED] ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
Re: Text blurred in application
On Nov 28, 2008, at 3:06AM, Adil Saleem wrote: But the static text is not readable when application is launched. It is too blurred. I have been using pdf files for NSButton images. Sometimes the images will be blurred. I have not figured it out yet. Richard ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]