The problem appears in Mail on Lion using the Fonts and Colors palette to customize colors and fonts. * STEPS TO REPRODUCE 1. Create new message, write some text. 2. Select text, use color picker to change color to a color other than black. 3. With text still selected, use color picker to change color to black. * RESULTS Text becomes invisible/transparent. It should be black. * REGRESSION The Fonts and Color palette work as expected in previous version of Mac OSX.
<rdar://problem/9460733>
AppKit's behavior changed in Lion. If the NSForegroundColorAttributeName is solid black, it is removed from the attributes dictionary. WebKit used to treat the missing color as an indication of transparent color.
Created attachment 122833 [details] Patch
Thanks for the review! Dan pointed out that I should write a TestWebKitAPI test and has shown me how to do it. I'll post another patch that has the test.
Created attachment 122856 [details] Patch with test
Comment on attachment 122856 [details] Patch with test View in context: https://bugs.webkit.org/attachment.cgi?id=122856&action=review > Tools/TestWebKitAPI/Tests/mac/InspectorBar.mm:28 > +#import <WebKit/DOMPrivate.h> Is thIs needed?
(In reply to comment #6) > (From update of attachment 122856 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=122856&action=review > > > Tools/TestWebKitAPI/Tests/mac/InspectorBar.mm:28 > > +#import <WebKit/DOMPrivate.h> > > Is thIs needed? No, I've removed it. Thanks for pointing it out.
http://trac.webkit.org/changeset/105291
Just wanted to say thanks for fixing this. it drives me nuts.