Implement filter xlink:href

RESOLVED FIXED in mozilla14

Status

()

Core
SVG
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: Robert Longson, Assigned: Robert Longson)

Tracking

Trunk
mozilla14
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(1 attachment)

(Assignee)

Description

6 years ago
Should be able to link filters via xlink:href so that any attributes which are defined on the referenced ‘filter’ element which are not defined on the current element are inherited.

We already implement this for gradients and patterns and the new code follows the approach taken there.
(Assignee)

Comment 1

6 years ago
Created attachment 609706 [details] [diff] [review]
patch with reftest
Assignee: nobody → longsonr
Attachment #609706 - Flags: review?(roc)
(Assignee)

Updated

6 years ago
Attachment #609706 - Flags: review?(roc) → review+
(Assignee)

Comment 2

6 years ago
pushed https://hg.mozilla.org/integration/mozilla-inbound/rev/24b7f6c27ee1
Flags: in-testsuite+
Target Milestone: --- → mozilla14
Comment on attachment 609706 [details] [diff] [review]
patch with reftest

Review of attachment 609706 [details] [diff] [review]:
-----------------------------------------------------------------

::: layout/svg/base/src/nsSVGFilterFrame.cpp
@@ +304,5 @@
> +nsSVGFilterFrame::GetFilterContent(nsIContent *aDefault)
> +{
> +  PRUint32 count = mContent->GetChildCount();
> +  for (PRUint32 i = 0; i < count; ++i) {
> +    nsIContent* child = mContent->GetChildAt(i);

This will be O(n^2) once we remove the array-based storage... We've been working to remove this pattern in favour of

for (nsIContent* child = mContent->GetFirstChild();
     child;
     child = child->GetNextSibling())
(Assignee)

Comment 4

6 years ago
(In reply to Ms2ger from comment #3)
Probably best to raise another bug so that http://mxr.mozilla.org/mozilla-central/source/layout/svg/base/src/nsSVGFilterInstance.cpp#202 can be addressed too.
(Assignee)

Updated

6 years ago
Depends on: 739972
https://hg.mozilla.org/mozilla-central/rev/24b7f6c27ee1
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.