views:

26

answers:

1

I have the following problem : in my GWT project there is a "main" css file for the application, inline css in the DOM that come from the application computation and a css file that is bundled in an archive uploaded to the application and dynamically loaded.

Now I need for an Element to find which CSS rules are applied, coming from either of the three sources. As I understand, GWT's getStyle() function only returns informations that are in the DOM.

What's the simplest way to achieve this ?

Edit : If possible, I search for a client-side solution (in java or javascript) rather than a server-side one.

A: 

Found a solution to my problem (in fact two but I'm going for the first) :

  1. Using jQuery's css() that does what I wanted
  2. A pure javascript solution in this SO question

I now just have to write a JNSI wrapper for the jQuery function...

Edit : Found a third solution which correspond exactly to what I want : GQuery which is a port of jQuery to GWT and contains (according to the main page) 98% of jQuery's core functionalities.

Vinze