Jump to content


Get Style associated with an element via API

  • Please log in to reply
1 reply to this topic

#1 mitya777



  • Members
  • PipPip
  • 28 posts

Posted 09 June 2012 - 12:10 PM

Hi all,

I was wondering whether anyone was familiar with whether it was possible to get the Style associated with an element.

To set a style I can do something like:

fw.getDocumentDOM().applyStyle("Some Style", 0);

But I'd like to do something like:

fw.selection[0].getStyle(); //returns "Some Style"

Fireworks must have this link somewhere because when I click on an element to which a Style has been applied, it shows up on the very right of the properties inspector. Wondering whether an api call exists to get it.


#2 jdunning


    Fireworks Ninja

  • Members
  • PipPipPipPipPip
  • 173 posts

Posted 22 June 2012 - 01:46 PM

I haven't looked into styles too closely, but I haven't seen much in the way of APIs for them.