Open Bug 296191 Opened 19 years ago Updated 2 years ago

Tooltip placement doesn't respect CSS cursor size [cursor: url(...);]

Categories

(Core :: Widget, enhancement, P3)

x86
All
enhancement

Tracking

()

People

(Reporter: mithgol, Unassigned)

References

(Depends on 1 open bug)

Details

(Keywords: polish, Whiteboard: tpi:+)

Attachments

(2 files)

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b2) Gecko/20050531 Firefox/1.0+ Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b2) Gecko/20050531 Firefox/1.0+ Section 18.1 of CSS 2.1 Specification (see http://www.w3.org/TR/CSS21/ui.html#cursor-props for details) explains how a custom cursor can be enabled for virtually any element of the webpage. However, if that element (e.g. a hyperlink) has a tooltip as well (e.g. via non-empty title="..." attribute), it is displayed in Deer Park without any respect to actual cursor height, as if it always were the standard Windows hand (i.e. the tooltip is displayed about 22px below the precise position that the cursor is being pointed to). If the actual cursor is higher than that, it happily overlays the tooltip, rendering one or two first letters of the tooltip covered by cursor at least partially. Reading the tooltip is made somewhat more tricky and less happy experience for the user. Reproducible: Always Steps to Reproduce: 1. Open the HTML attachment (I am going to provide at least one below). 2. Hover your mouse cursor over the link. 3. Wait for tooltip. Actual Results: Cursor is partially above the tooltip. Expected Results: Tooltip should be displayed precisely below the lowermost element of the cursor. I am going to attach a cursor first, then the HTML example of this bug. Be morally prepaired ;-)
Attached file HTML example (deleted) —
Additional hint: the HTML example should be completely loaded ("Done" in browser status line) in order to display the custom cursor. If it is not, then the cursor is probably not loaded yet. I've just reproduced the bug with this HTML attachment.
This bug depends on Bug 38447 -- I am adding it to the dependency tree.
Depends on: 38447
Adding a CC e-mail of Christian Biesinger, who once was expert enough to code a patch for bug 38447. (...Is it a piece of cake to find out the cursor's actual height?) A tooltip expert will probably also be needed here, but I just don't know whom I should invite... :-(
not a widget:win32 bug, as evidenced by the fact that it happens on linux too. I hope the new component is better... note that it is probably unrelated to cursor:url cursors at all - it seems very likely that it happens also if you choose a custom hand cursor in your system config.
Assignee: win32 → jag
Component: Widget: Win32 → XP Toolkit/Widgets
OS: Windows XP → All
QA Contact: ian → jrgmorrison
Until someone implements a way of measuring the hot spot height (distance from the hot spot to the last non-transparent row) of user and system cursors on all platforms we're going to be stuck with the current hardcoded values.
For custom cursors we have imgIContainer and can directly iterate its pixels to find out which is the last transparent row. It's (more or less) an easy problem. The code that patched bug 38447 could be extended to accomplish this task. So the problem with system cursors, though related, is nevertheless a separate (and more complicated) bug, and it should be treated and solved separately, not delaying this one.
isn't tooltip positioning done in xul/js?
I am not sure whether XUL element <tooltip position="..."> is used here. And, by the way: probably, this bug exists in XUL elements as well. Do you need a chrome testcase? Then I could add a high enough cursor to my extension at http://Mithgol.Ru/Mozilla/Firefox/ to see how it behaves in chrome.
it works perfectly for me... Mozilla deep park alpha 2 (not nightly)
Depends on: 113009
QA Contact: jrgmorrison → xptoolkit.widgets
Assignee: jag → nobody
(In reply to comment #11) > as is pointed out in bug 115447, comment 7, the real fix would come from bug 113009. Sergey, still see this bug, 113009 and bug 248718?
I still see this bug in Firefox 3.6.4 on Windows XP with my testcase (attached here), and I also see bug 248718. Bug 113009 has no testcase for me to test against, and thus I cannot easily confirm or deny its effects.
Can confirm the bug for Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.6) Gecko/20100625 Firefox/3.6.6 With Bug 541182 hopefuly fixed in 1.9.2.7, the tooltip will completely disappear behind bigger cursors. Was this bug really found 2005-06-01 - and no official confirmation yet? Please, at least confirm it, thanks!
I still see that bug 296191 exists in Firefox 11 on Windows XP SP3, and bug 248718 also.
Very similar to bug 248718 and bug 557754, but the CSS cursor is an additional step.
Severity: normal → enhancement
Status: UNCONFIRMED → NEW
Component: XUL → Widget
Depends on: 248718
Ever confirmed: true
Summary: Custom CSS cursors [cursor: url(...);] sometimes overlay the link tooltips [title="..."] -- Deer Park should respect cursor height and display the tooltip below the cursor (not under the cursor) → Tooltip placement doesn't respect CSS cursor size [cursor: url(...);]
Keywords: polish
Priority: -- → P3
Whiteboard: tpi:+
Compare Bug 248718 and second testcase there.
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: