Changeset 2863:f440617633ed in livinglogic.python.xist

Show
Ignore:
Timestamp:
08/07/07 18:38:27 (12 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Message:

Add docstring to html.itercssrules().

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/ll/xist/ns/html.py

    r2859 r2863  
    14521452 
    14531453def itercssrules(node, base=None, media=None): 
     1454    """ 
     1455    Return an iterator for all &css; rules defined in the &html; tree <arg>node</arg>. 
     1456    This will parse the &css; defined in any <class>style</class> or <class>link</class> 
     1457    element (and recursively in those stylesheets imported via the <lit>@import</lit> 
     1458    rule). The rules will be returned as <class>CSSStyleRule</class> objects 
     1459    from the <module>cssutils</module> package (so this requires <module>cssutils</module>). 
     1460    The <arg>base</arg> argument will be used as the base &url; for parsing the 
     1461    stylesheet references in the tree (so <lit>None</lit> means the &url;s will be 
     1462    used exactly as they appear in the tree). All &url;s in the style properties 
     1463    will be resolved. If <arg>media<arg> is given, only rules that apply to this 
     1464    media type will be produced. 
     1465    """ 
    14541466    if base is not None: 
    14551467        base = url.URL(base)