Closed
Bug 109184
Opened 23 years ago
Closed 3 years ago
Style "a:hover text-decoration:underline' works intermittently
Categories
(Core :: Layout, defect, P3)
Tracking
()
RESOLVED
INCOMPLETE
Future
People
(Reporter: trav, Unassigned)
References
()
Details
(Keywords: css2, Whiteboard: [CSS1-2.1][CSS1-5.4.3])
Attachments
(1 file)
18.92 KB,
image/png
|
Details |
The URL I gave is for demo purposes - I've seen this happen on other pages as
well (note that the navigation links on the left side aren't supposed to "hover
underline", but the other links on the page are).
When you have a style that indicates a link you're hovering over should be
underlined, Mozilla does not always render it - sometimes the underline appears,
and sometimes it doesn't. It does consistently reflect the color attribute
correctly though, so it's recognizing the hover state.
I've tried it with both 0.9.4 and 0.9.5 and gotten the same result. The pages
work correctly in Internet Explorer, so I'm sure the CSS is coded correctly.
Don't be so sure the CSS is coded correctly. IE has a bug where it gives :hover
a higher specificity than other pseudo-classes, or something like that. See
http://www.people.fas.harvard.edu/~dbaron/css/1999/09/links . Is that the
problem here?
Or could the problem be that the line below is obscuring part of the underline?
(Although the problem that I can think of that would have caused that would
have been fixed before 0.9.5, and I think also before 0.9.4, although I'm less
sure of that).
I don't see any problems on a current Linux build.
Reporter | ||
Comment 3•23 years ago
|
||
> ------- Additional Comments From dbaron@fas.harvard.edu 2001-11-08 16:59
> Don't be so sure the CSS is coded correctly. IE has a bug where it gives :hover
> a higher specificity than other pseudo-classes, or something like that. See
> http://www.people.fas.harvard.edu/~dbaron/css/1999/09/links . Is that the
> problem here?
I'll try not to take it personally, since I wrote the styles on that
page I used for a demo. ;-) Hey it's possible, I'll admit I'm not
perfect...
But I think there's a few problems with this. First, I believe this
USED to work correctly in Mozilla on Linux. Second, it works correctly
in Opera on Linux, and it works as expected in Netscape 6 on Windows (I
have mozilla 0.9.5/Windows at home, and I'll check that ASAP). Third, on
a link that wraps over several lines (on that page I originally gave, there's
one link whose text reads "Where are the leaders in the post-PC revolution?"),
some parts of that single link get underlined and some parts don't. The style
doesn't vary within a single link, obviously.
Could you attach a screenshot of the problem?
Reporter | ||
Comment 5•23 years ago
|
||
Unfortunately the mouse doesn't appear in the screenshot, but you'll see the
effect I'm talking about in the lower right section ("where are the
leaders...").
Do you know what font that text gets displayed in? (TrueType, bitmap,
Postscript, etc.?)
Reporter | ||
Comment 7•23 years ago
|
||
The font is "Lucida". The style declaration I'm using is
font-family: Lucida, Helvetica, Arial, sans-serif;
But I don't really know enough about how Red Hat 7.2 manages fonts to tell you
whether it's using True-Type, Type 1 or whatever, because I don't see a likely
file in any of my font directories - unless it's one of Abiword's
cryptically-named font files.
Anyway, Lucida seems to be the issue. I set up a test page whose only difference
is the removal of the Lucida font-family style entry, and the problem disappears:
http://www.ee.washington.edu/index-test.shtml
Since Windows browsers don't seem to be using Lucida anyway, I'm moving the
"problem" page that uses Lucida (just in case you need to check this) to
http://www.ee.washington.edu/index-lucida.shtml
I'm going to pull Lucida out of my default style sheet, so the original URL I
gave in the opening report will soon not reflect the problem anymore.
BTW this does seem to be a Linux-only issue, probably because of the font. On
Mozilla 0.9.5/Windows this problem doesn't occur.
Travis
![]() |
||
Updated•23 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Does the problem get better if you somehow obscure the window and cause it to
repaint while keeping the link in the :hover state? (Maybe an easier thing to
test would be if the underlines show up properly if they're the non-:hover style.)
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla0.9.9
This wasn't the bug I meant to accept.
Status: ASSIGNED → NEW
Target Milestone: mozilla0.9.9 → ---
Updated•23 years ago
|
Whiteboard: [CSS1-2.1][CSS1-5.4.3]
I suspect this could be an invalidation problem when the underline is outside
the bounds of the text frame. I see a similar problem for the edge of the "r"
in attachment 1810 [details] (on bug 5693, with my fix for bug 5693).
Comment 11•23 years ago
|
||
In which case the fix for this might be similar to the fix for 'outline'.
Bug 136935 is about a similar problem on windows (a regression due to recent
changes), although the fix for that is likely not to be useful here. I never
know, though. (This, in fact, could be a regression from my font metrics
changes that prevented text frames from overflowing their containers, bug 91794.)
Severity: normal → major
Status: NEW → ASSIGNED
Component: Style System → Layout
Priority: -- → P3
Target Milestone: --- → Future
Comment 13•23 years ago
|
||
am I to stupid to see it? ;)
Linux, 2002070508 and no problem!
This is expected to be unreproducable on most machines.
Comment 15•21 years ago
|
||
It's happening to me in build 2003082704, on windows 2000. The css i'm using is:
a:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
a:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
a:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
a:visited:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: underline;
}
a:active {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
Then i've a page with the following code:
<a href="link1.html">link1</a>
<a href="link2.html">link2</a>
Of notice, the link1.html exists in the same directory as the page that contains
the html. link2.html doesn't exist at all.
What i've observed is that the first link will appear underlined when the mouse
overs it. BUT link 2 will stay in normal (no underline at all).
Comment 16•21 years ago
|
||
The last comment is almost certainly caused by the fact that the style rules ask
for underlining only when the link is visited.
Comment 17•21 years ago
|
||
Is this still a problem?
Comment 18•21 years ago
|
||
(Win2k, Firefox 0.8) - I get this problem too when I use a font-size of 75% with
a padding-top value of less than 1em or a line-height value of less than 1.5em.
At larger font sizes (16px) a short underline may appear on wrapped lines. It
doesn't happen on every line and if you change em values from say .8 to .99 the
affected lines may change.
I can't see any obvious relationship to the shape of the font (e.g. descenders),
but it only happens with my monospaced font ("Courier New").
Comment 19•21 years ago
|
||
is bug 249402 a dupe of this?
Comment 20•20 years ago
|
||
*** Bug 270961 has been marked as a duplicate of this bug. ***
Comment 21•20 years ago
|
||
Testcase from the bug that was duped to this one:
https://bugzilla.mozilla.org/attachment.cgi?id=166572&action=view
Comment 22•18 years ago
|
||
Is this still an issue now on trunk?
Reporter | ||
Comment 23•18 years ago
|
||
I don't think it's been a problem for a while, even though it doesn't appear anyone worked on it directly. I can't see the problem on the original test page:
http://www.ee.washington.edu/index.html-lucida
Comment 24•18 years ago
|
||
Yeah, unfortunately that happens. Bugs that get worksforme without any developer working on it.
Anyone else who saw the bug, can he also test?
Updated•16 years ago
|
QA Contact: ian → layout
Comment 25•15 years ago
|
||
I think we can close this one. It appears to be working correctly for me too, with Firefox 3.5.3 on Mac.
Assignee: dbaron → nobody
Status: ASSIGNED → NEW
Comment 26•3 years ago
|
||
Hey Travis,
Can you still reproduce this issue or should we close it?
Flags: needinfo?(trav)
Comment 27•3 years ago
|
||
Marking this as Resolved > Incomplete since the last activity on this issue was 15 years ago and it might not be relevant anymore.
Feel free to re-open if the issue is still reproducible on your end in the latest FF versions.
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → INCOMPLETE
Reporter | ||
Comment 28•2 years ago
|
||
My apologies, I didn't see the follow-up from a year ago. Feel free to close it; I believe it's fixed.
Flags: needinfo?(trav)
You need to log in
before you can comment on or make changes to this bug.
Description
•