C# Class LayoutFarm.WebDom.Parser.CssParserHelper

Parser to parse CSS stylesheet source string into CSS objects.
Datei anzeigen Open project: prepare/HTML-Renderer

Public Methods

Method Description
ParseStyleSheet ( string stylesheet, WebDom defaultActiveSheet, bool combineWithDefault ) : WebDom.CssActiveSheet

Parse the given stylesheet source to CSS blocks dictionary.
The CSS blocks are organized into two level buckets of media type and class name.
Root media type are found under 'all' bucket.
If combineWithDefault is true the parsed css blocks are added to the default css data (as defined by W3), merged if class name already exists. If false only the data in the given stylesheet is returned.

ParseStyleSheet ( WebDom cssData, string cssTextSource ) : void

Parse the given stylesheet source to CSS blocks dictionary.
The CSS blocks are organized into two level buckets of media type and class name.
Root media type are found under 'all' bucket.
The parsed css blocks are added to the given css data, merged if class name already exists.

Method Details

ParseStyleSheet() public static method

Parse the given stylesheet source to CSS blocks dictionary.
The CSS blocks are organized into two level buckets of media type and class name.
Root media type are found under 'all' bucket.
If combineWithDefault is true the parsed css blocks are added to the default css data (as defined by W3), merged if class name already exists. If false only the data in the given stylesheet is returned.
public static ParseStyleSheet ( string stylesheet, WebDom defaultActiveSheet, bool combineWithDefault ) : WebDom.CssActiveSheet
stylesheet string raw css stylesheet to parse
defaultActiveSheet WebDom
combineWithDefault bool true - combine the parsed css data with default css data, false - return only the parsed css data
return WebDom.CssActiveSheet

ParseStyleSheet() public static method

Parse the given stylesheet source to CSS blocks dictionary.
The CSS blocks are organized into two level buckets of media type and class name.
Root media type are found under 'all' bucket.
The parsed css blocks are added to the given css data, merged if class name already exists.
public static ParseStyleSheet ( WebDom cssData, string cssTextSource ) : void
cssData WebDom the CSS data to fill with parsed CSS objects
cssTextSource string raw css stylesheet to parse
return void