Open Bug 929703 Opened 11 years ago Updated 2 years ago

<treechildren tooltip="_child"> doesn't work

Categories

(Core :: XUL, defect)

x86_64
All
defect

Tracking

()

UNCONFIRMED

People

(Reporter: peter.kehl, Unassigned)

Details

(Keywords: dev-doc-needed)

Attachments

(3 files)

1.06 KB, application/vnd.mozilla.xul+xml
Details
1.07 KB, application/vnd.mozilla.xul+xml
Details
1.20 KB, application/vnd.mozilla.xul+xml
Details
Attached file treeTooltipLocal.xul
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Firefox/24.0 (Beta/Release)
Build ID: 20130917102605

Steps to reproduce:

Attached are 2 XULs:
- treeTooltipGlobal has <treechildren tooltip="id-of-tooltip-here">. Tooltip works for it. This is just for reference.
- treeTooltipLocal has <treechildren tooltip="_child"> and that element has a child element <tooltip label="text-here">. That doesn't work.



Actual results:

When I put a mouse over cells in treeTooltipLocal, I get no tooltip.


Expected results:

According to https://developer.mozilla.org/en-US/docs/XUL/Attribute/tooltip, when I use tooltip="_child" (as in treeTooltipLocal.xul), it should use the first tooltip child element. It's not doing it.
Attached file treeTooltipGlobal.xul
Component: Untriaged → XUL
OS: Linux → All
Product: Firefox → Core
Version: 24 Branch → Trunk
treechildren doesn't layout or draw its child elements so this is correct. You'll need to point to an element elsewhere.
Status: UNCONFIRMED → RESOLVED
Closed: 11 years ago
Resolution: --- → INVALID
The behaviour may be correct. However, the documentation is not:

https://developer.mozilla.org/en-US/docs/XUL/treechildren#Attributes clearly lists 'tooltip' attribute (even though inherited from XUL). That page doesn't mention anything about treechildren not laying out/drawing its child elements.

That page links to https://developer.mozilla.org/en-US/docs/XUL/Attribute/tooltip, which doesn't mention this special treechildren-specific behaviour, either.

The documentation doesn't clearly describe the behaviour. There may be docs on this somewhere else, but that doesn't matter; the above docs are misleading (for treechildren).

I'm requesting the docs to be changed. Putting this back to UNCONFIRMED.
Status: RESOLVED → UNCONFIRMED
Resolution: INVALID → ---
Keywords: dev-doc-needed
Also, tooltip="_child" doesn't work for <treeitem> or <treecell>. You need to fix their documentation, too.

See attached treeItemOrRowTooltip.xul.
Implementation of <tree>, <treeitem>, <treecell> etc. seems to be a can of worms. According to https://developer.mozilla.org/en-US/docs/XUL/treecell and similar respective pages, they're supposed to have 'className' property, inherited from XUL, which operates on 'class' attribute.

However, setting 'className' property has no visual effect.
No, everything inside a treechildren element is not drawn directly. The children inside it only serve as a shorthand placeholders for the data to be placed in the tree for those simple cases where you don't want to implement a tree view.

This is all documented at https://developer.mozilla.org/en/XUL_Tutorial/Trees
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: