Hi folks,

as abaco doesn't yet have CSS support, I intend to write some 
tiny CSS parser/loader.

If we represent the CSS contents as an tree structure, we basicly 
have these node types:

* media type: container for holding media-specific data.
  per default we're operating in "all". to make it simplier,
  the parse could be told to only honor one specific type.
* @import: tells us to include another file
  it could be either resolved within the parsing process by 
  an call-back or simply added to the output tree
* per-object: has one and more object addresses (eg. via ID, 
  classname or even some path) and contains a list of properties.
  for make it simpler, we can "flatten" multiple addresses by 
  inserting an copy per single address
* object properties: are just name+value pairs of (almost) 
  arbitrary strings. some of the values could be also parsed and 
  split into several other properties (eg. some url() statement
  could be replaced by an addittional *-url property).

While parsing this way into a list of property lists isn't that
challenge, there are still some open questions, eg. should most
of the properties representing specific type of data (eg. borders
and padding) be split off to the finest granilarity and maybe also
identified by an integer ID instead of the name or does this 
belong to the client (-> renderer) ?


cu
-- 
---------------------------------------------------------------------
 Enrico Weigelt    ==   metux IT service - http://www.metux.de/
---------------------------------------------------------------------
 Please visit the OpenSource QM Taskforce:
        http://wiki.metux.de/public/OpenSource_QM_Taskforce
 Patches / Fixes for a lot dozens of packages in dozens of versions:
        http://patches.metux.de/
---------------------------------------------------------------------

Reply via email to