Closed
Bug 408369
Opened 17 years ago
Closed 14 years ago
spell check underline color is hardcoded
Categories
(Core :: Layout, defect)
Core
Layout
Tracking
()
RESOLVED
FIXED
People
(Reporter: kairo, Unassigned)
References
(Depends on 1 open bug, )
Details
Attachments
(1 file)
2.55 KB,
image/png
|
Details |
The (dotted) underline drawn by the spell checker is hardcoded in http://lxr.mozilla.org/seamonkey/source/layout/generic/nsTextFrameThebes.cpp#3708 which is a problem when one themes text boxes to have a red or reddish background color, as it visually disappears in that case and there's no possibility to theme it to a more appropriate color for that case.
Is there no possibility to move the whole thing into some theming CSS file or such?
Updated•17 years ago
|
Assignee: mscott → nobody
Component: Spelling checker → Layout
QA Contact: spelling-checker → layout
Comment 1•16 years ago
|
||
Can I add another reason to fix this bu? I am legally blind, so use a block background. That means no spell check. Thanks!
Comment 2•16 years ago
|
||
Same here (visual impairment).
Under certain circumstances, and differently colored text boxes and single line inputs, it is sometimes difficult to impossible to see the red underline.
![]() |
Reporter | |
Comment 3•16 years ago
|
||
Masayuki, I saw you were doing some change related to spell checker underline marking. Can anything be done regarding the issue here?
Ideally, we'd be able to change the spellcheck underline color at least in any context where we can change the background color it's displayed against, i.e. via some CSS in themes, I think.
Depends on: 256773
Comment 4•16 years ago
|
||
Ah, is the presudo-class useful for themes? It's easy to implement they are specified from CSS if it's needed.
I think the solution we eventually want here is something based on bug 256773.
![]() |
Reporter | |
Comment 6•16 years ago
|
||
Anything that allows to specify a different color when my textbox has, say, |background-color:red;| is usable. Of course you guys know better what fits well with stuff we're doing elsewhere in Gecko ;-)
Updated•16 years ago
|
Comment 7•16 years ago
|
||
I'm having a snake line to indicate errors, it's better than dot underline but the "wave" of snake is somehow too high that it often overlapped the text.
This hardcoded red dotted underline is a problem for me, too. For other reasons, I have to use a background color, which makes this red dotted line nearly invisible. So the spell-checker is of nouse for me.
The red color seems to be still hardcoded here in the source code:
http://mxr.mozilla.org/seamonkey/source/layout/generic/nsTextFrameThebes.cpp#3874
--- snip ---
3872 case nsISelectionController::SELECTION_SPELLCHECK: {
3873 nsCSSRendering::PaintDecorationLine(
3874 aContext, NS_RGB(255,0,0),
3875 aPt, size, aAscent, aFontMetrics.underlineOffset,
3876 NS_STYLE_TEXT_DECORATION_UNDERLINE, NS_STYLE_BORDER_STYLE_DOTTED);
3877 break;
3878 }
--- snap ---
The change from the hard-coded style to a CSS style parameter seems to be a minor change. Who is responsible for this code? Can also I submit such a fix?
Comment 10•14 years ago
|
||
Why are you looking such old code??
This is the latest code:
http://mxr.mozilla.org/mozilla-central/source/layout/generic/nsTextFrameThebes.cpp#4270
And you can change the color from pref which name is "ui.SpellCheckerUnderline". See also following URL for the detail:
http://mxr.mozilla.org/mozilla-central/source/widget/src/xpwidgets/nsXPLookAndFeel.cpp#146
Comment 11•14 years ago
|
||
Thank you, for your information. I see, it is fixed in this code.
I tested following lines in a user.js file with a TB 3.0.4:
user_pref("ui.SpellCheckerUnderline", "#ffff00");
respective
user_pref("ui.SpellCheckerUnderline", "yellow");
But it had no effect. Is this new code already active in this TB version? Or did I something wrong?
Comment 12•14 years ago
|
||
The fix was landed at 1.9.2 a1. So, TB3.1 or later has the code. TB 3.0 (Gecko 1.9.1) doesn't have the fix.
https://bugzilla.mozilla.org/show_bug.cgi?id=338209
Comment 13•14 years ago
|
||
Thanks, I got it working. So, why this Bug is not set to RESOLVED?
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•