Inside SVG files, shouldn't element.style have members like stroke and fill?

RESOLVED DUPLICATE of bug 374216

Status

()

RESOLVED DUPLICATE of bug 374216
10 years ago
10 years ago

People

(Reporter: will.pittenger1+mozbugzilla, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

10 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.3) Gecko/2008092417 Firefox/3.0.3
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.3) Gecko/2008092417 Firefox/3.0.3

I was going to use element.style.stroke (actually whatever the width would be) to change the stroke of an object from EmcaScript.  But element.style has no fill or stroke members.  Rather, the only members are only appropriate in HTML/XHTML.  They are of no use in SVG.

I couldn't even determine what would correspond to stroke-width with out something like Firebug or Venkman showing SVG attributes.  Any attempt to set any stroke or fill attribute results in an error unless you change the string.  That would be bad coding.

Reproducible: Always

Steps to Reproduce:
1. Examine the members of element.style of any object in any SVG file.
2. You will not see anything to do with stroke or fill as would be expected.
3. Rather, you see XHTML/HTML attributes which are no help in SVG.
Actual Results:  
Only XHTML/HTML attributes are accessible inside element.style in any SVG file from JavaScript.

Expected Results:  
SVG attributes should be available inside element.style.

Updated

10 years ago
Status: UNCONFIRMED → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 374216
You need to log in before you can comment on or make changes to this bug.