Closed Bug 279027 Opened 20 years ago Closed 20 years ago

xforms.css doesn't work in trunk builds

Categories

(Core Graveyard :: XForms, defect)

x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: smaug, Assigned: bryner)

Details

Attachments

(2 files)

Just try to use the following xforms.css in trunk builds. The background is not set to red. Works on branch. @namespace url(http://www.w3.org/2002/xforms); repeat, repeatitem, contextcontainer, group, switch, case { display: block; background: red !important; }
(In reply to comment #0) > Just try to use the following xforms.css in trunk builds. > The background is not set to red. Works on branch. It does not work if you set the style directly in the XHTML page either, so the bug must be hidden somewhere deeper. Not annoying at all, if one is looking at repeats for the moment ....argh :(
The elements seem to end up in the XHTML namespace instead, just forget the XForms namespace and it works. Could be bug 103225? It sets everything that is nsIContent::eHTML into the XHTML namespace.
Uh? Does xforms return true for IsContentOfType(eHTML)? Why? This will most likly lead to crashes since we assume that only nsGenericHTMLElement does that. See http://lxr.mozilla.org/mozilla/source/content/html/content/src/nsGenericHTMLElement.h#86
So could someone who knows how XForms is set up explain what the general deal is here? I know you guys use anonymous XHTML elements, but those should be in the XHTML namespace anyway, right? I don't see any IsContentOfType implementations in the XForms module....
(In reply to comment #4) > So could someone who knows how XForms is set up explain what the general deal is > here? I know you guys use anonymous XHTML elements, but those should be in the > XHTML namespace anyway, right? I don't see any IsContentOfType implementations > in the XForms module.... Yes, the anonymous content is XHTML, but the XTF-elements themselves are created in the XForms-namespace (in the page), and repeat, repeatitem, etc are the XTF elements.
I'm not familiar with how XTF works, but in XBL the anonymous content is styled as a separate entitiy. So the wrapping element is styled according to its name and namespace and the anonymous content is styled according to its. What I don't understand is how the patch in bug 103225 could have changed anything. The element that IsContentOfType is now called is before returned the XHTML namespace anyway, not the XForms namespace.
So can someone familiar with XForms: 1) Attach a testcase showing the problem 2) Estimate when this regressed?
Attached file test xforms.css
This .css should cause xforms testcases with groups, etc. to show red borders. It doesn't.
Attached file xforms group testcase
group testcase that, when loaded, should show the input field surrounded by a red box
The FREAKIEST thing is that when I build and run with my XForms XPath extensions patch, I DO see the red box. But my patch doesn't affect any of the limited xpath that is in this testcase. Timing bug? I also noticed last week that with my xpath patch, external instance data is loading, too. And the problem there was that without the xpath patch, our load handler was never getting callback for load finish of the external document. Something crazy going on! Must be the magical incantations I say over my xpath patch :=)
How are you guys binding xforms.css to the document? comment 1 seems to indicate that this happens even for inline stylesheets. Is that true? If so, could you create a very simple testcase with just two or three elements and an inline stylesheet.
Hmmm, did this sort of just fix itself?
(In reply to comment #12) > Hmmm, did this sort of just fix itself? I would like to have an answer to why we had problems, but it works does it not? ... "works for me".
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → WORKSFORME
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: