Posts Tagged ‘css’

CSS2UML - generating hierarchy graphs from CSS

Wednesday, May 14th, 2008

One day doing my labour work - related with models transformations. Unexpectantly work results was interesting and not quite but i wanned but, decided share my results with you.

Main work idea was model transformation. But in this case transformation results was unextpected. Was created prototype witch allows generate hierarchy graphs from CSS (Cascading style sheets)

How does it works ?
Generatoriaus veikimo schema

Schema is quite simple (P.s at some schema elements you can do not pay attention) they were left just for simplifying understandability.

Like you see graphs are drawed using graphviz tool. This tool is also used by doxygen doxygen for drawing diagrams. For parsing CSS file is used csstidy, but tools is not quite stable atleast. Talking about graphs results it’s submited in the picture.

Įrankio sugeneruotas grafikas

Also would like to mention that tool does support complete CSS standards like (p + table) and so on. But most regular CSS files it parses “correctly”. One of the interesting result graphs . Also nocited that there are some problems with comments interpretatio. Of course you can play your self.

Talking about practical adoption the only purpose of this tool i see possibility use this tool for better understanding page CSS hierarchy then need quick integrate some enchantments do not breaking whole CSS structure.

Working tool realization can be found here