Giter VIP home page Giter VIP logo

Comments (15)

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
r174 incorporates this improvement to the trunk. Improves the code that handles
getting and setting attributes, and simplifies style parsing. getAttribute() is 
used
in rendering code instead of styles. Styles are now parsed upon being set 
instead of
upon rendering. This merges r117, 118, r128, r129 and portions of r148 and r155,
from James experimental branch. 
Issue 14 was also resolved by r174.

Original comment by [email protected] on 7 Feb 2009 at 6:02

  • Changed state: Fixed

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
Unfortunately the native support in Firefox and Safari keep attributes and 
style=""
values separate. The SVG spec itself doesn't have enough detail around correct
behavior, but Firefox and Safari are identical in this respect. Reopening bug 
with
two goals:

* Restore separate attribute and style="" handling
* Get photos.svg to work with separated handling (Rick said that photos.svg was
failing before this -- perhaps it's related to something else).

Original comment by [email protected] on 30 Mar 2009 at 8:55

  • Changed state: Accepted

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
I'm making these changes on my branch so far (branches/brad-merge-to-trunk). 
Here's
an overview of the architecture I am going to take.

I am adding two new methods, setStyle() and getStyle(). There is now still
getAttribute() and setAttribute(), but those only get and set the XML 
attributes and
do not affect the CSS style="" string. There will also be a new getStyleOrAttr()
method that can be used to get a final value ready for displaying, such as
getStyleOrAttr('fill')

Original comment by [email protected] on 30 Mar 2009 at 11:30

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
BTW, I should mention that I am keeping the nice 'inherit' code, which will 
look up
the style tree through ancestors for inherited styles if they are not present 
on the
node that getStyle() is called on.

Original comment by [email protected] on 31 Mar 2009 at 12:10

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
r348 on branches/brad-merge-to-trunk implements this change. Commit message 
with details:

"attributes and styles are now tracked separately again to match what
Firefox and Safari does; new getStyle() and setStyle() methods are now there,
and getAttribute and setAttribute only return XML attributes now rather than
including CSS ones like in the past. We suport inherited styles in getStyle().
New method getStyleOrAttr() should be called when you want to get some value
that could be set either in XML or style='' string in order to build up
something to display. Note that getAttribute, getStyle, and getStyleOrAttr now
return null instead of an empty string when a prop name is not present. Tested
on my own files but I have not tested this on Rick's demo.html files yet."

I'm not able yet to test photos.svg; I will isolate what the issue is there 
later as
I get closer to supporting rendering that file on my branch.

Original comment by [email protected] on 31 Mar 2009 at 1:25

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024

Original comment by [email protected] on 31 Mar 2009 at 1:26

  • Changed title: Separate handling XML attributes and style values separately

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
Note: there are a number of issues with my change. I'm tracking down the bugs 
now and
will have another SVN checkin that should fix some new regressions from this 
change.

Original comment by [email protected] on 31 Mar 2009 at 5:50

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
r354 contains more fixes for this bug. However, I believe there might still be 
some
regressions from this refactoring so I wouldn't apply it to trunk yet.

Original comment by [email protected] on 31 Mar 2009 at 6:00

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
More fixes in r357.

Original comment by [email protected] on 31 Mar 2009 at 6:51

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
More fixes in r358 around correctly applying opacity to images, which I 
regressed
with my earlier changes for this bug.

Original comment by [email protected] on 31 Mar 2009 at 7:26

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
r361 fixes a regression I introduced around gradients. Fixed now.

Original comment by [email protected] on 31 Mar 2009 at 8:17

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
r362 fixes regression in filters caused by this refactoring.

Original comment by [email protected] on 31 Mar 2009 at 9:00

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
r363 needed as well.

Original comment by [email protected] on 31 Mar 2009 at 9:04

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
Gradients fixed in r364. This should be the last set of fixes necessary. 
Keeping open
though until I can test photos.svg.

Original comment by [email protected] on 31 Mar 2009 at 10:13

from svgweb.

GoogleCodeExporter avatar GoogleCodeExporter commented on September 27, 2024
I implemented this a long time ago. Also, since I brought trunk back in a few 
days
which has these together I had to re-seperate them once again.

Original comment by [email protected] on 10 Jun 2009 at 5:30

  • Changed state: Fixed

from svgweb.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.