Changeset 3128:db1435a72dfc in livinglogic.python.xist

Show
Ignore:
Timestamp:
01/06/08 22:35:50 (12 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Message:

Shorted names of many doc elements to something more familiar.

* function to func;
* method to meth;
* module to mod;
* property to prop;
* title to h;
* par to p;
* olist to ol;
* ulist to ul;
* dlist to dl;
* item to li or dd (depending on whether it's inside an ol, ul or dl);
* term to dt;
* link to a.

Files:
56 modified

Legend:

Unmodified
Added
Removed
  • INSTALL.rst

    r3118 r3128  
    5050the ``site-packages`` directory as the :mod:`ll.xist` package. 
    5151 
    52 <par>For Windows a binary distribution is provided. To install it, 
     52<p>For Windows a binary distribution is provided. To install it, 
    5353double click it, and follow the instructions. 
    5454 
  • INSTALL.xml

    r3062 r3128  
    11<?xml version='1.0' encoding='iso-8859-1'?> 
    2 <section><title>Requirements</title> 
    3 <par>To use &xist; you need the following software packages:</par> 
    4 <olist> 
    5 <item><link href="http://www.python.org/">Python 2.5</link>,</item> 
    6 <item><link href="root:core/index.html">ll-core</link> (1.11 or newer),</item> 
     2<section><h>Requirements</h> 
     3<p>To use &xist; you need the following software packages:</p> 
     4<ol> 
     5<item><a href="http://www.python.org/">Python 2.5</a>,</item> 
     6<item><a href="root:core/index.html">ll-core</a> (1.11 or newer),</item> 
    77<item>if you want to use automatic image size calculation: the 
    8 <link href="http://www.pythonware.com/products/pil/">Python Imaging Library</link>,</item> 
    9 <item>if you want to parse broken &html;: <link href="http://www.xmlsoft.org/">libxml2</link> 
     8<a href="http://www.pythonware.com/products/pil/">Python Imaging Library</a>,</item> 
     9<item>if you want to parse broken &html;: <a href="http://www.xmlsoft.org/">libxml2</a> 
    1010(including its Python wrapper),</item> 
    11 <item>if you want want to use the function <function>ll.xist.ns.html.astext</function> 
    12 to convert &html; to plain text: <link href="http://elinks.or.cz/">elinks</link>,</item> 
     11<item>if you want want to use the function <func>ll.xist.ns.html.astext</func> 
     12to convert &html; to plain text: <a href="http://elinks.or.cz/">elinks</a>,</item> 
    1313<item>if you want to install this package as an egg: 
    14 <link href="http://peak.telecommunity.com/DevCenter/setuptools">setuptools</link>.</item> 
    15 <item>if you want to run the test suite: <link href="http://codespeak.net/py/current/doc/test.html">py.test</link>,</item> 
     14<a href="http://peak.telecommunity.com/DevCenter/setuptools">setuptools</a>.</item> 
     15<item>if you want to run the test suite: <a href="http://codespeak.net/py/current/doc/test.html">py.test</a>,</item> 
    1616<item>and a C compiler supported by <app>distutils</app>, if you want 
    1717to install the source distribution.</item> 
    18 </olist> 
     18</ol> 
    1919</section> 
    2020 
    2121 
    22 <section><title>Installation</title> 
    23 <par><app moreinfo="http://peak.telecommunity.com/DevCenter/setuptools">setuptools</app> 
    24 is used for installation so you can install this module with the following command:</par> 
     22<section><h>Installation</h> 
     23<p><app moreinfo="http://peak.telecommunity.com/DevCenter/setuptools">setuptools</app> 
     24is used for installation so you can install this module with the following command:</p> 
    2525 
    2626<prog> 
     
    2828</prog> 
    2929 
    30 <par>If you want to install from source, you can download one of the 
    31 <link href="root:xist/Download.html">distribution archives</link>, unpack it, 
    32 enter the directory and execute the following command:</par> 
     30<p>If you want to install from source, you can download one of the 
     31<a href="root:xist/Download.html">distribution archives</a>, unpack it, 
     32enter the directory and execute the following command:</p> 
    3333<prog> 
    3434python setup.py install 
    3535</prog> 
    3636 
    37 <par>This will copy <filename>*.py</filename> files, compile <filename>*.c</filename> 
     37<p>This will copy <filename>*.py</filename> files, compile <filename>*.c</filename> 
    3838files and install everything in the <dirname>site-packages</dirname> 
    39 directory as the <module>ll.xist</module> package.</par> 
     39directory as the <mod>ll.xist</mod> package.</p> 
    4040 
    41 <par>For Windows a binary distribution is provided. To install it, 
    42 double click it, and follow the instructions.</par> 
     41<p>For Windows a binary distribution is provided. To install it, 
     42double click it, and follow the instructions.</p> 
    4343 
    44 <par>If you have difficulties installing this software, send a problem report 
    45 to Walter Dörwald (<email>walter@livinglogic.de</email>).</par> 
     44<p>If you have difficulties installing this software, send a problem report 
     45to Walter Dörwald (<email>walter@livinglogic.de</email>).</p> 
    4646</section> 
    4747 
    4848 
    49 <section><title>Character encoding</title> 
    50 <par>When you pass an 8bit string in the constructor 
     49<section><h>Character encoding</h> 
     50<p>When you pass an 8bit string in the constructor 
    5151of an &xist; element, these strings have to 
    5252be converted to Unicode. &xist; assumes that these 8bit strings 
    53 are in the system default encoding, which normally is &ascii;.</par> 
     53are in the system default encoding, which normally is &ascii;.</p> 
    5454 
    55 <par>If your strings contain non-&ascii; characters you <em>must</em> 
     55<p>If your strings contain non-&ascii; characters you <em>must</em> 
    5656pass them as unicode strings to the &xist; constructors and you <em>must</em> 
    5757specify the encoding you're using in your source code in the first or second 
    5858line of your script (see 
    59 <link href="http://www.python.org/peps/pep-0263.html">PEP 263</link> for 
    60 a detailed description).</par> 
     59<a href="http://www.python.org/peps/pep-0263.html">PEP 263</a> for 
     60a detailed description).</p> 
    6161</section> 
    6262 
    6363 
    64 <section><title>IPython display hooks</title> 
    65 <par>If you're using &xist; in an 
    66 <link href="http://ipython.scipy.org/">IPython shell</link>, &xist; allows you 
     64<section><h>IPython display hooks</h> 
     65<p>If you're using &xist; in an 
     66<a href="http://ipython.scipy.org/">IPython shell</a>, &xist; allows you 
    6767to browse through your trees using any of the browsers provided by IPython's 
    68 <link href="http://projects.scipy.org/ipython/ipython/wiki/UsingIPipe">ipipe module</link>.</par> 
     68<a href="http://projects.scipy.org/ipython/ipython/wiki/UsingIPipe">ipipe module</a>.</p> 
    6969 
    70 <par>You can specify which format gets used by changing the value of the 
    71 <lit>defaultpresenter</lit> variable in the module <module>ll.xist.presenters</module>:</par> 
     70<p>You can specify which format gets used by changing the value of the 
     71<lit>defaultpresenter</lit> variable in the module <mod>ll.xist.presenters</mod>:</p> 
    7272 
    7373<prog> 
     
    7676</prog> 
    7777 
    78 <par>Setting this value to <lit>None</lit> turns off the display hook.</par> 
     78<p>Setting this value to <lit>None</lit> turns off the display hook.</p> 
    7979 
    8080</section> 
  • MIGRATION.rst

    r3125 r3128  
    5757        def convert(self, converter): 
    5858            return xsc.Text("foo") 
     59 
     60Renamed :mod:`doc` classes 
     61-------------------------- 
     62 
     63Many classes in the :mod:`ll.xist.ns.doc` module have been renamed. The 
     64following names have changed: 
     65 
     66*   ``function`` to ``func``; 
     67*   ``method`` to ``meth``; 
     68*   ``module`` to ``mod``; 
     69*   ``property`` to ``prop``; 
     70*   ``title`` to ``h``; 
     71*   ``par`` to ``p``; 
     72*   ``olist`` to ``ol``; 
     73*   ``ulist`` to ``ul``; 
     74*   ``dlist`` to ``dl``; 
     75*   ``item`` to ``li`` or ``dd`` (depending on whether it's inside a :class:`ol`, 
     76    :class:`ul` or  :class:`dl`); 
     77*   ``term`` to ``dt``; 
     78*   ``link`` to ``a``. 
    5979 
    6080 
  • MIGRATION.xml

    r3119 r3128  
    11<?xml version='1.0' encoding='iso-8859-1'?> 
    2 <section><title>Migrating to version 3.0</title> 
    3  
    4 <section><title>Changes to tree traversal</title> 
    5 <par>You can no longer apply XFind expression directly to nodes, so instead of:</par> 
     2<section><h>Migrating to version 3.0</h> 
     3 
     4<section><h>Changes to tree traversal</h> 
     5<p>You can no longer apply XFind expression directly to nodes, so instead of:</p> 
    66<prog> 
    77for node in root//html.p: 
    88    print node 
    99</prog> 
    10 <par>you have to write:</par> 
     10<p>you have to write:</p> 
    1111<prog> 
    1212for node in root.walknode(html.p): 
    1313    print node 
    1414</prog> 
    15 <par>If you want the search anchored at the root node, you can do the following:</par> 
     15<p>If you want the search anchored at the root node, you can do the following:</p> 
    1616<prog> 
    1717for node in root.walknode(root/html.p): 
    1818    print node 
    1919</prog> 
    20 <par>This will yield <class>html.p</class> elements only if they are immediate 
    21 children of the <lit>root</lit> node.</par> 
    22  
    23 <par>Passing a callable to the <method>walk</method> method now creates a 
     20<p>This will yield <class>html.p</class> elements only if they are immediate 
     21children of the <lit>root</lit> node.</p> 
     22 
     23<p>Passing a callable to the <meth>walk</meth> method now creates a 
    2424<class>ll.xist.xfind.CallableSelector</class>. If you want the old tree traversal 
    25 logic back, you have to put your code into the <method>filterpath</method> method 
    26 of a <class>WalkFilter</class> object.</par> 
    27  
    28 <par>Many of the XFind operators have been renamed (and all have been rewritten). 
    29 See the <module>xfind</module> documentation for more info.</par> 
    30  
    31 </section> 
    32  
    33 <section><title>The death of namespace modules</title> 
    34  
    35 <par>It's no longer possible to turn modules into namespaces. Element classes 
     25logic back, you have to put your code into the <meth>filterpath</meth> method 
     26of a <class>WalkFilter</class> object.</p> 
     27 
     28<p>Many of the XFind operators have been renamed (and all have been rewritten). 
     29See the <mod>xfind</mod> documentation for more info.</p> 
     30 
     31</section> 
     32 
     33<section><h>The death of namespace modules</h> 
     34 
     35<p>It's no longer possible to turn modules into namespaces. Element classes 
    3636belong to a namespace (in the &xml; sense) simpy if their <lit>xmlns</lit> 
    37 attribute have the same value. So a module definition like this:</par> 
     37attribute have the same value. So a module definition like this:</p> 
    3838 
    3939<prog> 
     
    5050</prog> 
    5151 
    52 <par>has to be changed into this:</par> 
     52<p>has to be changed into this:</p> 
    5353 
    5454<prog> 
     
    6464</section> 
    6565 
    66 </section> 
    67  
    68  
    69 <section><title>Migrating to version 2.15</title> 
    70  
    71 <section><title>Changes to plain text conversion</title> 
    72  
    73 <par>The node method <method>asText</method> has been moved to the 
    74 <module>html</module> namespace, so you have to replace:</par> 
     66<section><h>Renamed <mod>doc</mod> classes</h> 
     67 
     68<p>Many classes in the <mod>ll.xist.ns.doc</mod> module have been renamed. 
     69The following names have changed:</p> 
     70 
     71<ul> 
     72<li><lit>function</lit> to <lit>func</lit>;</li> 
     73<li><lit>method</lit> to <lit>meth</lit>;</li> 
     74<li><lit>module</lit> to <lit>mod</lit>;</li> 
     75<li><lit>property</lit> to <lit>prop</lit>;</li> 
     76<li><lit>title</lit> to <lit>h</lit>;</li> 
     77<li><lit>par</lit> to <lit>p</lit>;</li> 
     78<li><lit>olist</lit> to <lit>ol</lit>;</li> 
     79<li><lit>ulist</lit> to <lit>ul</lit>;</li> 
     80<li><lit>dlist</lit> to <lit>dl</lit>;</li> 
     81<li><lit>item</lit> to <lit>li</lit> or </lit>dd</lit> (depending on whether 
     82it's inside a <class>ol</class>, <class>ul</class> or <class>dl</class>);</li> 
     83<li><lit>term</lit> to <lit>dt</lit>;</li> 
     84<li><lit>link</lit> to <lit>a</lit>.</li> 
     85</ul> 
     86 
     87</section> 
     88 
     89 
     90<section><h>Migrating to version 2.15</h> 
     91 
     92<section><h>Changes to plain text conversion</h> 
     93 
     94<p>The node method <meth>asText</meth> has been moved to the 
     95<mod>html</mod> namespace, so you have to replace:</p> 
    7596 
    7697<prog>print node.asText()</prog> 
    7798 
    78 <par>with:</par> 
     99<p>with:</p> 
    79100 
    80101<prog> 
     
    85106</section> 
    86107 
    87 <section><title>Changes to <class>htmlspecials.pixel</class></title> 
    88  
    89 <par>If you've been using the <lit>color</lit> attribute for 
     108<section><h>Changes to <class>htmlspecials.pixel</class></h> 
     109 
     110<p>If you've been using the <lit>color</lit> attribute for 
    90111<class>htmlspecials.pixel</class>, you have to add a <lit>#</lit> in from of 
    91112the value, as it is a &css; color value now. (And if've you've been using 
    92113<lit>color</lit> and a &css; padding of a different color: This will no longer 
    93 work).</par> 
    94  
    95 </section> 
    96  
    97 </section> 
    98  
    99  
    100 <section><title>Migrating to version 2.14</title> 
    101  
    102 <section><title>Changes to presenters</title> 
    103  
    104 <par>Presenters work differently now. Instead of:</par> 
     114work).</p> 
     115 
     116</section> 
     117 
     118</section> 
     119 
     120 
     121<section><h>Migrating to version 2.14</h> 
     122 
     123<section><h>Changes to presenters</h> 
     124 
     125<p>Presenters work differently now. Instead of:</p> 
    105126 
    106127<prog>print node.asrepr(presenters.CodePresenter)</prog> 
    107128 
    108 <par>simply do the following:</par> 
     129<p>simply do the following:</p> 
    109130 
    110131<prog>print presenters.CodePresenter(node)</prog> 
     
    115136 
    116137 
    117 <section><title>Migrating to version 2.13</title> 
    118  
    119 <section><title>Changes to <module>ll.xist.xsc</module></title> 
    120  
    121 <par><method>xsc.Namespace.tokenize</method> no longer has an <arg>encoding</arg> 
     138<section><h>Migrating to version 2.13</h> 
     139 
     140<section><h>Changes to <mod>ll.xist.xsc</mod></h> 
     141 
     142<p><meth>xsc.Namespace.tokenize</meth> no longer has an <arg>encoding</arg> 
    122143argument, but operates on a unicode string directly. You can either use the 
    123 result of a <method>asString</method> call or decode the result of an 
    124 <method>asBytes</method> call yourself.</par> 
    125 </section> 
    126  
    127 </section> 
    128  
    129  
    130 <section><title>Migrating to version 2.11</title> 
    131  
    132 <section><title>Changes to <module>ll.xist.xsc</module></title> 
    133  
    134 <par>The function <function>ToNode</function> has been renamed to 
    135 <function>tonode</function>.</par> 
    136  
    137 <par><class>ll.xist.Context</class> no longer subclasses <class>list</class>. 
     144result of a <meth>asString</meth> call or decode the result of an 
     145<meth>asBytes</meth> call yourself.</p> 
     146</section> 
     147 
     148</section> 
     149 
     150 
     151<section><h>Migrating to version 2.11</h> 
     152 
     153<section><h>Changes to <mod>ll.xist.xsc</mod></h> 
     154 
     155<p>The function <func>ToNode</func> has been renamed to 
     156<func>tonode</func>.</p> 
     157 
     158<p><class>ll.xist.Context</class> no longer subclasses <class>list</class>. 
    138159If you need a stack for your context, simply add the list as an attribute 
    139 of the context object.</par> 
    140  
    141 </section> 
    142  
    143 <section><title>Code rearrangements</title> 
    144  
    145 <par>The iterator stuff from <module>ll.xist.xfind</module> has been moved to 
    146 the <module>ll</module> package/module, i.e. you have to use 
    147 <function>ll.first</function> instead of <function>ll.xist.xfind.first</function>.</par> 
    148  
    149 </section> 
    150  
    151 <section><title>Changes to the <method>walk</method> method</title> 
    152  
    153 <par>The <method>walk</method> method has changed again. There are no inmodes 
     160of the context object.</p> 
     161 
     162</section> 
     163 
     164<section><h>Code rearrangements</h> 
     165 
     166<p>The iterator stuff from <mod>ll.xist.xfind</mod> has been moved to 
     167the <mod>ll</mod> package/module, i.e. you have to use 
     168<func>ll.first</func> instead of <func>ll.xist.xfind.first</func>.</p> 
     169 
     170</section> 
     171 
     172<section><h>Changes to the <meth>walk</meth> method</h> 
     173 
     174<p>The <meth>walk</meth> method has changed again. There are no inmodes 
    154175and outmodes any longer. Instead input and output are <class>Cursor</class> 
    155 objects. If you're using your own <method>walk</method> filters, you have to 
    156 update them. For different output modes you can use the methods <method>walknode</method>, 
    157 <method>walkpath</method> or <method>walkindex</method> instead of using 
    158 the cursor yielded by <method>walk</method>.</par> 
    159  
    160 <par>The node methods <method>find</method> and <method>findfirst</method> 
     176objects. If you're using your own <meth>walk</meth> filters, you have to 
     177update them. For different output modes you can use the methods <meth>walknode</meth>, 
     178<meth>walkpath</meth> or <meth>walkindex</meth> instead of using 
     179the cursor yielded by <meth>walk</meth>.</p> 
     180 
     181<p>The node methods <meth>find</meth> and <meth>findfirst</meth> 
    161182have been removed. Use <lit>xsc.Frag(node.walk(<rep>...</rep>)</lit> or 
    162 <lit>node.walk(<rep>...</rep>)[0]</lit> instead.</par> 
    163  
    164 </section> 
    165  
    166 <section><title>Changes to publishing</title> 
    167  
    168 <par>Publishing has changed: If you've used the method <method>repr</method> 
     183<lit>node.walk(<rep>...</rep>)[0]</lit> instead.</p> 
     184 
     185</section> 
     186 
     187<section><h>Changes to publishing</h> 
     188 
     189<p>Publishing has changed: If you've used the method <meth>repr</meth> 
    169190before to get a string representation of an &xml; tree, you have to use 
    170 <method>asrepr</method> instead now (<method>repr</method> is a generator 
    171 which will produce the string in pieces).</par> 
    172  
    173 </section> 
    174  
    175 <section><title>Changes to the <module>xfind</module> module</title> 
    176  
    177 <par>The functions <function>item</function>, <function>first</function>, 
    178 <function>last</function>, <function>count</function> and 
    179 <function>iterone</function> as well as the class <class>Iterator</class> 
    180 have been moved to the <module>ll</module> module.</par> 
    181  
    182 </section> 
    183  
    184 </section> 
    185  
    186  
    187 <section><title>Migrating to version 2.10</title> 
    188  
    189 <section><title>Changes to publishing</title> 
    190 <par>Publishing has been changed from using a stream &api; to using a 
    191 iterator &api;. If you've been using <method>Publisher.write</method> or 
    192 <method>Publisher.writetext</method> (in your own <method>publish</method> 
     191<meth>asrepr</meth> instead now (<meth>repr</meth> is a generator 
     192which will produce the string in pieces).</p> 
     193 
     194</section> 
     195 
     196<section><h>Changes to the <mod>xfind</mod> module</h> 
     197 
     198<p>The functions <func>item</func>, <func>first</func>, 
     199<func>last</func>, <func>count</func> and 
     200<func>iterone</func> as well as the class <class>Iterator</class> 
     201have been moved to the <mod>ll</mod> module.</p> 
     202 
     203</section> 
     204 
     205</section> 
     206 
     207 
     208<section><h>Migrating to version 2.10</h> 
     209 
     210<section><h>Changes to publishing</h> 
     211<p>Publishing has been changed from using a stream &api; to using a 
     212iterator &api;. If you've been using <meth>Publisher.write</meth> or 
     213<meth>Publisher.writetext</meth> (in your own <meth>publish</meth> 
    193214methods) you must update your code by replacing <lit>publisher.write(<rep>foo</rep>)</lit> 
    194215with <lit>yield publisher.encode(<rep>foo</rep>)</lit> and 
    195216<lit>publisher.writetext(<rep>foo</rep>)</lit> with 
    196 <lit>yield publisher.encodetext(<rep>foo</rep>)</lit>.</par> 
    197 </section> 
    198  
    199 <section><title>Changes to the test suite</title> 
    200 <par>The test suite now uses <link href="http://codespeak.net/py/current/doc/test.html">py.test</link>, 
    201 so if you want to run it you'll need py.test.</par> 
    202 </section> 
    203  
    204 <section><title>Changes to <module>ll.xist.ns.code</module></title> 
    205 <par>The code in a <class>ll.xist.ns.code.pyexec</class> object is no longer 
     217<lit>yield publisher.encodetext(<rep>foo</rep>)</lit>.</p> 
     218</section> 
     219 
     220<section><h>Changes to the test suite</h> 
     221<p>The test suite now uses <a href="http://codespeak.net/py/current/doc/test.html">py.test</a>, 
     222so if you want to run it you'll need py.test.</p> 
     223</section> 
     224 
     225<section><h>Changes to <mod>ll.xist.ns.code</mod></h> 
     226<p>The code in a <class>ll.xist.ns.code.pyexec</class> object is no longer 
    206227executed at construction time, but at conversion time. So if you relied on 
    207228this fact (e.g. to make a namespace available for parsing the rest of the 
    208 &xml; file) you will have to change your code.</par> 
    209 </section> 
    210  
    211 <section><title>Removed namespaces</title> 
    212 <par>The namespace modules <module>ll.xist.ns.css</module> and 
    213 <module>ll.xist.ns.cssspecials</module> have been removed.</par> 
    214 </section> 
    215  
    216 </section> 
    217  
    218  
    219 <section><title>Migrating to version 2.9</title> 
    220  
    221 <section><title>Changes to exceptions</title> 
    222 <par>All exception classes have been moved from <module>ll.xist.errors</module> 
    223 to <module>ll.xist.xsc</module>.</par> 
    224 </section> 
    225  
    226 <section><title>Changes to &xml; name handling</title> 
    227 <par>The class attribute <lit>xmlname</lit> no longer gets replaced with a tuple 
     229&xml; file) you will have to change your code.</p> 
     230</section> 
     231 
     232<section><h>Removed namespaces</h> 
     233<p>The namespace modules <mod>ll.xist.ns.css</mod> and 
     234<mod>ll.xist.ns.cssspecials</mod> have been removed.</p> 
     235</section> 
     236 
     237</section> 
     238 
     239 
     240<section><h>Migrating to version 2.9</h> 
     241 
     242<section><h>Changes to exceptions</h> 
     243<p>All exception classes have been moved from <mod>ll.xist.errors</mod> 
     244to <mod>ll.xist.xsc</mod>.</p> 
     245</section> 
     246 
     247<section><h>Changes to &xml; name handling</h> 
     248<p>The class attribute <lit>xmlname</lit> no longer gets replaced with a tuple 
    228249containing both the Python and the &xml; name. If you want to get the Python name, 
    229 use <lit><rep>foo</rep>.__class__.__name__</lit>.</par> 
    230 </section> 
    231  
    232 <section><title>Changes to the methods <method>walk</method>, <method>find</method> and <method>findfirst</method></title> 
    233 <par>The argument <arg>filtermode</arg> has been renamed to <arg>inmode</arg> 
    234 and (for <method>walk</method>) <arg>walkmode</arg> has been renamed to <arg>outmode</arg>.</par> 
    235 </section> 
    236  
    237 </section> 
    238  
    239  
    240 <section><title>Migrating to version 2.8</title> 
    241  
    242 <section><title>Changes to display hooks</title> 
    243 <par>The way &xist; uses <function>sys.displayhook</function> has been 
     250use <lit><rep>foo</rep>.__class__.__name__</lit>.</p> 
     251</section> 
     252 
     253<section><h>Changes to the methods <meth>walk</meth>, <meth>find</meth> and <meth>findfirst</meth></h> 
     254<p>The argument <arg>filtermode</arg> has been renamed to <arg>inmode</arg> 
     255and (for <meth>walk</meth>) <arg>walkmode</arg> has been renamed to <arg>outmode</arg>.</p> 
     256</section> 
     257 
     258</section> 
     259 
     260 
     261<section><h>Migrating to version 2.8</h> 
     262 
     263<section><h>Changes to display hooks</h> 
     264<p>The way &xist; uses <func>sys.displayhook</func> has been 
    244265enhanced. To make use of this, you might want to update your Python 
    245266startup script. For more info see the 
    246 <link href="root:xist/Installation.html">installation instructions</link>.</par> 
    247 </section> 
    248  
    249 <section><title>Changes to the <lit>xmlns</lit> attribute</title> 
    250 <par>Each element (or entity, or processing instruction) class had an attribute 
     267<a href="root:xist/Installation.html">installation instructions</a>.</p> 
     268</section> 
     269 
     270<section><h>Changes to the <lit>xmlns</lit> attribute</h> 
     271<p>Each element (or entity, or processing instruction) class had an attribute 
    251272<lit>xmlns</lit> that references the namespace module. This attribute has been 
    252 renamed to <lit>__ns__</lit>.</par> 
    253 </section> 
    254  
    255 <section><title>Other minor changes</title> 
    256 <par><class>ll.xist.ns.specials.x</class> has been renamed to 
    257 <class>ll.xist.ns.specials.ignore</class>.</par> 
    258 <par><class>ll.xist.xfind.item</class> no longer handles slices. 
     273renamed to <lit>__ns__</lit>.</p> 
     274</section> 
     275 
     276<section><h>Other minor changes</h> 
     277<p><class>ll.xist.ns.specials.x</class> has been renamed to 
     278<class>ll.xist.ns.specials.ignore</class>.</p> 
     279<p><class>ll.xist.xfind.item</class> no longer handles slices. 
    259280If you've used that functionality, you may now use slices 
    260281on XFind operators, and materilize the result, i.e. replace 
    261282<lit>xfind.slice(<rep>foo</rep>, 1, -1)</lit> 
    262283with <lit>list(<rep>foo</rep>[1:-1])</lit>, if <lit><rep>foo</rep></lit> is 
    263 an XFind operator. Otherwise you can use <lit>list(<rep>foo</rep>)[1:-1]</lit>.</par> 
    264 </section> 
    265  
    266 </section> 
    267  
    268  
    269 <section><title>Migrating to version 2.7</title> 
    270  
    271 <section><title>Changes to <module>ll.xist.xfind</module></title> 
    272 <par>The functions <function>xfind.first</function> and 
    273 <function>xfind.last</function> now use <function>xfind.item</function>, so 
     284an XFind operator. Otherwise you can use <lit>list(<rep>foo</rep>)[1:-1]</lit>.</p> 
     285</section> 
     286 
     287</section> 
     288 
     289 
     290<section><h>Migrating to version 2.7</h> 
     291 
     292<section><h>Changes to <mod>ll.xist.xfind</mod></h> 
     293<p>The functions <func>xfind.first</func> and 
     294<func>xfind.last</func> now use <func>xfind.item</func>, so 
    274295they will raise an <class>IndexError</class> when no default value is passed. 
    275 To get the old behaviour, simply pass <lit>None</lit> as the default.</par> 
    276 </section> 
    277  
    278 </section> 
    279  
    280  
    281 <section><title>Migrating to version 2.6</title> 
    282  
    283 <section><title>Changes to the publishing &api;</title> 
    284 <par>The top level publishing method in the publisher has been 
    285 renamed from <method>dopublication</method> to <method>publish</method>. 
     296To get the old behaviour, simply pass <lit>None</lit> as the default.</p> 
     297</section> 
     298 
     299</section> 
     300 
     301 
     302<section><h>Migrating to version 2.6</h> 
     303 
     304<section><h>Changes to the publishing &api;</h> 
     305<p>The top level publishing method in the publisher has been 
     306renamed from <meth>dopublication</meth> to <meth>publish</meth>. 
    286307If you're using the publishing &api; directly (instead of the node methods 
    287 <method>asBytes</method> and <method>write</method>), you'll have to 
    288 update your code.</par> 
    289 <par>The method that writes a unicode object to the output stream has 
    290 been renamed from <method>publish</method> to <method>write</method>. 
    291 This is only relevant when you've overwritten the <method>publish</method> 
     308<meth>asBytes</meth> and <meth>write</meth>), you'll have to 
     309update your code.</p> 
     310<p>The method that writes a unicode object to the output stream has 
     311been renamed from <meth>publish</meth> to <meth>write</meth>. 
     312This is only relevant when you've overwritten the <meth>publish</meth> 
    292313method in your own node class (e.g. in &jsp; tag library directives 
    293 or similar stuff, or for special nodes that publish some text literally).</par> 
    294 </section> 
    295  
    296 <section><title>Changes to the presentation &api;</title> 
    297 <par>The presentation &api; has been changed too: The top level presentation 
    298 method in the presenter has been renamed from <method>dopresentation</method> to 
    299 <method>present</method>. This is only relevant if you've written your own 
     314or similar stuff, or for special nodes that publish some text literally).</p> 
     315</section> 
     316 
     317<section><h>Changes to the presentation &api;</h> 
     318<p>The presentation &api; has been changed too: The top level presentation 
     319method in the presenter has been renamed from <meth>dopresentation</meth> to 
     320<meth>present</meth>. This is only relevant if you've written your own 
    300321presenter, or are using the presentation &api; directly (instead of the node 
    301 method <method>repr</method>).</par> 
    302 </section> 
    303  
    304 <section><title>Parsing &html;</title> 
    305 <par>Parsing &html; is now done via libxml2's &html; parser, instead of using 
     322method <meth>repr</meth>).</p> 
     323</section> 
     324 
     325<section><h>Parsing &html;</h> 
     326<p>Parsing &html; is now done via libxml2's &html; parser, instead of using 
    306327µTidyLib of mxTidy. You can no longer pass arguments to tidy. Only the boolean 
    307328values of the <arg>tidy</arg> argument will be used. There are no other visible 
    308 changes to the &api; but the result of parsing might have changed.</par> 
    309 </section> 
    310  
    311 <section><title>Removed &api;s and scripts</title> 
    312 <par>The script <filename>xscmake.py</filename> has been removed.</par> 
    313  
    314 <par>The <method>visit</method> method has been removed.</par> 
    315  
    316 <par><method>ll.xist.xsc.FindOld</method> has been removed.</par> 
    317  
    318 <par><class>ll.xist.ns.xml.header</class> has been renamed to 
    319 <class>ll.xist.ns.xml.declaration</class>.</par> 
    320  
    321 </section> 
    322  
    323 </section> 
    324  
    325  
    326 <section><title>Migrating to version 2.5</title> 
    327  
    328 <section><title>Changes to content model</title> 
    329 <par>The boolean class attribute <lit>empty</lit> for element classes has been 
     329changes to the &api; but the result of parsing might have changed.</p> 
     330</section> 
     331 
     332<section><h>Removed &api;s and scripts</h> 
     333<p>The script <filename>xscmake.py</filename> has been removed.</p> 
     334 
     335<p>The <meth>visit</meth> method has been removed.</p> 
     336 
     337<p><meth>ll.xist.xsc.FindOld</meth> has been removed.</p> 
     338 
     339<p><class>ll.xist.ns.xml.header</class> has been renamed to 
     340<class>ll.xist.ns.xml.declaration</class>.</p> 
     341 
     342</section> 
     343 
     344</section> 
     345 
     346 
     347<section><h>Migrating to version 2.5</h> 
     348 
     349<section><h>Changes to content model</h> 
     350<p>The boolean class attribute <lit>empty</lit> for element classes has been 
    330351replaced by an object <lit>model</lit>. <lit>empty</lit> is still supported, 
    331352but issues a <class>PendingDeprecationWarning</class>. If you don't want to specify 
     
    333354with <lit>model = True</lit> (which is a shortcut for <lit>model = sims.Any()</lit>) 
    334355and <lit>empty = True</lit> with <lit>model = False</lit> (which is a shortcut 
    335 for <lit>model = sims.Empty()</lit>).</par> 
    336 </section> 
    337  
    338 </section> 
    339  
    340  
    341 <section><title>Migrating to version 2.4</title> 
    342  
    343 <section><title>Changes to parsing</title> 
    344 <par>Parsing has changed internally, but the module level parsing functions in 
    345 <module>ll.xist.parsers</module> are still available (and will create a parser 
    346 on the fly), but a few arguments have changed:</par> 
    347 <dlist> 
     356for <lit>model = sims.Empty()</lit>).</p> 
     357</section> 
     358 
     359</section> 
     360 
     361 
     362<section><h>Migrating to version 2.4</h> 
     363 
     364<section><h>Changes to parsing</h> 
     365<p>Parsing has changed internally, but the module level parsing functions in 
     366<mod>ll.xist.parsers</mod> are still available (and will create a parser 
     367on the fly), but a few arguments have changed:</p> 
     368<dl> 
    348369<term><arg>handler</arg></term><item>This argument is no longer available, if you 
    349370need a special handler, you have to subclass <class>ll.xist.parsers.Parser</class> 
     
    353374but a callable that will create a &sax;2 parser.</item> 
    354375<term><arg>sysid</arg></term><item><arg>sysid</arg> is now available for all 
    355 parsing functions not just <function>parseString</function>.</item> 
    356 </dlist> 
    357 </section> 
    358  
    359 <section><title>Changes to converter contexts</title> 
    360 <par><method>ll.xist.converters.Converter.__getitem__</method> now doesn't use 
     376parsing functions not just <func>parseString</func>.</item> 
     377</dl> 
     378</section> 
     379 
     380<section><h>Changes to converter contexts</h> 
     381<p><meth>ll.xist.converters.Converter.__getitem__</meth> now doesn't use 
    361382the key passed in, but <lit><rep>key</rep>.Context</lit> as the real dictionary 
    362 key. This has the following consequences:</par> 
    363 <ulist> 
    364 <item><par>If you want a unique context for your own element class, 
     383key. This has the following consequences:</p> 
     384<ul> 
     385<item><p>If you want a unique context for your own element class, 
    365386you <em>must</em> implement a new <class>Context</class> class (otherwise you'd 
    366 get <class>ll.xist.xsc.Element.Context</class>):</par> 
     387get <class>ll.xist.xsc.Element.Context</class>):</p> 
    367388<example> 
    368389<prog> 
     
    378399</item> 
    379400<item>Subclasses that don't overwrite <class>Context</class> (as well as instances 
    380 of those classes) can be passed to <method>ll.xist.converters.Converter.__getitem__</method> 
     401of those classes) can be passed to <meth>ll.xist.converters.Converter.__getitem__</meth> 
    381402and the unique base class context object will be returned.</item> 
    382 </ulist> 
    383 </section> 
    384  
    385 <section><title>Changed namespaces</title> 
    386 <par>The character reference classes from <module>ll.xist.ns.ihtml</module> 
    387 that are duplicates of those in <module>ll.xist.ns.chars</module> have been removed, so you 
    388 have to use <module>ll.xist.ns.chars</module> for those characters in addition to 
    389 <module>ll.xist.ns.ihtml</module> 
    390 </par> 
    391 </section> 
    392  
    393 </section> 
    394  
    395  
    396 <section><title>Migrating to version 2.3</title> 
    397  
    398 <section><title>Changes in namespace handling</title> 
    399 <par>Namespace handling has changed. There are no entity or processing instruction 
     403</ul> 
     404</section> 
     405 
     406<section><h>Changed namespaces</h> 
     407<p>The character reference classes from <mod>ll.xist.ns.ihtml</mod> 
     408that are duplicates of those in <mod>ll.xist.ns.chars</mod> have been removed, so you 
     409have to use <mod>ll.xist.ns.chars</mod> for those characters in addition to 
     410<mod>ll.xist.ns.ihtml</mod> 
     411</p> 
     412</section> 
     413 
     414</section> 
     415 
     416 
     417<section><h>Migrating to version 2.3</h> 
     418 
     419<section><h>Changes in namespace handling</h> 
     420<p>Namespace handling has changed. There are no entity or processing instruction 
    400421prefixes any longer and creating a proper <class>Prefixes</class> object has 
    401 been simplified. For example:</par> 
     422been simplified. For example:</p> 
    402423<prog> 
    403424prefixes = xsc.Prefixes() 
     
    405426prefixes.addElementPrefixMapping("svg", svg) 
    406427</prog> 
    407 <par>can be simplified to:</par> 
     428<p>can be simplified to:</p> 
    408429<prog> 
    409430prefixes = xsc.Prefixes(html, svg=svg) 
    410431</prog> 
    411 <par>The three arguments <arg>elementmode</arg>, <arg>entitymode</arg> and 
     432<p>The three arguments <arg>elementmode</arg>, <arg>entitymode</arg> and 
    412433<arg>procinstmode</arg> for the publishing methods have been combined into 
    413 <arg>prefixmode</arg>, which is used for elements only.</par> 
    414 </section> 
    415  
    416 <section><title>Changed namespaces</title> 
    417 <par>The character reference classes from <module>ll.xist.ns.html</module> 
    418 have been moved to a separate namespace <module>ll.xist.ns.chars</module>.</par> 
    419 <par>The processing instructions <class>eval_</class> and <class>exec_</class> 
    420 from the <module>ll.xist.ns.code</module> module have been renamed to 
    421 <class>pyeval</class> and <class>pyexec</class>.</par> 
    422 </section> 
    423  
    424 <section><title>Changed method names</title> 
    425 <par>The method names <method>beginPublication</method>, <method>endPublication</method> 
    426 and <method>doPublication</method> have been lowercased.</par> 
    427 </section> 
    428 </section> 
    429  
    430  
    431 <section><title>Migrating to version 2.2</title> 
    432  
    433 <section><title>Attribute methods</title> 
    434  
    435 <par>The <class>Element</class> methods for accessing attributes 
     434<arg>prefixmode</arg>, which is used for elements only.</p> 
     435</section> 
     436 
     437<section><h>Changed namespaces</h> 
     438<p>The character reference classes from <mod>ll.xist.ns.html</mod> 
     439have been moved to a separate namespace <mod>ll.xist.ns.chars</mod>.</p> 
     440<p>The processing instructions <class>eval_</class> and <class>exec_</class> 
     441from the <mod>ll.xist.ns.code</mod> module have been renamed to 
     442<class>pyeval</class> and <class>pyexec</class>.</p> 
     443</section> 
     444 
     445<section><h>Changed method names</h> 
     446<p>The method names <meth>beginPublication</meth>, <meth>endPublication</meth> 
     447and <meth>doPublication</meth> have been lowercased.</p> 
     448</section> 
     449</section> 
     450 
     451 
     452<section><h>Migrating to version 2.2</h> 
     453 
     454<section><h>Attribute methods</h> 
     455 
     456<p>The <class>Element</class> methods for accessing attributes 
    436457have been deprecated. So instead of <lit><rep>node</rep>.hasattr("<rep>attr</rep>")</lit>, 
    437 you should use:</par> 
     458you should use:</p> 
    438459 
    439460<prog> 
     
    441462</prog> 
    442463 
    443 <par>The same holds for checking whether an attribute is allowed. You can use the following code:</par> 
     464<p>The same holds for checking whether an attribute is allowed. You can use the following code:</p> 
    444465 
    445466<prog> 
     
    447468</prog> 
    448469 
    449 <par>or:</par> 
     470<p>or:</p> 
    450471 
    451472<prog> 
     
    453474</prog> 
    454475 
    455 <par>or:</par> 
     476<p>or:</p> 
    456477 
    457478<prog> 
     
    459480</prog> 
    460481 
    461 <par>Many <class>Attrs</class> methods have gained an additional parameter 
     482<p>Many <class>Attrs</class> methods have gained an additional parameter 
    462483<arg>xml</arg>, which specifies whether an attribute name should be 
    463484treated as the &xml; or the Python name of the attribute. Make sure 
    464485that you're not mixing up your arguments in the function call. The 
    465 safest method for this is using keyword arguments, e.g.:</par> 
     486safest method for this is using keyword arguments, e.g.:</p> 
    466487 
    467488<prog> 
     
    471492</section> 
    472493 
    473 <section><title>JSP directive page element</title> 
    474  
    475 <par>A <lit>contentType</lit> attribute is no longer generated for the 
     494<section><h>JSP directive page element</h> 
     495 
     496<p>A <lit>contentType</lit> attribute is no longer generated for the 
    476497<class>ll.xist.ns.jsp.directive_page</class>. You have to explicitely use an attribute 
    477498<lit>contentType="<rep>text/html</rep>"</lit> to get a <lit>contentType</lit> attribute 
    478499in the resulting &jsp;. The <lit>charset</lit> option is generated automatically 
    479 from the encoding specified in the publisher.</par> 
    480  
    481 </section> 
    482  
    483 <section><title><class>autoimg</class> changes</title> 
    484  
    485 <par><class>ll.xist.htmlspecials.autoimg</class> will no longer touches existing <lit>width</lit> 
     500from the encoding specified in the publisher.</p> 
     501 
     502</section> 
     503 
     504<section><h><class>autoimg</class> changes</h> 
     505 
     506<p><class>ll.xist.htmlspecials.autoimg</class> will no longer touches existing <lit>width</lit> 
    486507or <lit>height</lit> attributes, so e.g. setting the width to twice the image size via 
    487508<lit>width="2*%(width)s"</lit> no longer works. You have to implement your own 
    488 version of <class>autoimg</class> if you need this.</par> 
    489  
    490 </section> 
    491  
    492 <section><title><method>find</method> changes</title> 
    493  
    494 <par><method>find</method> has been completely rewritten to use the new tree traversal filters. 
     509version of <class>autoimg</class> if you need this.</p> 
     510 
     511</section> 
     512 
     513<section><h><meth>find</meth> changes</h> 
     514 
     515<p><meth>find</meth> has been completely rewritten to use the new tree traversal filters. 
    495516For backwards compatibility a filter functor <class>ll.xist.xsc.FindOld</class> exists that 
    496 takes the same arguments as the old <method>find</method> method. I.e. you can replace:</par> 
     517takes the same arguments as the old <meth>find</meth> method. I.e. you can replace:</p> 
    497518<prog> 
    498519node.find( 
     
    502523) 
    503524</prog> 
    504 <par>with:</par> 
     525<p>with:</p> 
    505526<prog> 
    506527node.find( 
     
    513534) 
    514535</prog> 
    515 <par>But one minor difference remains: when <arg>skiproot</arg> is set to true in the new 
    516 <method>find</method> method, the attributes of the root element will <em>not</em> be traversed. 
    517 With the old method they would be traversed.</par> 
    518  
    519 </section> 
    520  
    521 <section><title><class>doc</class> changes</title> 
    522  
    523 <par><class>programlisting</class> has been renamed to <class>prog</class>.</par> 
    524  
    525 </section> 
    526  
    527 <section><title>Namespace changes</title> 
    528  
    529 <par>Namespaces can no longer be instantiated. Instead you have to derive a class 
     536<p>But one minor difference remains: when <arg>skiproot</arg> is set to true in the new 
     537<meth>find</meth> method, the attributes of the root element will <em>not</em> be traversed. 
     538With the old method they would be traversed.</p> 
     539 
     540</section> 
     541 
     542<section><h><class>doc</class> changes</h> 
     543 
     544<p><class>programlisting</class> has been renamed to <class>prog</class>.</p> 
     545 
     546</section> 
     547 
     548<section><h>Namespace changes</h> 
     549 
     550<p>Namespaces can no longer be instantiated. Instead you have to derive a class 
    530551from <class>Namespace</class>. The <arg>xmlprefix</arg> argument from the constructor 
    531552becomes a class attribute <lit>xmlname</lit> and the argument <arg>xmlname</arg> 
    532 becomes <lit>xmlurl</lit>.</par> 
    533  
    534 <par>Adding element classes to the namespace is now done with the 
    535 <class>Namespace</class> classmethod <method>update</method>. 
     553becomes <lit>xmlurl</lit>.</p> 
     554 
     555<p>Adding element classes to the namespace is now done with the 
     556<class>Namespace</class> classmethod <meth>update</meth>. 
    536557If you want the turn a namespace into a module, you can use the classmethod 
    537 <method>makemod</method> instead of <method>update</method>.</par> 
    538  
    539 <example><title>Old method</title> 
     558<meth>makemod</meth> instead of <meth>update</meth>.</p> 
     559 
     560<example><h>Old method</h> 
    540561<prog> 
    541562xmlns = xsc.Namespace("foo", "http://www.foo.com/", vars() 
     
    543564</example> 
    544565 
    545 <example><title>New method</title> 
     566<example><h>New method</h> 
    546567<prog> 
    547568class xmlns(xsc.Namespace): 
     
    557578 
    558579 
    559 <section><title>Migrating to version 2.1</title> 
    560  
    561 <ulist> 
    562 <item>The method <method>withSep</method> has been renamed 
    563 to <method>withsep</method>.</item> 
     580<section><h>Migrating to version 2.1</h> 
     581 
     582<ul> 
     583<item>The method <meth>withSep</meth> has been renamed 
     584to <meth>withsep</meth>.</item> 
    564585 
    565586<item>The argument <arg>defaultEncoding</arg> for the various 
    566587parsing functions has been renamed to <arg>encoding</arg>.</item> 
    567 </ulist> 
    568  
    569 </section> 
    570  
    571  
    572 <section><title>Migrating to version 2.0</title> 
    573  
    574 <section><title>Attribute handling</title> 
    575  
    576 <par>The biggest change is in the way attributes are defined. In older 
     588</ul> 
     589 
     590</section> 
     591 
     592 
     593<section><h>Migrating to version 2.0</h> 
     594 
     595<section><h>Attribute handling</h> 
     596 
     597<p>The biggest change is in the way attributes are defined. In older 
    577598versions you had to define a class attribute <lit>attrHandlers</lit> 
    578599that mapped attribute names to attribute classes. This created problems 
     
    580601in &html;), so for them an ugly workaround was implemented. With 2.0 
    581602this is no longer neccessary. Defining attributes is done via a 
    582 class <class>Attrs</class> nested inside the element class like this:</par> 
     603class <class>Attrs</class> nested inside the element class like this:</p> 
    583604 
    584605<example> 
     
    596617</example> 
    597618 
    598 <par>Default values, set of allowed attributes values and 
     619<p>Default values, set of allowed attributes values and 
    599620whether the attribute is required can be defined via 
    600621class attributes as shown above. You should (directly 
     
    604625base class), you can derive from the appropriate 
    605626<class>Attrs</class> class. Removing an attribute you inherited 
    606 can be done like this:</par> 
     627can be done like this:</p> 
    607628 
    608629<example> 
     
    614635</example> 
    615636 
    616 <par>This removes the attribute <lit>baz</lit> inherited 
    617 from <class>foo</class>.</par> 
    618  
    619 <par>For attribute names that are no legal Python identifiers, 
     637<p>This removes the attribute <lit>baz</lit> inherited 
     638from <class>foo</class>.</p> 
     639 
     640<p>For attribute names that are no legal Python identifiers, 
    620641the same method can be used as for element classes: Define 
    621642the real &xml; name via a class attribute. This class attribute 
    622 has been renamed from <lit>name</lit> to <lit>xmlname</lit>.</par> 
    623  
    624 <par>This also means that you always have to use the Python 
     643has been renamed from <lit>name</lit> to <lit>xmlname</lit>.</p> 
     644 
     645<p>This also means that you always have to use the Python 
    625646name when using attributes now. The &xml; name will only 
    626 be used for parsing and publishing.</par> 
    627  
    628 <par>&xist; 2.0 tries to be as backwards compatible as 
     647be used for parsing and publishing.</p> 
     648 
     649<p>&xist; 2.0 tries to be as backwards compatible as 
    629650possible: An existing <lit>attrHandlers</lit> attribute 
    630651will be converted to an <class>Attrs</class> class on the 
     
    635656The only situation where this won't work, is with 
    636657attributes where the Python and &xml; name differ, you 
    637 have to use <z>new style</z> attributes there.</par> 
    638 </section> 
    639  
    640 <section><title>Namespace support</title> 
    641  
    642 <par>&xist; supports &xml; namespaces now and for parsing it's 
     658have to use <z>new style</z> attributes there.</p> 
     659</section> 
     660 
     661<section><h>Namespace support</h> 
     662 
     663<p>&xist; supports &xml; namespaces now and for parsing it's 
    643664possible to configure which namespaces should be available 
    644665for instantiating classes from. For more info about this 
    645 refer to the documentation for the class <pyref module="ll.xist.xsc" class="Prefixes"><class>Prefixes</class></pyref>.</par> 
    646  
    647 <par>Before 2.0 the &xml; name for a namespace object 
     666refer to the documentation for the class <pyref module="ll.xist.xsc" class="Prefixes"><class>Prefixes</class></pyref>.</p> 
     667 
     668<p>Before 2.0 the &xml; name for a namespace object 
    648669was pretty useless, now it can be used as the namespace 
    649670name in <lit>xmlns</lit> attributes and it will be used 
    650671for that when publishing and specifying an <lit>elementmode</lit> 
    651672of <lit>2</lit> in the call to the publishing method or the constructor 
    652 of the publisher.</par> 
    653  
    654 <par>Namespace objects should now be named <lit>xmlns</lit> 
    655 instead of <lit>namespace</lit> as before.</par> 
    656  
    657 </section> 
    658  
    659 <section><title>Global attributes</title> 
    660  
    661 <par>Global attributes are supported now, e.g. the attributes 
     673of the publisher.</p> 
     674 
     675<p>Namespace objects should now be named <lit>xmlns</lit> 
     676instead of <lit>namespace</lit> as before.</p> 
     677 
     678</section> 
     679 
     680<section><h>Global attributes</h> 
     681 
     682<p>Global attributes are supported now, e.g. the attributes 
    662683<lit>xml:lang</lit> and <lit>xml:space</lit> can be specified 
    663 in an element constructor like this:</par> 
     684in an element constructor like this:</p> 
    664685 
    665686<example> 
     
    676697</example> 
    677698 
    678 <par>Instead of the module object (which must contain a 
     699<p>Instead of the module object (which must contain a 
    679700namespace object named <lit>xmlns</lit>), you can also 
    680701pass the namespace object itself (i.e. <lit>xml.xmlns</lit>) 
    681 or the namespace name (i.e. <lit>"http://www.w3.org/XML/1998/namespace"</lit>).</par> 
    682  
    683 </section> 
    684  
    685 <section><title>Namespace changes</title> 
    686  
    687 <par>The classes <class>XML</class> and <class>XML10</class> 
    688 have been moved from <module>ll.xist.xsc</module> to 
    689 <module>ll.xist.ns.xml</module>.</par> 
    690  
    691 <par>All the classes in <module>ll.xist.ns.specials</module> 
     702or the namespace name (i.e. <lit>"http://www.w3.org/XML/1998/namespace"</lit>).</p> 
     703 
     704</section> 
     705 
     706<section><h>Namespace changes</h> 
     707 
     708<p>The classes <class>XML</class> and <class>XML10</class> 
     709have been moved from <mod>ll.xist.xsc</mod> to 
     710<mod>ll.xist.ns.xml</mod>.</p> 
     711 
     712<p>All the classes in <mod>ll.xist.ns.specials</mod> 
    692713that are specific to &html; generation have been moved 
    693 to the new module <module>ll.xist.ns.htmlspecials</module>.</par> 
    694  
    695 <par>The module <module>ll.xist.ns.html</module> has been updated 
     714to the new module <mod>ll.xist.ns.htmlspecials</mod>.</p> 
     715 
     716<p>The module <mod>ll.xist.ns.html</mod> has been updated 
    696717to the &xhtml; specification, so there might be some changes. 
    697718The new feature for specifying attribute restrictions has 
     
    699720attributes in <class>img</class> elements. These warnings 
    700721are issued via the warning framework. Refer to the documentation 
    701 for the <module>warnings</module> module to find out how to 
    702 configure the handling of these warnings.</par> 
    703  
    704 </section> 
    705  
    706 <section><title>Miscellaneous</title> 
    707  
    708 <par>&xist; now requires at least Python 2.2.1 because 
     722for the <mod>warnings</mod> module to find out how to 
     723configure the handling of these warnings.</p> 
     724 
     725</section> 
     726 
     727<section><h>Miscellaneous</h> 
     728 
     729<p>&xist; now requires at least Python 2.2.1 because 
    709730the integer constants <lit>True</lit> and <lit>False</lit> 
    710731are used throughout the code wherever appropriate. These 
     
    712733in Python 2.3. You might want to change your code too, to 
    713734use these new constant (e.g. when setting the element 
    714 class attribute <lit>empty</lit>).</par> 
    715  
    716 <par>Using mixed case method names was a bad idea, because 
     735class attribute <lit>empty</lit>).</p> 
     736 
     737<p>Using mixed case method names was a bad idea, because 
    717738this conflicts with Python's convention of using 
    718739all lowercase names (without underscores). These method 
    719740names will be fixed in the next few &xist; versions. 
    720741The first names that where changed were the element methods 
    721 <method>getAttr</method> and <method>hasAttr</method>, which 
    722 have been renamed to <method>getattr</method> and 
    723 <method>hasattr</method> respectively. <method>getAttr</method> 
    724 and <method>hasAttr</method> are still there and can be called 
     742<meth>getAttr</meth> and <meth>hasAttr</meth>, which 
     743have been renamed to <meth>getattr</meth> and 
     744<meth>hasattr</meth> respectively. <meth>getAttr</meth> 
     745and <meth>hasAttr</meth> are still there and can be called 
    725746without generating <class>DeprecationWarning</class>s, but they 
    726 will start to generate warnings in the upcoming versions.</par> 
    727  
    728 </section> 
     747will start to generate warnings in the upcoming versions.</p> 
     748 
     749</section> 
  • NEWS.rst

    r3110 r3128  
    7272 
    7373    __ http://docutils.sourceforge.net/rst.html 
     74 
     75*   Many classes in the :mod:`ll.xist.ns.doc` have been renamed to more familiar 
     76    names (from HTML, XHTML 2 or ReST). 
    7477 
    7578*   The ``media`` attribute of :class:`html.link` and :class:`html.style` now has 
  • NEWS.xml

    r3110 r3128  
    11<?xml version='1.0' encoding='iso-8859-1'?> 
    2 <section><title>Changes in 3.0 (released ??/??/2007)</title> 
    3 <ulist> 
     2<section><h>Changes in 3.0 (released ??/??/2007)</h> 
     3<ul> 
    44<item>Namespaces have been greatly simplified. There are no namespace modules any 
    55longer. An element class can be assigned a namespace by setting the <lit>xmlns</lit> 
     
    1111</item> 
    1212 
    13 <item>Dependency on <link href="http://pyxml.sf.net/">PyXML</link> has finally 
     13<item>Dependency on <a href="http://pyxml.sf.net/">PyXML</a> has finally 
    1414been dropped. &xist; now uses its own &xml; parsing &api;. Two parsers 
    15 are available: One based on <link href="http://expat.sourceforge.net/">expat</link> 
     15are available: One based on <a href="http://expat.sourceforge.net/">expat</a> 
    1616and one based on a custom version of 
    17 <link href="http://effbot.org/zone/sgmlop-index.htm">sgmlop</link>.</item> 
     17<a href="http://effbot.org/zone/sgmlop-index.htm">sgmlop</a>.</item> 
    1818 
    1919<item>Tree traversal has been rewritten again. XFind expressions involving 
    20 multiple uses of <lit>//</lit> now work correctly. The method <method>walk</method> 
     20multiple uses of <lit>//</lit> now work correctly. The method <meth>walk</meth> 
    2121now doesn't yield <class>Cursor</class> objects, but simple path list 
    2222(actually it's always the same list, if you want distinct lists use 
    23 <method>walkpath</method>). Applying XFind expressions to nodes directly 
    24 is no longer supported, you have to call <method>walk</method>, 
    25 <method>walknode</method> or <method>walkpath</method> with the XFind 
     23<meth>walkpath</meth>). Applying XFind expressions to nodes directly 
     24is no longer supported, you have to call <meth>walk</meth>, 
     25<meth>walknode</meth> or <meth>walkpath</meth> with the XFind 
    2626expression instead. Many XFind operators have been renamed and/or reimplemented 
    27 (see the documentation for the <module>xfind</module> module for more 
     27(see the documentation for the <mod>xfind</mod> module for more 
    2828information).</item> 
    2929 
    30 <item><par>The methods <method>__getitem__</method>, <method>__setitem__</method> 
    31 and <method>__delitem__</method> for <class>Frag</class> and <class>Element</class> 
    32 now support the new walk filters, so you can do:</par> 
    33 <ulist> 
     30<item><p>The methods <meth>__getitem__</meth>, <meth>__setitem__</meth> 
     31and <meth>__delitem__</meth> for <class>Frag</class> and <class>Element</class> 
     32now support the new walk filters, so you can do:</p> 
     33<ul> 
    3434<item><lit>del node[html.p]</lit> to delete all <class>html.p</class> child elements 
    3535of <lit>node</lit>;</item> 
     
    4343silly, but illustrates that you can pass a node to get/replace/delete 
    4444that node);</item> 
    45 </ulist> 
     45</ul> 
    4646</item> 
    4747 
    48 <item><par>A new module <module>ll.xist.css</module> has been added which contains 
    49 &css; related functionality: The generator function <function>iterrules</function> 
     48<item><p>A new module <mod>ll.xist.css</mod> has been added which contains 
     49&css; related functionality: The generator function <func>iterrules</func> 
    5050can be passed an &xist; tree and it will produce all &css; rules defined in any 
    5151<class>html.link</class> or <class>html.style</class> elements or imported by them 
    5252(via the &css; rule <lit>@import</lit>). This requires the 
    53 <link href="http://cheeseshop.python.org/pypi/cssutils"><module>cssutils</module></link> 
    54 package.</par> 
    55  
    56 <par>The function <function>applystylesheets</function> modifies the &xist; tree 
     53<a href="http://cheeseshop.python.org/pypi/cssutils"><mod>cssutils</mod></a> 
     54package.</p> 
     55 
     56<p>The function <func>applystylesheets</func> modifies the &xist; tree 
    5757passed in by removing all &css; (from <class>html.link</class> and <class>html.style</class> 
    5858elements and their <lit>@import</lit>ed stylesheets) and putting the styles into 
    59 <lit>style</lit> attributes of the affected elements instead.</par> 
    60  
    61 <par>The function <function>selector</function> return a tree walk filter from 
    62 a &css; selector passed as a string.</par> 
     59<lit>style</lit> attributes of the affected elements instead.</p> 
     60 
     61<p>The function <func>selector</func> return a tree walk filter from 
     62a &css; selector passed as a string.</p> 
    6363</item> 
    6464 
    6565<item> 
    66 <par>Constructing trees can now be done with <lit>with</lit> blocks. Code looks 
    67 like this:</par> 
     66<p>Constructing trees can now be done with <lit>with</lit> blocks. Code looks 
     67like this:</p> 
    6868<prog> 
    6969with xsc.Frag() as node: 
     
    8383print node.conv().bytes(encoding="us-ascii") 
    8484</prog> 
    85 <par>Also the function <function>xsc.append</function> has been renamed to 
    86 <function>add</function> and supports <lit>with</lit> blocks now instead of 
    87 <link href="http://codespeak.net/svn/user/hpk/talks/xpython-talk.txt">XPython</link>.</par> 
     85<p>Also the function <func>xsc.append</func> has been renamed to 
     86<func>add</func> and supports <lit>with</lit> blocks now instead of 
     87<a href="http://codespeak.net/svn/user/hpk/talks/xpython-talk.txt">XPython</a>.</p> 
    8888</item> 
    8989 
    90 <item>A subset of <link href="http://docutils.sourceforge.net/rst.html">ReST</link> 
    91 is supported now for docstrings when using the <module>ll.xist.ns.doc</module> 
     90<item>A subset of <a href="http://docutils.sourceforge.net/rst.html">ReST</a> 
     91is supported now for docstrings when using the <mod>ll.xist.ns.doc</mod> 
    9292module. The module attribute <lit>__docformat__</lit> is now honored (Set it 
    9393to <lit>"xist"</lit> to get &xist; docstrings).</item> 
    9494 
     95<item>Many classes in the <mod>ll.xist.ns.doc</mod> have been renamed 
     96to more familiar names (from &html;, &xhtml; 2 or ReST).</p> 
     97 
    9598<item>The <lit>media</lit> attribute of <class>html.link</class> and 
    96 <class>html.style</class> now has a method <method>hasmedia</method>.</item> 
    97  
    98 <item>The node method <method>asBytes</method> has been renamed to 
    99 <method>bytes</method> and <method>bytes</method> has been renamed to 
    100 <method>iterbytes</method>.</item> 
    101  
    102 <item>The node method <method>asString</method> has been renamed to 
    103 <method>string</method> and a new method <method>iterstring</method> has been 
     99<class>html.style</class> now has a method <meth>hasmedia</meth>.</item> 
     100 
     101<item>The node method <meth>asBytes</meth> has been renamed to 
     102<meth>bytes</meth> and <meth>bytes</meth> has been renamed to 
     103<meth>iterbytes</meth>.</item> 
     104 
     105<item>The node method <meth>asString</meth> has been renamed to 
     106<meth>string</meth> and a new method <meth>iterstring</meth> has been 
    104107added.</item> 
    105108 
     
    107110<class>ll.xist.ns.xml.XML</class> instead.</item> 
    108111 
    109 <item><function>xsc.tonode</function> now will raise an exception when it 
     112<item><func>xsc.tonode</func> now will raise an exception when it 
    110113can't handle an argument instead of issuing a warning.</item> 
    111114 
     
    116119methods.</item> 
    117120 
    118 <item>The deprecated <class>Element</class> methods <method>hasAttr</method>, 
    119 <method>hasattr</method>, <method>isallowedattr</method>, <method>getAttr</method>, 
    120 <method>getattr</method>, <method>setDefaultAttr</method>, 
    121 <method>setdefaultattr</method>, <method>attrkeys</method>, 
    122 <method>attrvalues</method>, <method>attritems</method>, 
    123 <method>iterattrkeys</method>, <method>iterattrvalues</method>, 
    124 <method>iterattritems</method>, <method>allowedattrkeys</method>, 
    125 <method>allowedattrvalues</method>, <method>allowedattritems</method>, 
    126 <method>iterallowedattrkeys</method>, <method>iterallowedattrvalues</method>, 
    127 <method>iterallowedattritems</method> and <method>copyDefaultAttrs</method> 
     121<item>The deprecated <class>Element</class> methods <meth>hasAttr</meth>, 
     122<meth>hasattr</meth>, <meth>isallowedattr</meth>, <meth>getAttr</meth>, 
     123<meth>getattr</meth>, <meth>setDefaultAttr</meth>, 
     124<meth>setdefaultattr</meth>, <meth>attrkeys</meth>, 
     125<meth>attrvalues</meth>, <meth>attritems</meth>, 
     126<meth>iterattrkeys</meth>, <meth>iterattrvalues</meth>, 
     127<meth>iterattritems</meth>, <meth>allowedattrkeys</meth>, 
     128<meth>allowedattrvalues</meth>, <meth>allowedattritems</meth>, 
     129<meth>iterallowedattrkeys</meth>, <meth>iterallowedattrvalues</meth>, 
     130<meth>iterallowedattritems</meth> and <meth>copyDefaultAttrs</meth> 
    128131have been removed. The deprecated <class>Attrs</class> method 
    129 <method>copydefaults</method> has been removed too.</item> 
    130  
    131 <item>The namespace module <module>ll.xist.ns.cond</module> has been removed.</item> 
    132  
    133 <item>When calling the function <function>ll.xist.parsers.parseURL</function> 
     132<meth>copydefaults</meth> has been removed too.</item> 
     133 
     134<item>The namespace module <mod>ll.xist.ns.cond</mod> has been removed.</item> 
     135 
     136<item>When calling the function <func>ll.xist.parsers.parseURL</func> 
    134137the arguments <arg>headers</arg> and <arg>data</arg> are now passed along 
    135138to the parser's method only if they are specified. This makes it possible to 
    136 pass ssh &url;s to <function>ll.xist.parsers.parseURL</function>.</item> 
    137  
    138 <item>The methods <method>withnames</method> and <method>withoutnames</method> have 
     139pass ssh &url;s to <func>ll.xist.parsers.parseURL</func>.</item> 
     140 
     141<item>The methods <meth>withnames</meth> and <meth>withoutnames</meth> have 
    139142been split into two that take Python names and two that take XML names. 
    140143Multiple arguments are used now (instead of one argument that must be a sequence). 
    141144Passing a namespace to remove all attributes from the namespace is no longer supported.</item> 
    142145 
    143 <item>The <class>Attrs</class> methods <method>updatenew</method> and 
    144 <method>updatexisting</method> have been removed.</item> 
    145  
    146 </ulist> 
    147 </section> 
    148  
    149  
    150 <section><title>Changes in 2.15.5 (released 07/17/2007)</title> 
    151  
    152 <ulist> 
     146<item>The <class>Attrs</class> methods <meth>updatenew</meth> and 
     147<meth>updatexisting</meth> have been removed.</item> 
     148 
     149</ul> 
     150</section> 
     151 
     152 
     153<section><h>Changes in 2.15.5 (released 07/17/2007)</h> 
     154 
     155<ul> 
    153156<item>The Python quotes example no longer contains the &xml; source 
    154157or the generated &html;.</item> 
    155 </ulist> 
    156  
    157  
    158 <section><title>Changes in 2.15.4 (released 07/16/2007)</title> 
    159 <ulist> 
     158</ul> 
     159 
     160 
     161<section><h>Changes in 2.15.4 (released 07/16/2007)</h> 
     162<ul> 
    160163<item>The Python quotes example now always parses the file from 
    161164the original &url;.</item> 
    162165<item>The Python quotes and the media example now print the result 
    163166to <lit>stdout</lit>.</item> 
    164 </ulist> 
    165 </section> 
    166  
    167  
    168 <section><title>Changes in 2.15.3 (released 07/16/2007)</title> 
    169 <ulist> 
     167</ul> 
     168</section> 
     169 
     170 
     171<section><h>Changes in 2.15.3 (released 07/16/2007)</h> 
     172<ul> 
    170173<item>Use a consistent license (MIT) everywhere. This should make 
    171174&xist; Debian compatible.</item> 
     
    173176there's no <filename>python-quotes.xml</filename> in the current 
    174177directory.</item> 
    175 </ulist> 
    176 </section> 
    177  
    178  
    179 <section><title>Changes in 2.15.2 (released 01/24/2007)</title> 
    180 <ulist> 
    181 <item>Fixed a bug in <method>presenters.CodePresenter.__str__</method>.</item> 
     178</ul> 
     179</section> 
     180 
     181 
     182<section><h>Changes in 2.15.2 (released 01/24/2007)</h> 
     183<ul> 
     184<item>Fixed a bug in <meth>presenters.CodePresenter.__str__</meth>.</item> 
    182185<item>Fixed base URL handling for tidy parsing.</item> 
    183186<item>Updated examples.</item> 
    184 <item>Updated <function>xiter</function> and <function>xattrs</function> 
     187<item>Updated <func>xiter</func> and <func>xattrs</func> 
    185188implementations for <class>Node</class> and <class>Namespace</class> to 
    186189conform to the newest version of IPython.</item> 
    187 </ulist> 
    188 </section> 
    189  
    190  
    191 <section><title>Changes in 2.15.1 (released 09/25/2006)</title> 
    192 <ulist> 
    193 <item>Fixed a few bugs in the <module>sgmlop</module> function declarations.</item> 
     190</ul> 
     191</section> 
     192 
     193 
     194<section><h>Changes in 2.15.1 (released 09/25/2006)</h> 
     195<ul> 
     196<item>Fixed a few bugs in the <mod>sgmlop</mod> function declarations.</item> 
    194197<item>Readded the spacer pixel.</item> 
    195 </ulist> 
    196 </section> 
    197  
    198  
    199 <section><title>Changes in 2.15 (released 09/24/2006)</title> 
    200 <ulist> 
     198</ul> 
     199</section> 
     200 
     201 
     202<section><h>Changes in 2.15 (released 09/24/2006)</h> 
     203<ul> 
    201204<item>&xist; has been made compatible with Python 2.5: Code has been updated 
    202 to use the proper C API for memory management and <link href="http://www.python.org/dev/peps/pep-0353/">PEP 353</link> 
    203 support has been added. &xist; now includes its own fixed version of <module>sgmlop</module>.</item> 
    204 <item>The <class>ll.xist.xsc.Attrs</class> methods <method>with</method> and 
    205 <method>without</method> have been renamed to <method>withnames</method> and 
    206 <method>withoutnames</method> for Python 2.5 compatibility.</item> 
     205to use the proper C API for memory management and <a href="http://www.python.org/dev/peps/pep-0353/">PEP 353</a> 
     206support has been added. &xist; now includes its own fixed version of <mod>sgmlop</mod>.</item> 
     207<item>The <class>ll.xist.xsc.Attrs</class> methods <meth>with</meth> and 
     208<meth>without</meth> have been renamed to <meth>withnames</meth> and 
     209<meth>withoutnames</meth> for Python 2.5 compatibility.</item> 
    207210<item><class>ll.xist.ns.htmlspecials.pixel</class> no longer handles colors 
    208211via different GIFs. It uses the <lit>background-color</lit> in the <lit>style</lit> 
     
    211214the default <lit>src</lit> attribute value of <lit>root:px/spc.gif</lit> either 
    212215via the &xml; attribute or via the converter context.</item> 
    213 <item>The node method <method>asText</method> has been made a function, moved 
    214 into the <module>html</module> namespace and renamed to <function>astext</function>. 
     216<item>The node method <meth>asText</meth> has been made a function, moved 
     217into the <mod>html</mod> namespace and renamed to <func>astext</func>. 
    215218Furthermore <app moreinfo="http://elinks.or.cz/">elinks</app> is used for plain text 
    216219formatting now instead of <app moreinfo="http://w3m.sourceforge.net/">w3m</app>.</item> 
    217 </ulist> 
    218 </section> 
    219  
    220  
    221 <section><title>Changes in 2.14.2 (released 07/04/2006)</title> 
    222 <ulist> 
    223 <item>Fixed a bug in the <method>presentAttr</method> method of 
     220</ul> 
     221</section> 
     222 
     223 
     224<section><h>Changes in 2.14.2 (released 07/04/2006)</h> 
     225<ul> 
     226<item>Fixed a bug in the <meth>presentAttr</meth> method of 
    224227<class>ll.xist.presenters.TreePresenter</class>.</item> 
    225 </ulist> 
    226 </section> 
    227  
    228  
    229 <section><title>Changes in 2.14.1 (released 06/29/2006)</title> 
    230 <ulist> 
    231 <item>Fixed a bug in the <method>presentEntity</method> method of 
     228</ul> 
     229</section> 
     230 
     231 
     232<section><h>Changes in 2.14.1 (released 06/29/2006)</h> 
     233<ul> 
     234<item>Fixed a bug in the <meth>presentEntity</meth> method of 
    232235<class>ll.xist.presenters.CodePresenter</class>.</item> 
    233236<item>Updated installation instructions.</item> 
    234 </ulist> 
    235 </section> 
    236  
    237  
    238 <section><title>Changes in 2.14 (released 06/28/2006)</title> 
    239 <ulist> 
     237</ul> 
     238</section> 
     239 
     240 
     241<section><h>Changes in 2.14 (released 06/28/2006)</h> 
     242<ul> 
    240243<item>Namespaces for RSS 0.91, RSS 2.0 and Atom 1.0 have been added.</item> 
    241244 
    242 <item>A new namespace <module>ll.xist.ns.detox</module> has been added that 
    243 is similar to <module>ll.toxic</module> but can be used to generate Python 
    244 code instead of PL/SQL code. Using <module>detox</module> templates is about 
     245<item>A new namespace <mod>ll.xist.ns.detox</mod> has been added that 
     246is similar to <mod>ll.toxic</mod> but can be used to generate Python 
     247code instead of PL/SQL code. Using <mod>detox</mod> templates is about 
    24524850 times faster than using &xist; trees directly and about 10 times faster than 
    246 <link href="http://kid.lesscode.org/">Kid</link>.</item> 
    247  
    248 <item>Presenters are now compatible to <link href="http://ipython.scipy.org/">IPython</link>'s 
     249<a href="http://kid.lesscode.org/">Kid</a>.</item> 
     250 
     251<item>Presenters are now compatible to <a href="http://ipython.scipy.org/">IPython</a>'s 
    249252ipipe module. This means that you can browse &xist; trees interactively 
    250253if you have IPython installed. <class>NormalPresenter</class> and the 
    251 <class>Node</class> methods <method>repr</method> and <method>asrepr</method> 
     254<class>Node</class> methods <meth>repr</meth> and <meth>asrepr</meth> 
    252255have been removed.</item> 
    253256 
     
    259262<lit>lang</lit> and <lit>xml:lang</lit> attribute, if neither of them exists.</item> 
    260263 
    261 <item><module>setuptools</module> is now supported for installation.</item> 
    262 </ulist> 
    263 </section> 
    264  
    265  
    266 <section><title>Changes in 2.13 (released 10/31/2005)</title> 
    267 <ulist> 
    268 <item><method>ll.xist.xsc.Namespace.tokenize</method> requires a 
     264<item><mod>setuptools</mod> is now supported for installation.</item> 
     265</ul> 
     266</section> 
     267 
     268 
     269<section><h>Changes in 2.13 (released 10/31/2005)</h> 
     270<ul> 
     271<item><meth>ll.xist.xsc.Namespace.tokenize</meth> requires a 
    269272<class>unicode</class> object as input now. This makes it possible 
    270273to use encodings that are not ASCII compatible (such as UTF-16). 
    271274The <arg>encoding</arg> argument is gone.</item> 
    272275 
    273 <item><method>ll.xist.xsc.Node.asString</method> uses the <arg>encoding</arg> 
     276<item><meth>ll.xist.xsc.Node.asString</meth> uses the <arg>encoding</arg> 
    274277argument to determine which characters have to be output as character references 
    275278now. (You'll still get a unicode object as the result.)</item> 
     
    279282can be used for embedding preformatted &xml; (e.g. from a database) into an 
    280283XIST tree.</item> 
    281 </ulist> 
    282  
    283 </section> 
    284  
    285  
    286 <section><title>Changes in 2.12 (released 10/13/2005)</title> 
    287 <ulist> 
    288 <item>Namespaces for <link href="http://www.relaxng.org/">Relax NG</link> and 
    289 <link href="http://kid.lesscode.org/">Kid</link> have been added.</item> 
     284</ul> 
     285 
     286</section> 
     287 
     288 
     289<section><h>Changes in 2.12 (released 10/13/2005)</h> 
     290<ul> 
     291<item>Namespaces for <a href="http://www.relaxng.org/">Relax NG</a> and 
     292<a href="http://kid.lesscode.org/">Kid</a> have been added.</item> 
    290293 
    291294<item>&xist; requires version 1.0 of the core package now.</item> 
     
    293296<item>The class name for the DocBook &dtd; class has been fixed.</item> 
    294297 
    295 </ulist> 
    296  
    297 </section> 
    298  
    299  
    300 <section><title>Changes in 2.11 (released 07/29/2005)</title> 
    301 <ulist> 
     298</ul> 
     299 
     300</section> 
     301 
     302 
     303<section><h>Changes in 2.11 (released 07/29/2005)</h> 
     304<ul> 
    302305<item>A script <filename>xml2xsc.py</filename> has been added, that 
    303306can be used to parse an &xml; file and generate a rudimentary &xist; namespace 
     
    309312<item>Line number information is now added when parsing &html;.</item> 
    310313 
    311 <item>The <method>sorted</method> method now supports the same arguments 
     314<item>The <meth>sorted</meth> method now supports the same arguments 
    312315(<arg>cmp</arg>, <arg>key</arg> and <arg>reverse</arg>) as 
    313 <method>list.sort</method> and <function>sorted</function> in Python 2.4.</item> 
    314  
    315 <item>The <method>walk</method> doesn't yield the node directly, but yields 
     316<meth>list.sort</meth> and <func>sorted</func> in Python 2.4.</item> 
     317 
     318<item>The <meth>walk</meth> doesn't yield the node directly, but yields 
    316319a <class>Cursor</class> object now, with has several ways of referencing the node.</item> 
    317320 
    318 <item>New methods <method>walknode</method>, <method>walkpath</method> and 
    319 <method>walkindex</method> have been added.</item> 
     321<item>New methods <meth>walknode</meth>, <meth>walkpath</meth> and 
     322<meth>walkindex</meth> have been added.</item> 
    320323 
    321324<item>Presenters use an iterator &api; instead of a stream &api; now. Dumping 
     
    324327 
    325328<item>Fixed a bug with element/attribute names that contained a <lit>.</lit> 
    326 character. (This broke <module>ll.xist.ns.fo</module>.)</item> 
     329character. (This broke <mod>ll.xist.ns.fo</mod>.)</item> 
    327330 
    328331<item>Fixed a bug with <lit>xmlns</lit> attributes in nested elements. 
     
    332335current version of AMK's &xml; file.</item> 
    333336 
    334 <item>Removed iterator stuff from <module>ll.xist.xfind</module>, as this 
    335 is now part of the <module>ll</module> package/module.</item> 
    336  
    337 <item>The function <function>ToNode</function> has been renamed to 
    338 <function>tonode</function>.</item> 
     337<item>Removed iterator stuff from <mod>ll.xist.xfind</mod>, as this 
     338is now part of the <mod>ll</mod> package/module.</item> 
     339 
     340<item>The function <func>ToNode</func> has been renamed to 
     341<func>tonode</func>.</item> 
    339342 
    340343<item><class>ll.xist.Context</class> no longer subclasses <class>list</class>.</item> 
     
    343346in the order in which they appear in the Python source.</item> 
    344347 
    345 <item>The node methods <method>find</method> and <method>findfirst</method> 
     348<item>The node methods <meth>find</meth> and <meth>findfirst</meth> 
    346349have been removed.</item> 
    347350 
    348 <item><module>ll.xist.ns.cond</module> now uses a sandbox dictionary in a 
     351<item><mod>ll.xist.ns.cond</mod> now uses a sandbox dictionary in a 
    349352converter context for evaluating expression.</item> 
    350 </ulist> 
    351 </section> 
    352  
    353  
    354 <section><title>Changes in 2.10 (released 05/20/2005)</title> 
    355 <ulist> 
     353</ul> 
     354</section> 
     355 
     356 
     357<section><h>Changes in 2.10 (released 05/20/2005)</h> 
     358<ul> 
    356359<item>The content of the processing instruction <class>ll.xist.ns.code.pyexec</class> 
    357360will not be executed at construction time, but at conversion time. The code 
    358361in <class>ll.xist.ns.code.pyexec</class> or <class>ll.xist.ns.code.pyeval</class> 
    359 will no longer be executed in the <module>ll.xist.sandbox</module> module 
     362will no longer be executed in the <mod>ll.xist.sandbox</mod> module 
    360363(which has been removed), but in a sandbox dictionary in the converter context 
    361 of the <module>ll.xist.ns.code</module> namespace.</item> 
    362  
    363 <item>The tests have been ported to <link href="http://codespeak.net/py/current/doc/test.html">py.test</link>.</item> 
    364  
    365 <item>The method <method>mapped</method> is now callable without arguments. 
     364of the <mod>ll.xist.ns.code</mod> namespace.</item> 
     365 
     366<item>The tests have been ported to <a href="http://codespeak.net/py/current/doc/test.html">py.test</a>.</item> 
     367 
     368<item>The method <meth>mapped</meth> is now callable without arguments. 
    366369In this case a converter will be created on the fly. You can pass constructor 
    367 arguments for this converter to <method>mapped</method> as keyword arguments.</item> 
    368  
    369 <item>The publishing &api; has changed again: <method>ll.xist.publishers.Publisher.publish</method> 
     370arguments for this converter to <meth>mapped</meth> as keyword arguments.</item> 
     371 
     372<item>The publishing &api; has changed again: <meth>ll.xist.publishers.Publisher.publish</meth> 
    370373no longer accepts an argument <arg>stream</arg> to which the byte strings are 
    371 written, but it is a generator now. The publisher methods <method>write</method> 
    372 and <method>writetext</method> have been renamed to <method>encode</method> and 
    373 <method>encodetext</method> and return the encoded byte string, instead of 
     374written, but it is a generator now. The publisher methods <meth>write</meth> 
     375and <meth>writetext</meth> have been renamed to <meth>encode</meth> and 
     376<meth>encodetext</meth> and return the encoded byte string, instead of 
    374377writing it directly to the stream. There's a new generator method 
    375 <method>bytes</method> for nodes now, which can be passed the same arguments 
    376 as <method>asBytes</method>. These changes should help when using 
     378<meth>bytes</meth> for nodes now, which can be passed the same arguments 
     379as <meth>asBytes</meth>. These changes should help when using 
    377380&xist; in &wsgi; applications.</item> 
    378381 
    379 <item>The iterator returned from <method>Element.__getitem__</method>, 
    380 <method>Frag.__getitem__</method> and the <method>walk</method> method 
    381 now supports <method>__getitem__</method> itself, so you can write 
     382<item>The iterator returned from <meth>Element.__getitem__</meth>, 
     383<meth>Frag.__getitem__</meth> and the <meth>walk</meth> method 
     384now supports <meth>__getitem__</meth> itself, so you can write 
    382385<lit><rep>table</rep>[html.tr][0]</lit> to get the first row from a table or 
    383386<lit><rep>page</rep>.walk(xsc.FindTypeAll(html.td))[-1]</lit> to get the last table cell 
    384387from a complete &html; page.</item> 
    385388 
    386 <item>Several bugs in the namespaces <module>ll.xist.ns.meta</module>, 
    387 <module>ll.xist.ns.form</module> and 
    388 <module>ll.xist.ns.specials</module> have been fixed.</item> 
    389 <item>The namespace modules <module>ll.xist.ns.css</module> and 
    390 <module>ll.xist.ns.cssspecials</module> have been removed.</item> 
    391 </ulist> 
    392 </section> 
    393  
    394  
    395 <section><title>Changes in 2.9 (released 04/21/2005)</title> 
    396 <ulist> 
     389<item>Several bugs in the namespaces <mod>ll.xist.ns.meta</mod>, 
     390<mod>ll.xist.ns.form</mod> and 
     391<mod>ll.xist.ns.specials</mod> have been fixed.</item> 
     392<item>The namespace modules <mod>ll.xist.ns.css</mod> and 
     393<mod>ll.xist.ns.cssspecials</mod> have been removed.</item> 
     394</ul> 
     395</section> 
     396 
     397 
     398<section><h>Changes in 2.9 (released 04/21/2005)</h> 
     399<ul> 
    397400<item>&xist; trees can now be pickled. The only restriction is that global 
    398401attributes must come from a namespace that has been turned into a module 
    399 via <method>makemod</method>, so that this module can be imported on 
     402via <meth>makemod</meth>, so that this module can be imported on 
    400403unpickling.</item> 
    401404 
    402 <item><par>Two arguments of the <method>walk</method> method have been renamed: 
     405<item><p>Two arguments of the <meth>walk</meth> method have been renamed: 
    403406<arg>filtermode</arg> has been renamed to <arg>inmode</arg> and <arg>walkmode</arg> 
    404407has been renamed to <arg>outmode</arg>. For these modes two new values are 
    405 supported:</par> 
    406 <dlist> 
     408supported:</p> 
     409<dl> 
    407410<term><lit>ll.xist.xsc.walkindex</lit></term><item>The value passed to the filter 
    408411function or yielded from the iterator is a list containing child indizes and 
     
    410413<term><lit>ll.xist.xsc.walkrootindex</lit></term><item>The filter function 
    411414will be called with two arguments: The first is the root node of the tree (i.e. 
    412 the node for which <method>walk</method> has been called), the second one is 
     415the node for which <meth>walk</meth> has been called), the second one is 
    413416an index path (just like for <lit>ll.xist.xsc.walkindex</lit>). If used as 
    414417an <arg>outmode</arg> a tuple with these two values will be yielded.</item> 
    415 </dlist> 
     418</dl> 
    416419</item> 
    417 <item><par>Attribute mappings now support <method>__getitem__</method>, 
    418 <method>__setitem__</method> and <method>__delitem__</method> with list 
    419 arguments, i.e. you can do:</par> 
     420<item><p>Attribute mappings now support <meth>__getitem__</meth>, 
     421<meth>__setitem__</meth> and <meth>__delitem__</meth> with list 
     422arguments, i.e. you can do:</p> 
    420423<prog> 
    421424<prompt>&gt;&gt;&gt; </prompt><input>from ll.xist.ns import html</input> 
     
    431434</prog> 
    432435</item> 
    433 <item><par>&xml; attributes can now be accessed as Python attributes, i.e.</par> 
     436<item><p>&xml; attributes can now be accessed as Python attributes, i.e.</p> 
    434437<prog> 
    435438<prompt>&gt;&gt;&gt; </prompt><input>from ll.xist.ns import html</input> 
     
    438441eggs 
    439442</prog> 
    440 <par>(Don't confuse this with <lit>e.Attrs.href</lit> which is the 
    441 attribute class.)</par> 
     443<p>(Don't confuse this with <lit>e.Attrs.href</lit> which is the 
     444attribute class.)</p> 
    442445</item> 
    443446 
    444447<item><class>Frag</class> and <class>Element</class> now support <class>Node</class> 
    445 subclasses as arguments to their <method>__getitem__</method> method: An iterator 
     448subclasses as arguments to their <meth>__getitem__</meth> method: An iterator 
    446449for all children of the specified type will be returned.</item> 
    447450 
     
    452455and <lit>"iso-8859-1"</lit> will be used when parsing broken &html;.</item> 
    453456 
    454 <item>All error and warning classes from <module>ll.xist.errors</module> 
    455 have been merged into <module>ll.xist.xsc</module>. This avoids import 
     457<item>All error and warning classes from <mod>ll.xist.errors</mod> 
     458have been merged into <mod>ll.xist.xsc</mod>. This avoids import 
    456459problems with circular imports.</item> 
    457460 
     
    468471 
    469472<item>Instances of <class>ll.xist.xsc.Entity</class> subclasses can now be 
    470 compared. <method>__eq__</method> simply checks if the objects are instances 
     473compared. <meth>__eq__</meth> simply checks if the objects are instances 
    471474of the same class.</item> 
    472 </ulist> 
    473 </section> 
    474  
    475  
    476 <section><title>Changes in 2.8.1 (released 03/22/2005)</title> 
    477 <ulist> 
     475</ul> 
     476</section> 
     477 
     478 
     479<section><h>Changes in 2.8.1 (released 03/22/2005)</h> 
     480<ul> 
    478481<item>Added a note about the package init file to the installation 
    479482documentation.</item> 
    480 </ulist> 
    481 </section> 
    482  
    483  
    484 <section><title>Changes in 2.8 (released 01/03/2005)</title> 
    485 <ulist> 
     483</ul> 
     484</section> 
     485 
     486 
     487<section><h>Changes in 2.8 (released 01/03/2005)</h> 
     488<ul> 
    486489<item>&xist; requires Python 2.4 now.</item> 
    487490 
     
    506509the displayhook you can tweak or replace <lit>ll.xist.presenters.hookpresenter</lit> 
    507510to change the output.</item> 
    508 </ulist> 
    509 </section> 
    510  
    511  
    512 <section><title>Changes in 2.7 (released 11/24/2004)</title> 
    513 <ulist> 
     511</ul> 
     512</section> 
     513 
     514 
     515<section><h>Changes in 2.7 (released 11/24/2004)</h> 
     516<ul> 
    514517<item>The transparent pixel used by <class>ll.xist.ns.htmlspecials.pixel</class> 
    515518has been renamed to <filename>spc.gif</filename> to avoid problems with IE.</item> 
    516519<item>Removed a debug print in <class>ll.xist.xfind.Finder.__getitem__</class>.</item> 
    517 <item><module>ll.xist.xfind</module> now has a new function <function>item</function>, 
     520<item><mod>ll.xist.xfind</mod> now has a new function <func>item</func>, 
    518521that can be used to get a certain item or slice from an iterator. 
    519 <function>xfind.first</function> and <function>xfind.last</function> have been 
    520 changed to use <function>xfind.item</function>, so you now have to pass a 
     522<func>xfind.first</func> and <func>xfind.last</func> have been 
     523changed to use <func>xfind.item</func>, so you now have to pass a 
    521524default value to get the old behaviour.</item> 
    522 <item>Obsolete options in <module>ll.xist.options</module> have been removed 
     525<item>Obsolete options in <mod>ll.xist.options</mod> have been removed 
    523526(and <lit>reprEncoding</lit> has been renamed to <lit>reprencoding</lit>).</item> 
    524 </ulist> 
    525 </section> 
    526  
    527  
    528 <section><title>Changes in 2.6.2 (released 06/06/2005)</title> 
    529 <ulist> 
    530 <item>Fixed a bug in <method>ll.xist.parsers.Parser.parse</method>.</item> 
    531 </ulist> 
    532 </section> 
    533  
    534  
    535 <section><title>Changes in 2.6.1 (released 11/02/2004)</title> 
    536 <ulist> 
    537 <item>Fixed a bug in <method>ll.xist.xfind.Finder.__floordiv__</method>.</item> 
     527</ul> 
     528</section> 
     529 
     530 
     531<section><h>Changes in 2.6.2 (released 06/06/2005)</h> 
     532<ul> 
     533<item>Fixed a bug in <meth>ll.xist.parsers.Parser.parse</meth>.</item> 
     534</ul> 
     535</section> 
     536 
     537 
     538<section><h>Changes in 2.6.1 (released 11/02/2004)</h> 
     539<ul> 
     540<item>Fixed a bug in <meth>ll.xist.xfind.Finder.__floordiv__</meth>.</item> 
    538541<item>Restricted characters as defined in 
    539 <link href="http://www.w3.org/TR/2004/REC-xml11-20040204/#NT-RestrictedChar">&xml; 1.1</link> 
     542<a href="http://www.w3.org/TR/2004/REC-xml11-20040204/#NT-RestrictedChar">&xml; 1.1</a> 
    540543will now be published as character references.</item> 
    541 </ulist> 
    542 </section> 
    543  
    544  
    545 <section><title>Changes in 2.6 (released 10/26/2004)</title> 
    546 <ulist> 
    547 <item><function>ToNode</function> now tries iterating through the 
     544</ul> 
     545</section> 
     546 
     547 
     548<section><h>Changes in 2.6 (released 10/26/2004)</h> 
     549<ul> 
     550<item><func>ToNode</func> now tries iterating through the 
    548551value passed in, so it's now possible to pass iterators and generators 
    549552(and generator expressions in Python 2.4) to <class>Frag</class> 
    550553and <class>Element</class> constructors.</item> 
    551554 
    552 <item><par>A new &api; named XFind has been added for iterating through &xml; 
     555<item><p>A new &api; named XFind has been added for iterating through &xml; 
    553556trees. XFind expressions look somewhat like XPath expressions but are pure 
    554557Python expressions. For example finding all images inside links in an &html; 
    555 page can be done like this:</par> 
    556 <example><title>Finding linked images with XFind</title> 
     558page can be done like this:</p> 
     559<example><h>Finding linked images with XFind</h> 
    557560<prog> 
    558561from ll.xist import parsers, xfind 
     
    564567</example> 
    565568 
    566 <par>The module <module>ll.xist.xfind</module> contains several operators 
    567 that can be used in XFind expressions.</par> 
     569<p>The module <mod>ll.xist.xfind</mod> contains several operators 
     570that can be used in XFind expressions.</p> 
    568571</item> 
    569572 
    570573<item>Parsing broken &html; is now done with the &html; parser from 
    571 <link href="http://www.xmlsoft.org/">libxml2</link>. The parsing functions 
     574<a href="http://www.xmlsoft.org/">libxml2</a>. The parsing functions 
    572575no longer accept options for tidy, only the boolean value of the <arg>tidy</arg> 
    573576argument is used.</item> 
    574577 
    575578<item>The publishing &api; has been simplified: Publication can now be done with 
    576 a call to <method>ll.xist.publishers.Publisher.publish</method>, passing in a 
     579a call to <meth>ll.xist.publishers.Publisher.publish</meth>, passing in a 
    577580<class>ll.xist.xsc.Node</class>. Writing strings to the publisher output is 
    578 now done with <method>ll.xist.publishers.Publisher.write</method>. The methods 
    579 <method>beginPublication</method> and <method>endPublication</method> have been 
     581now done with <meth>ll.xist.publishers.Publisher.write</meth>. The methods 
     582<meth>beginPublication</meth> and <meth>endPublication</meth> have been 
    580583removed.</item> 
    581584 
    582585<item>The presentation &api; has been simplified in the same way: You'll get a 
    583586presentation by calling: <lit>string = <rep>presenter</rep>.present(<rep>node</rep>)</lit>. 
    584 The methods <method>beginPresentation</method> and <method>endPresentation</method> 
     587The methods <meth>beginPresentation</meth> and <meth>endPresentation</meth> 
    585588have been removed.</item> 
    586589 
     
    589592exception, but this can now be reconfigured via Python's warning framework.</item> 
    590593 
    591 <item>The classmethod <method>tokenize</method> from <module>ll.toxic</module> 
     594<item>The classmethod <meth>tokenize</meth> from <mod>ll.toxic</mod> 
    592595has been moved to <class>ll.xist.xsc.Namespace</class>, so it's now possible 
    593596to tokenize an &xml; string for other processing instructions as well.</item> 
     
    602605 
    603606<item>Elements <class>hostname</class>, <class>tty</class>, <class>prompt</class> 
    604 and <class>input</class> were add to <module>ll.xist.ns.doc</module>.</item> 
    605  
    606 <item>The method <method>ll.xist.xsc.Attrs.set</method> now returns the 
     607and <class>input</class> were add to <mod>ll.xist.ns.doc</mod>.</item> 
     608 
     609<item>The method <meth>ll.xist.xsc.Attrs.set</meth> now returns the 
    607610new attribute object.</item> 
    608611 
    609 <item>The <method>visit</method> method has been removed.</item> 
    610  
    611 <item><method>ll.xist.xsc.FindOld</method> has been removed.</item> 
     612<item>The <meth>visit</meth> method has been removed.</item> 
     613 
     614<item><meth>ll.xist.xsc.FindOld</meth> has been removed.</item> 
    612615 
    613616<item><class>ll.xist.ns.xml.header</class> has been renamed to 
    614617<class>ll.xist.ns.xml.declaration</class>.</item> 
    615618 
    616 </ulist> 
    617  
    618 </section> 
    619  
    620  
    621 <section><title>Changes in 2.5 (released 06/30/2004)</title> 
    622 <ulist> 
     619</ul> 
     620 
     621</section> 
     622 
     623 
     624<section><h>Changes in 2.5 (released 06/30/2004)</h> 
     625<ul> 
    623626 
    624627<item>Specifying content models for elements has seen major enhancements. The 
    625628boolean class attribute <lit>empty</lit> has been replaced by an object 
    626 <lit>model</lit> whose <method>checkvalid</method> method will be called 
     629<lit>model</lit> whose <meth>checkvalid</meth> method will be called 
    627630for validating the element content.</item> 
    628631 
    629 <item>A new module <module>ll.xist.sims</module> has been added that provides 
     632<item>A new module <mod>ll.xist.sims</mod> has been added that provides 
    630633a simple schema validation. Schema violations will be reported via Pythons 
    631634warning framework.</item> 
    632635 
    633 <item>All namespace modules have been updated to use <module>sims</module> 
     636<item>All namespace modules have been updated to use <mod>sims</mod> 
    634637information. The &svg; module has been updated to &svg; 1.1. The docbook 
    635638module has been updated to DocBook 4.3.</item> 
     
    637640<item>It's possible to switch off validation during parsing and publishing.</item> 
    638641 
    639 <item><par><class>ll.xist.xsc.Frag</class> and <class>ll.xist.xsc.Element</class> 
    640 both have a <method>__call__</method> method with the same arguments as 
     642<item><p><class>ll.xist.xsc.Frag</class> and <class>ll.xist.xsc.Element</class> 
     643both have a <meth>__call__</meth> method with the same arguments as 
    641644their constructors. Those methods will append content nodes (and set attributes 
    642645for <class>ll.xist.xsc.Element</class>) and return <self/>, so they can be used 
    643646when creating an object tree. This makes it possible to put the attributes close 
    644 to the tag name, instead of putting them at the end after the content.</par> 
    645 <par>Instead of:</par> 
     647to the tag name, instead of putting them at the end after the content.</p> 
     648<p>Instead of:</p> 
    646649<example> 
    647650<prog> 
     
    659662</prog> 
    660663</example> 
    661 <par>you can now use the following:</par> 
     664<p>you can now use the following:</p> 
    662665<example> 
    663666<prog> 
     
    677680</item> 
    678681 
    679 <item><par>Experimental support for Holger Krekel's 
    680 <link href="http://codespeak.net/svn/user/hpk/talks/xpython-talk.txt">XPython</link> 
    681 has been added. Code might look like this:</par> 
     682<item><p>Experimental support for Holger Krekel's 
     683<a href="http://codespeak.net/svn/user/hpk/talks/xpython-talk.txt">XPython</a> 
     684has been added. Code might look like this:</p> 
    682685<example> 
    683686<prog> 
     
    713716 
    714717<item> 
    715 <par>Creating global attributes has been simplified. Passing an instance 
     718<p>Creating global attributes has been simplified. Passing an instance 
    716719of <class>ll.xist.xsc.Namespace.Attrs</class> to an <class>Element</class> 
    717 constructor now does the right thing:</par> 
     720constructor now does the right thing:</p> 
    718721<example> 
    719722<prog> 
     
    729732 
    730733<item>Creating skeleton implementations of &xist; namespaces is no longer done 
    731 via &xml; conversion (i.e. the namespace module <module>ll.xist.ns.xndl</module>), 
    732 but through the new module <module>ll.xist.xnd</module>. The script 
    733 <filename>dtdxsc.py</filename> will automatically generate <module>sims</module> 
     734via &xml; conversion (i.e. the namespace module <mod>ll.xist.ns.xndl</mod>), 
     735but through the new module <mod>ll.xist.xnd</mod>. The script 
     736<filename>dtdxsc.py</filename> will automatically generate <mod>sims</mod> 
    734737information.</item> 
    735738 
     
    753756<item>Two mailing lists are now available: One for discussion about &xist; 
    754757and one for &xist; announcements.</item> 
    755 </ulist> 
    756 </section> 
    757  
    758  
    759 <section><title>Changes in 2.4.1 (released 01/05/2004)</title> 
    760 <ulist> 
     758</ul> 
     759</section> 
     760 
     761 
     762<section><h>Changes in 2.4.1 (released 01/05/2004)</h> 
     763<ul> 
    761764<item>Changed the xmlname of <class>ll.xist.ns.jsp.directive_page</class> back again 
    762765(it's <lit>directive.page</lit> only for the &xml; form, which we don't use anyway.)</item> 
     
    768771a namespace it will return this prefix too, if asked for a prefix for a subclass 
    769772of this namespace.</item> 
    770 </ulist> 
    771 </section> 
    772  
    773  
    774 <section><title>Changes in 2.4 (released 01/02/2004)</title> 
    775 <ulist> 
     773</ul> 
     774</section> 
     775 
     776 
     777<section><h>Changes in 2.4 (released 01/02/2004)</h> 
     778<ul> 
    776779<item>The class <class>ll.xist.parsers.Handler</class> has been renamed to 
    777780<class>Parser</class> and has been made reusable, i.e. it is possible to 
     
    788791<item>Now converter contexts are no longer bound to an element 
    789792class, but to the context class defined by the element class, i.e. 
    790 the attribute <lit>Context</lit> of the argument for <method>Converter.__getitem__</method> 
     793the attribute <lit>Context</lit> of the argument for <meth>Converter.__getitem__</meth> 
    791794will be used as the dictionary key. This makes it possible to use a class 
    792795and it subclasses interchangeably (as long as the base class defines 
     
    795798searches content and attributes.</item> 
    796799<item>Fixed the &xml; name for <class>ll.xist.ns.jsp.directive_page</class>.</item> 
    797 <item>All character references in <module>ll.xist.ns.ihtml</module> 
    798 that exist in <module>ll.xist.ns.chars</module> too have been removed.</item> 
    799 </ulist> 
    800 </section> 
    801  
    802  
    803 <section><title>Changes in 2.3 (released 12/08/2003)</title> 
    804 <ulist> 
     800<item>All character references in <mod>ll.xist.ns.ihtml</mod> 
     801that exist in <mod>ll.xist.ns.chars</mod> too have been removed.</item> 
     802</ul> 
     803</section> 
     804 
     805 
     806<section><h>Changes in 2.3 (released 12/08/2003)</h> 
     807<ul> 
    805808<item>It's now possible to parse &xml; without generating location 
    806809information for each node, by passing <lit>loc=False</lit> to 
     
    814817passing an argument dictionary for the <arg>tidy</arg> argument 
    815818in the parsing functions.</item> 
    816 <item>The methods <method>parsed</method> and <method>checkvalid</method> 
     819<item>The methods <meth>parsed</meth> and <meth>checkvalid</meth> 
    817820have been separated.</item> 
    818821<item><class>ll.xist.ns.htmlspecials.pixel</class> and 
     
    820823<lit>color</lit> attribute is ok.</item> 
    821824<item>The base &url; is now set correctly when parsing from an &url; 
    822 even if the original &url; does a redirect. (This requires <module>ll.url</module> 
     825even if the original &url; does a redirect. (This requires <mod>ll.url</mod> 
    823826version 0.11.3).</item> 
    824827<item>Namespace handling has been rewritten again, to be more standards 
     
    828831<class>xsc.NamespaceAttrMixIn</class> is gone too.</item> 
    829832<item>The processing instructions <class>exec_</class> and <class>eval_</class> 
    830 from <module>ll.xist.ns.code</module> have been renamed to <class>pyexec</class> 
     833from <mod>ll.xist.ns.code</mod> have been renamed to <class>pyexec</class> 
    831834and <class>pyeval</class> and <class>import_</class> has been removed.</item> 
    832 <item><class>CharRef</class>s from <module>ll.xist.ns.html</module> have been 
    833 moved to a new module named <module>ll.xist.ns.chars</module>.</item> 
    834 <item>The method names <method>beginPublication</method>, <method>endPublication</method> 
    835 and <method>doPublication</method> have been lowercased.</item> 
    836 </ulist> 
    837 </section> 
    838  
    839  
    840 <section><title>Changes in 2.2 (released 07/31/2003)</title> 
    841 <ulist> 
    842 <item><par>Namespace handling has been completely rewritten. 
     835<item><class>CharRef</class>s from <mod>ll.xist.ns.html</mod> have been 
     836moved to a new module named <mod>ll.xist.ns.chars</mod>.</item> 
     837<item>The method names <meth>beginPublication</meth>, <meth>endPublication</meth> 
     838and <meth>doPublication</meth> have been lowercased.</item> 
     839</ul> 
     840</section> 
     841 
     842 
     843<section><h>Changes in 2.2 (released 07/31/2003)</h> 
     844<ul> 
     845<item><p>Namespace handling has been completely rewritten. 
    843846Namespaces are now classes derived from <class>ll.xist.xsc.Namespace</class>. 
    844847Defining element classes can be done inside or outside the namespace 
    845848class. If the element classes are defined outside the namespace 
    846849class, they can be moved inside the namespace with a simple 
    847 attribute assignment:</par> 
     850attribute assignment:</p> 
    848851<prog> 
    849852class foo(xsc.Element): 
     
    856859xmlns.foo = foo 
    857860</prog> 
    858 <par>The methods <method>elementkeys</method>, <method>iterelementkeys</method>, 
    859 <method>elementvalues</method>, <method>iterelementvalues</method>, 
    860 <method>elementitems</method> and <method>iterelementitems</method> 
     861<p>The methods <meth>elementkeys</meth>, <meth>iterelementkeys</meth>, 
     862<meth>elementvalues</meth>, <meth>iterelementvalues</meth>, 
     863<meth>elementitems</meth> and <meth>iterelementitems</meth> 
    861864can be used for iterating through the element classes and their 
    862 names. You can use the method <method>element</method> 
    863 to get an element class with a certain name:</par> 
     865names. You can use the method <meth>element</meth> 
     866to get an element class with a certain name:</p> 
    864867<prog> 
    865868&gt;&gt;&gt; from ll.xist.ns import html 
     
    867870&lt;element class ll.xist.ns.html/div at 0x824363c&gt; 
    868871</prog> 
    869 <par>For processing instructions, entities and character references 
    870 similar methods are available.</par> 
    871 <par>The method <method>update</method> can be used to add 
     872<p>For processing instructions, entities and character references 
     873similar methods are available.</p> 
     874<p>The method <meth>update</meth> can be used to add 
    872875many element classes to a namespace at once, simply by passing 
    873876a dictionary with those classes (use <lit>vars()</lit> 
    874877to add everything that's defined inside your module). The method 
    875 <method>updatenew</method> does the same, but copies only those 
    876 attributes that don't exist in the namespace, <method>updateexisting</method> 
     878<meth>updatenew</meth> does the same, but copies only those 
     879attributes that don't exist in the namespace, <meth>updateexisting</meth> 
    877880copies only those that do exist. You can turn a namespace 
    878 into a module with <method>makemod</method>:</par> 
     881into a module with <meth>makemod</meth>:</p> 
    879882<prog> 
    880883from ll.xist import xsc 
     
    888891xmlns.makemod(vars()) 
    889892</prog> 
    890 <par>Put the above code into <filename>foo.py</filename> and 
    891 you can do the following:</par> 
     893<p>Put the above code into <filename>foo.py</filename> and 
     894you can do the following:</p> 
    892895<prog> 
    893896>>> import foo 
     
    897900</item> 
    898901 
    899 <item><function>getns</function> has been dropped, so you always 
     902<item><func>getns</func> has been dropped, so you always 
    900903have to pass in a <class>Namespace</class> class where a namespace 
    901904is required.</item> 
     
    907910is optional.</item> 
    908911 
    909 <item>The converter has a new property <function>node</function>. 
    910 <arg>node</arg> can't be passed to <method>conv</method> but 
    911 will be set to <self/> by <method>conv</method> automatically. 
     912<item>The converter has a new property <func>node</func>. 
     913<arg>node</arg> can't be passed to <meth>conv</meth> but 
     914will be set to <self/> by <meth>conv</meth> automatically. 
    912915This makes it possible to access the <z>document root</z> 
    913916during conversion.</item> 
     
    926929 
    927930<item><class>Frag</class> and <class>Element</class> now support 
    928 the methods <method>extend</method> and <method>__iadd__</method>.</item> 
    929  
    930 <item>For walking the tree the method <method>walk</method> has been completely 
    931 rewritten and a new method <method>visit</method> has been added. For 
     931the methods <meth>extend</meth> and <meth>__iadd__</meth>.</item> 
     932 
     933<item>For walking the tree the method <meth>walk</meth> has been completely 
     934rewritten and a new method <meth>visit</meth> has been added. For 
    932935more info see the docstrings.</item> 
    933936 
    934 <item><class>Node</class> now has two new methods <method>copy</method> 
    935 and <method>deepcopy</method> and supports the <module>copy</module> 
     937<item><class>Node</class> now has two new methods <meth>copy</meth> 
     938and <meth>deepcopy</meth> and supports the <mod>copy</mod> 
    936939module from the Python standard library.</item> 
    937940 
    938 <item>Calling <method>mapped</method> through <method>conv</method> has 
    939 been removed. You again have to call <method>mapped</method> directly 
     941<item>Calling <meth>mapped</meth> through <meth>conv</meth> has 
     942been removed. You again have to call <meth>mapped</meth> directly 
    940943and pass a node and a converter.</item> 
    941944 
    942945<item>The &html; handling of the <class>HTMLParser</class> has been improved 
    943 (it now uses code from <module>xml.sax.drivers2.drv_sgmlop_html</module> (which 
    944 is part of <link href="http://pyxml.sf.net">PyXML</link>)).</item> 
     946(it now uses code from <mod>xml.sax.drivers2.drv_sgmlop_html</mod> (which 
     947is part of <a href="http://pyxml.sf.net">PyXML</a>)).</item> 
    945948 
    946949<item>The core functionality found in the script <filename>dtd2xsc.py</filename> 
    947 has been moved to a class method <method>ll.xist.ns.xndl.fromdtd</method> in the 
    948 <module>ll.xist.ns.xndl</module> namespace.</item> 
     950has been moved to a class method <meth>ll.xist.ns.xndl.fromdtd</meth> in the 
     951<mod>ll.xist.ns.xndl</mod> namespace.</item> 
    949952 
    950953<item><class>ll.xist.parsers.ExpatParser</class> is now a real subclass 
     
    956959<item>Namespaces have been added for Zope's TAL and METAL specifications.</item> 
    957960 
    958 <item>A namespace has been added for <link href="http://www.w3.org/Style/XSL/">XSL-FO</link>.</item> 
    959 </ulist> 
    960 </section> 
    961  
    962  
    963 <section><title>Changes in 2.1.4 (released 06/13/2003)</title> 
    964 <ulist> 
     961<item>A namespace has been added for <a href="http://www.w3.org/Style/XSL/">XSL-FO</a>.</item> 
     962</ul> 
     963</section> 
     964 
     965 
     966<section><h>Changes in 2.1.4 (released 06/13/2003)</h> 
     967<ul> 
    965968<item>Remove the checks for attributes in attributes and 
    966969moved the publication code for the full element into a separate 
    967970method. This allows &jsp; tag library namespaces to simply 
    968 overwrite <method>publish</method> to publish the element 
     971overwrite <meth>publish</meth> to publish the element 
    969972even inside attributes. (This is the same fix as in release 1.5.10)</item> 
    970 </ulist> 
    971 </section> 
    972  
    973  
    974 <section><title>Changes in 2.1.3 (released 05/07/2003)</title> 
    975 <ulist> 
    976 <item>The methods <method>sorted</method>, <method>reversed</method> 
    977 and <method>shuffled</method> have been rewritten so they no longer 
     973</ul> 
     974</section> 
     975 
     976 
     977<section><h>Changes in 2.1.3 (released 05/07/2003)</h> 
     978<ul> 
     979<item>The methods <meth>sorted</meth>, <meth>reversed</meth> 
     980and <meth>shuffled</meth> have been rewritten so they no longer 
    978981use <lit>sys.maxint</lit>. This change fixes those methods for 
    97998264 bit platforms (reported by Giles Frances Hall)</item> 
    980 </ulist> 
    981 </section> 
    982  
    983  
    984 <section><title>Changes in 2.1.2 (released 02/27/2003)</title> 
    985 <ulist> 
     983</ul> 
     984</section> 
     985 
     986 
     987<section><h>Changes in 2.1.2 (released 02/27/2003)</h> 
     988<ul> 
    986989<item><class>ll.xist.ns.struts_config11.plug_in</class> now 
    987990allows content (as the &dtd; states). (This is the same fix 
    988991as in release 1.5.8.)</item> 
    989 </ulist> 
    990 </section> 
    991  
    992  
    993 <section><title>Changes in 2.1.1 (released 02/11/2003)</title> 
    994 <ulist> 
    995 <item>Added a few elements and attributes to <module>ll.xist.ns.doc</module>: 
     992</ul> 
     993</section> 
     994 
     995 
     996<section><h>Changes in 2.1.1 (released 02/11/2003)</h> 
     997<ul> 
     998<item>Added a few elements and attributes to <mod>ll.xist.ns.doc</mod>: 
    996999<class>username</class>, which is used for the name of a user account, 
    9971000<class>xref</class>, which is used for internal cross references and 
    9981001the attribute <lit>id</lit> for <class>section</class>, which specifies 
    9991002the target for an <class>xref</class>.</item> 
    1000 </ulist> 
    1001 </section> 
    1002  
    1003  
    1004 <section><title>Changes in 2.1 (released 12/09/2002)</title> 
    1005 <ulist> 
    1006 <item>Added a new namespace module <module>ll.xist.ns.xndl</module> 
     1003</ul> 
     1004</section> 
     1005 
     1006 
     1007<section><h>Changes in 2.1 (released 12/09/2002)</h> 
     1008<ul> 
     1009<item>Added a new namespace module <mod>ll.xist.ns.xndl</mod> 
    10071010that contains the <z>&xist; namespace definition language</z>, i.e. 
    10081011elements that describe an &xist; namespace and can be used by 
     
    10101013The first of these script is the &dtd; to namespace converter 
    10111014<filename>dtd2xsc.py</filename>.</item> 
    1012 <item>Added a new namespace module <module>ll.xist.ns.tld</module> 
     1015<item>Added a new namespace module <mod>ll.xist.ns.tld</mod> 
    10131016that contains the definition for Java Server Pages Tag Library 
    10141017descriptors and a script <filename>tld2xsc.py</filename> 
     
    10161019<lit>tld</lit> files.</item> 
    10171020<item><class>Attr</class> now supports the method 
    1018 <method>filtered</method>. This is used by <method>without</method> 
    1019 now. The arguments for <method>without</method> have changed, 
     1021<meth>filtered</meth>. This is used by <meth>without</meth> 
     1022now. The arguments for <meth>without</meth> have changed, 
    10201023because handling global attributes was too <z>magic</z>. 
    1021 A new method <method>with</method> has been added, with does 
    1022 the opposite of <method>without</method>, i.e. it removes all 
     1024A new method <meth>with</meth> has been added, with does 
     1025the opposite of <meth>without</meth>, i.e. it removes all 
    10231026attributes that are not specified as parameters.</item> 
    10241027<item>The Python name of each <class>Node</class> subclass 
    10251028is now available as the class attribute <lit>pyname</lit>.</item> 
    1026 <item>To continue the great renaming <method>withSep</method> 
    1027 has been renamed to <method>withsep</method>.</item> 
    1028 <item>The namespace name for the <module>ll.xist.ns.struts_html</module> 
     1029<item>To continue the great renaming <meth>withSep</meth> 
     1030has been renamed to <meth>withsep</meth>.</item> 
     1031<item>The namespace name for the <mod>ll.xist.ns.struts_html</mod> 
    10291032module has been fixed.</item> 
    10301033<item>The argument <arg>defaultEncoding</arg> for the various 
    10311034parsing functions has been renamed to <arg>encoding</arg>.</item> 
    1032 </ulist> 
    1033 </section> 
    1034  
    1035  
    1036 <section><title>Changes in 2.0.8 (released 11/20/2002)</title> 
    1037 <ulist> 
    1038 <item><function>ll.xist.ns.doc.getDoc</function> has been renamed 
    1039 to <function>getdoc</function>.</item> 
     1035</ul> 
     1036</section> 
     1037 
     1038 
     1039<section><h>Changes in 2.0.8 (released 11/20/2002)</h> 
     1040<ul> 
     1041<item><func>ll.xist.ns.doc.getDoc</func> has been renamed 
     1042to <func>getdoc</func>.</item> 
    10401043<item>The &css; parser was dropping the <lit>%</lit> from 
    10411044percentage values. This has been fixed.</item> 
    1042 </ulist> 
    1043 </section> 
    1044  
    1045  
    1046 <section><title>Changes in 2.0.7 (released 11/12/2002)</title> 
    1047 <ulist> 
    1048 <item><method>xsc.Element.__nonzero__</method> can no longer fall back 
    1049 to <method>xsc.Frag.__nonzero__</method>. 
     1045</ul> 
     1046</section> 
     1047 
     1048 
     1049<section><h>Changes in 2.0.7 (released 11/12/2002)</h> 
     1050<ul> 
     1051<item><meth>xsc.Element.__nonzero__</meth> can no longer fall back 
     1052to <meth>xsc.Frag.__nonzero__</meth>. 
    10501053(this is the same fix as in 1.5.7).</item> 
    1051 </ulist> 
    1052 </section> 
    1053  
    1054  
    1055 <section><title>Changes in 2.0.6 (released 11/11/2002)</title> 
    1056 <ulist> 
     1054</ul> 
     1055</section> 
     1056 
     1057 
     1058<section><h>Changes in 2.0.6 (released 11/11/2002)</h> 
     1059<ul> 
    10571060<item>Performance optimizations.</item> 
    1058 </ulist> 
    1059 </section> 
    1060  
    1061  
    1062 <section><title>Changes in 2.0.5 (released 11/11/2002)</title> 
    1063 <ulist> 
     1061</ul> 
     1062</section> 
     1063 
     1064 
     1065<section><h>Changes in 2.0.5 (released 11/11/2002)</h> 
     1066<ul> 
    10641067<item>Fixed a bug in <class>ll.xist.ns.specials.autoimg</class>: 
    10651068Attributes were not converted before the size check was done 
    10661069(this is the same fix as in 1.5.5).</item> 
    1067 </ulist> 
    1068 </section> 
    1069  
    1070  
    1071 <section><title>Changes in 2.0.4 (released 11/08/2002)</title> 
    1072 <ulist> 
     1070</ul> 
     1071</section> 
     1072 
     1073 
     1074<section><h>Changes in 2.0.4 (released 11/08/2002)</h> 
     1075<ul> 
    10731076<item>Fixed a regression bug in <class>ll.xist.ns.jsp.directive</class> 
    10741077and several documentation issues.</item> 
    1075 </ulist> 
    1076 </section> 
    1077  
    1078  
    1079 <section><title>Changes in 2.0.3 (released 10/30/2002)</title> 
    1080 <ulist> 
     1078</ul> 
     1079</section> 
     1080 
     1081 
     1082<section><h>Changes in 2.0.3 (released 10/30/2002)</h> 
     1083<ul> 
    10811084<item>Fixed a few bugs in <class>HTMLParser</class>.</item> 
    10821085<item>Added DocBook conversion for several elements 
    1083 in <module>ll.xist.ns.doc</module>.</item> 
     1086in <mod>ll.xist.ns.doc</mod>.</item> 
    10841087<item>Now the <filename>__init__.py</filename> file for the 
    1085 <module>ll</module> package is included.</item> 
    1086 </ulist> 
    1087 </section> 
    1088  
    1089  
    1090 <section><title>Changes in 2.0.2 (released 10/21/2002)</title> 
    1091 <ulist> 
    1092 <item>Fixed a bug in <method>Frag.__rmul__</method> (by 
    1093 reusing <method>__mul__</method>).</item> 
     1088<mod>ll</mod> package is included.</item> 
     1089</ul> 
     1090</section> 
     1091 
     1092 
     1093<section><h>Changes in 2.0.2 (released 10/21/2002)</h> 
     1094<ul> 
     1095<item>Fixed a bug in <meth>Frag.__rmul__</meth> (by 
     1096reusing <meth>__mul__</meth>).</item> 
    10941097<item>Fixed a bug with the backwards compatible prefix 
    10951098mapping: Defining element classes in <lit>exec</lit> processing 
     
    11001103functions uses one global shared <class>Prefixes</class> instances 
    11011104where all the namespaces that are newly defined will be registered too.</item> 
    1102 </ulist> 
    1103 </section> 
    1104  
    1105  
    1106 <section><title>Changes in 2.0.1 (released 10/17/2002)</title> 
    1107 <ulist> 
     1105</ul> 
     1106</section> 
     1107 
     1108 
     1109<section><h>Changes in 2.0.1 (released 10/17/2002)</h> 
     1110<ul> 
    11081111<item>Fixed <filename>xscmake.py</filename> by removing the 
    11091112prefix handling. <class>OldPrefixes</class> will always 
    11101113be used for parsing now.</item> 
    1111 </ulist> 
    1112 </section> 
    1113  
    1114  
    1115 <section><title>Changes in 2.0 (released 10/16/2002)</title> 
    1116 <ulist> 
     1114</ul> 
     1115</section> 
     1116 
     1117 
     1118<section><h>Changes in 2.0 (released 10/16/2002)</h> 
     1119<ul> 
    11171120<item>&xist; now requires at least Python 2.2.1.</item> 
    11181121<item>Attribute handling has been largely rewritten. Instead of 
     
    11391142for the <lit>xml</lit> and <lit>xlink</lit> namespaces 
    11401143have been added (and <class>ll.xist.xsc.XML</class> was 
    1141 moved to <module>ll.xist.ns.xml</module>).</item> 
    1142 <item>A new namespace module for &svg; 1.0 has been added: <module>ll.xist.ns.svg</module>.</item> 
    1143 <item>The &html; specific parts of <module>ll.xist.ns.specials</module> 
    1144 have been split off into a separate module <module>ll.xist.ns.htmlspecials</module>.</item> 
     1144moved to <mod>ll.xist.ns.xml</mod>).</item> 
     1145<item>A new namespace module for &svg; 1.0 has been added: <mod>ll.xist.ns.svg</mod>.</item> 
     1146<item>The &html; specific parts of <mod>ll.xist.ns.specials</mod> 
     1147have been split off into a separate module <mod>ll.xist.ns.htmlspecials</mod>.</item> 
    11451148<item>Comparison of attributes with strings has been removed. 
    1146 You have to use <method>__unicode__</method> or <method>__str__</method> 
     1149You have to use <meth>__unicode__</meth> or <meth>__str__</meth> 
    11471150now before comparing.</item> 
    11481151<item>The <class>HTMLParser</class> now removes unknown attributes 
     
    11541157<item>To give all nodes a chance to do something after they have been parsed 
    11551158(e.g. to prepend the base &url; for <class>URLAttr</class> nodes), the parser 
    1156 now calls the method <method>parsed</method> immediately after node creation. 
     1159now calls the method <meth>parsed</meth> immediately after node creation. 
    11571160This is used for the new class <class>StyleAttr</class>, which uses the 
    11581161<class>CSSTokenizer</class>, to prepend the base &url; to all &url;s 
     
    11601163<item>The pixel images have been moved to the directory <dirname>px</dirname> 
    11611164to make image &url;s shorter.</item> 
    1162 </ulist> 
    1163 </section> 
    1164  
    1165  
    1166 <section><title>Changes in 1.6.1 (released 08/25/2003)</title> 
    1167 <ulist> 
    1168 <item>Updated to work with newer versions of <module>ll.ansistyle</module>.</item> 
    1169 <item>Updated the namespaces <module>ll.xist.ns.struts_html</module> and 
    1170 <module>ll.xist.ns.struts_config11</module> to the state of Struts 1.1 final.</item> 
    1171 </ulist> 
    1172 </section> 
    1173  
    1174  
    1175 <section><title>Changes in 1.6 (released 07/02/2003)</title> 
    1176 <ulist> 
     1165</ul> 
     1166</section> 
     1167 
     1168 
     1169<section><h>Changes in 1.6.1 (released 08/25/2003)</h> 
     1170<ul> 
     1171<item>Updated to work with newer versions of <mod>ll.ansistyle</mod>.</item> 
     1172<item>Updated the namespaces <mod>ll.xist.ns.struts_html</mod> and 
     1173<mod>ll.xist.ns.struts_config11</mod> to the state of Struts 1.1 final.</item> 
     1174</ul> 
     1175</section> 
     1176 
     1177 
     1178<section><h>Changes in 1.6 (released 07/02/2003)</h> 
     1179<ul> 
    11771180<item>Removed the default value for the <lit>className</lit> attribute 
    11781181in <class>ll.xist.ns.struts_config11.action</class>.</item> 
    11791182<item>Added an attribute <lit>type</lit> to 
    11801183<class>ll.xist.ns.struts_config11.action_mapping</class>.</item> 
    1181 </ulist> 
    1182 </section> 
    1183  
    1184  
    1185 <section><title>Changes in 1.5.13 (released 07/01/2003)</title> 
    1186 <ulist> 
    1187 <item>Implemented <method>ll.xist.xsc.Namespace.__eq__</method>, 
     1184</ul> 
     1185</section> 
     1186 
     1187 
     1188<section><h>Changes in 1.5.13 (released 07/01/2003)</h> 
     1189<ul> 
     1190<item>Implemented <meth>ll.xist.xsc.Namespace.__eq__</meth>, 
    11881191so that replacing a namespace in the registry really works.</item> 
    11891192<item>Added an attribute <lit>target</lit> to <class>ll.xist.ns.html.area</class>.</item> 
    1190 </ulist> 
    1191 </section> 
    1192  
    1193  
    1194 <section><title>Changes in 1.5.12 (released 06/17/2003)</title> 
    1195 <ulist> 
    1196 <item>Fixed a bug in the new <module>ll.xist.ns.jsp</module>.</item> 
    1197 </ulist> 
    1198 </section> 
    1199  
    1200  
    1201 <section><title>Changes in 1.5.11 (released 06/13/2003)</title> 
    1202 <ulist> 
    1203 <item>Updated <module>ll.xist.ns.jsp</module> to &jsp; 1.2.</item> 
    1204 </ulist> 
    1205 </section> 
    1206  
    1207  
    1208 <section><title>Changes in 1.5.10 (released 06/13/2003)</title> 
    1209 <ulist> 
     1193</ul> 
     1194</section> 
     1195 
     1196 
     1197<section><h>Changes in 1.5.12 (released 06/17/2003)</h> 
     1198<ul> 
     1199<item>Fixed a bug in the new <mod>ll.xist.ns.jsp</mod>.</item> 
     1200</ul> 
     1201</section> 
     1202 
     1203 
     1204<section><h>Changes in 1.5.11 (released 06/13/2003)</h> 
     1205<ul> 
     1206<item>Updated <mod>ll.xist.ns.jsp</mod> to &jsp; 1.2.</item> 
     1207</ul> 
     1208</section> 
     1209 
     1210 
     1211<section><h>Changes in 1.5.10 (released 06/13/2003)</h> 
     1212<ul> 
    12101213<item>Remove the checks for attributes in attributes and 
    12111214moved the publication code for the full element into a separate 
    12121215method. This allows &jsp; tag library namespaces to simply 
    1213 overwrite <method>publish</method> to publish the element 
     1216overwrite <meth>publish</meth> to publish the element 
    12141217even inside attributes.</item> 
    1215 </ulist> 
    1216 </section> 
    1217  
    1218  
    1219 <section><title>Changes in 1.5.9 (released 04/30/2003)</title> 
    1220 <ulist> 
     1218</ul> 
     1219</section> 
     1220 
     1221 
     1222<section><h>Changes in 1.5.9 (released 04/30/2003)</h> 
     1223<ul> 
    12211224<item>Reregistering a namespace now properly overwrites 
    12221225the old version in <lit>xsc.namespaceRegistry</lit>.</item> 
    1223 </ulist> 
    1224 </section> 
    1225  
    1226  
    1227 <section><title>Changes in 1.5.8 (released 02/27/2003)</title> 
    1228 <ulist> 
     1226</ul> 
     1227</section> 
     1228 
     1229 
     1230<section><h>Changes in 1.5.8 (released 02/27/2003)</h> 
     1231<ul> 
    12291232<item><class>ll.xist.ns.struts_config11.plug_in</class> now 
    12301233allows content (as the &dtd; states).</item> 
    1231 </ulist> 
    1232 </section> 
    1233  
    1234  
    1235 <section><title>Changes in 1.5.7 (released 11/12/2002)</title> 
    1236 <ulist> 
    1237 <item><method>xsc.Element.__nonzero__</method> can no longer fall back 
    1238 to <method>xsc.Frag.__nonzero__</method>.</item> 
    1239 </ulist> 
    1240 </section> 
    1241  
    1242  
    1243 <section><title>Changes in 1.5.6 (released 11/11/2002)</title> 
    1244 <ulist> 
     1234</ul> 
     1235</section> 
     1236 
     1237 
     1238<section><h>Changes in 1.5.7 (released 11/12/2002)</h> 
     1239<ul> 
     1240<item><meth>xsc.Element.__nonzero__</meth> can no longer fall back 
     1241to <meth>xsc.Frag.__nonzero__</meth>.</item> 
     1242</ul> 
     1243</section> 
     1244 
     1245 
     1246<section><h>Changes in 1.5.6 (released 11/11/2002)</h> 
     1247<ul> 
    12451248<item>Performance optimizations.</item> 
    1246 </ulist> 
    1247 </section> 
    1248  
    1249  
    1250 <section><title>Changes in 1.5.5 (released 11/11/2002)</title> 
    1251 <ulist> 
     1249</ul> 
     1250</section> 
     1251 
     1252 
     1253<section><h>Changes in 1.5.5 (released 11/11/2002)</h> 
     1254<ul> 
    12521255<item>Fixed a bug in <class>ll.xist.ns.specials.autoimg</class>: 
    12531256Attributes were not converted before the size check was done.</item> 
    1254 </ulist> 
    1255 </section> 
    1256  
    1257  
    1258 <section><title>Changes in 1.5.4 (released 09/30/2002)</title> 
    1259 <ulist> 
     1257</ul> 
     1258</section> 
     1259 
     1260 
     1261<section><h>Changes in 1.5.4 (released 09/30/2002)</h> 
     1262<ul> 
    12601263<item><filename>xscmake.py</filename> now tries to strip off 
    12611264a trailing <lit>xsc</lit> from the filename before it falls back 
    12621265to the extension <lit>html</lit> (The builtin extension mapping 
    12631266is still tried first).</item> 
    1264 </ulist> 
    1265 </section> 
    1266  
    1267  
    1268 <section><title>Changes in 1.5.3 (released 09/25/2002)</title> 
    1269 <ulist> 
     1267</ul> 
     1268</section> 
     1269 
     1270 
     1271<section><h>Changes in 1.5.3 (released 09/25/2002)</h> 
     1272<ul> 
    12701273<item>Added new processing instruction class <class>ll.xist.ns.php.expression</class> 
    12711274that generates a &php; <lit>print</lit> statement from its content.</item> 
    1272 </ulist> 
    1273 </section> 
    1274  
    1275  
    1276 <section><title>Changes in 1.5.2 (released 09/19/2002)</title> 
    1277 <ulist> 
     1275</ul> 
     1276</section> 
     1277 
     1278 
     1279<section><h>Changes in 1.5.2 (released 09/19/2002)</h> 
     1280<ul> 
    12781281<item>Removed the <lit>value</lit> magic from 
    12791282<class>ll.xist.ns.form.checkbox</class> as this 
    12801283conflicted with dynamic <lit>value</lit> values.</item> 
    1281 </ulist> 
    1282 </section> 
    1283  
    1284  
    1285 <section><title>Changes in 1.5.1 (released 09/17/2002)</title> 
    1286 <ulist> 
     1284</ul> 
     1285</section> 
     1286 
     1287 
     1288<section><h>Changes in 1.5.1 (released 09/17/2002)</h> 
     1289<ul> 
    12871290<item>Comparison of attributes with strings has been removed. 
    1288 You have to use <method>__unicode__</method> or <method>__str__</method> 
     1291You have to use <meth>__unicode__</meth> or <meth>__str__</meth> 
    12891292instead.</item> 
    12901293<item>The <class>HTMLParser</class> now removes unknown attributes 
     
    12961299<item>To give all nodes a chance to do something after they have been parsed 
    12971300(e.g. to prepend the base URL for <class>URLAttr</class> nodes), the parser 
    1298 now calls the method <method>parsed()</method> immediately after node creation. 
     1301now calls the method <meth>parsed()</meth> immediately after node creation. 
    12991302This is used for the new class <class>StyleAttr</class>, which uses the 
    13001303<class>CSSTokenizer</class>, to prepend the base url to all urls found in 
     
    13081311<item>To give all nodes a chance to do something after they have been parsed 
    13091312(e.g. to prepend the base &url; for <class>URLAttr</class> nodes), the parser 
    1310 now calls the method <method>parsed</method> immediately after node creation. 
     1313now calls the method <meth>parsed</meth> immediately after node creation. 
    13111314This is used for the new class <class>StyleAttr</class>, which uses the 
    13121315<class>CSSTokenizer</class>, to prepend to base &url; to all &url;s 
    13131316found in a style attribute.</item> 
    1314 </ulist> 
    1315 </section> 
    1316  
    1317  
    1318 <section><title>Changes in 1.4.3 (released 04/29/2002)</title> 
    1319 <ulist> 
    1320 <item>New namespace module <module>xist.ns.struts_config11</module> 
    1321 allows to parse and modify <link href="http://jakarta.apache.org/struts/">Struts</link> 
     1317</ul> 
     1318</section> 
     1319 
     1320 
     1321<section><h>Changes in 1.4.3 (released 04/29/2002)</h> 
     1322<ul> 
     1323<item>New namespace module <mod>xist.ns.struts_config11</mod> 
     1324allows to parse and modify <a href="http://jakarta.apache.org/struts/">Struts</a> 
    13221325configuration files conforming to the 
    1323 <link href="http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">Struts 1.1 DTD</link>. 
     1326<a href="http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">Struts 1.1 DTD</a>. 
    13241327</item> 
    1325 </ulist> 
    1326 </section> 
    1327  
    1328  
    1329 <section><title>Changes in 1.4.2 (released 03/22/2002)</title> 
    1330 <ulist> 
     1328</ul> 
     1329</section> 
     1330 
     1331 
     1332<section><h>Changes in 1.4.2 (released 03/22/2002)</h> 
     1333<ul> 
    13311334<item>Updated <filename>xscmake.py</filename> to be compatible with the new 
    1332 <module>url</module> module.</item> 
     1335<mod>url</mod> module.</item> 
    13331336<item><class>xist.ns.jsp.directive_page</class> now automatically sets the 
    13341337<lit>contentType</lit> on publishing.</item> 
    1335 </ulist> 
    1336 </section> 
    1337  
    1338  
    1339 <section><title>Changes in 1.4.1 (released 03/21/2002)</title> 
    1340 <ulist> 
     1338</ul> 
     1339</section> 
     1340 
     1341 
     1342<section><h>Changes in 1.4.1 (released 03/21/2002)</h> 
     1343<ul> 
    13411344<item>Removed <class>TidyURLInputSource</class>. Now it's possible 
    1342 to pass a <lit>tidy</lit> flag to the remaining functions <function>parseString</function>, 
    1343 <function>parseFile</function> and <function>parseURL</function> to specify whether 
     1345to pass a <lit>tidy</lit> flag to the remaining functions <func>parseString</func>, 
     1346<func>parseFile</func> and <func>parseURL</func> to specify whether 
    13441347the source should be tidied.</item> 
    13451348<item>To prevent an element from being registered in a <class>Namespace</class> 
    13461349the class attribute <lit>register</lit> can be used now. This makes 
    13471350it possible to have a name for the element even when it's not registered.</item> 
    1348 <item><module>xist.ns.form</module> elements now have all the attributes that the 
    1349 corresponding elements from <module>xist.ns.html</module> have.</item> 
    1350 <item>Removed the old <module>xist.url</module> from the Windows distribution.</item> 
    1351 </ulist> 
    1352 </section> 
    1353  
    1354  
    1355 <section><title>Changes in 1.4 (released 03/18/2002)</title> 
    1356 <ulist> 
     1351<item><mod>xist.ns.form</mod> elements now have all the attributes that the 
     1352corresponding elements from <mod>xist.ns.html</mod> have.</item> 
     1353<item>Removed the old <mod>xist.url</mod> from the Windows distribution.</item> 
     1354</ul> 
     1355</section> 
     1356 
     1357 
     1358<section><h>Changes in 1.4 (released 03/18/2002)</h> 
     1359<ul> 
    13571360<item>Reimplemented &url; handling again. Now the new global 
    1358 module <module>url</module> is used for that.</item> 
    1359 </ulist> 
    1360 </section> 
    1361  
    1362  
    1363 <section><title>Changes in 1.3.1 (released 03/14/2002)</title> 
    1364 <ulist> 
    1365 <item>Added a method <method>pretty</method> to <class>Node</class> 
     1361module <mod>url</mod> is used for that.</item> 
     1362</ul> 
     1363</section> 
     1364 
     1365 
     1366<section><h>Changes in 1.3.1 (released 03/14/2002)</h> 
     1367<ul> 
     1368<item>Added a method <meth>pretty</meth> to <class>Node</class> 
    13661369for generating a pretty printable version of the node.</item> 
    13671370<item><lit>xsc.Node.name</lit> no longer is a class method, but a 
    13681371class attribute, that will be set at class instantiation time 
    13691372by the meta class.</item> 
    1370 </ulist> 
    1371 </section> 
    1372  
    1373  
    1374 <section><title>Changes in 1.3 (released 02/12/2002)</title> 
    1375 <ulist> 
     1373</ul> 
     1374</section> 
     1375 
     1376 
     1377<section><h>Changes in 1.3 (released 02/12/2002)</h> 
     1378<ul> 
    13761379<item>Ported to Python 2.2. <class>Node</class> is now derived from 
    13771380<class>object</class>, <class>Frag</class> from <class>list</class> and 
     
    13801383have been adapted to work with <class>Attrs</class>. 
    13811384In addition to the usual dictionary methods and operators <class>Attrs</class> 
    1382 has a method <method>without</method> that returns a copy of the 
     1385has a method <meth>without</meth> that returns a copy of the 
    13831386<class>Attrs</class> instance with some specified attributes removed.</item> 
    1384 <item>All the node classes now have a new method <method>walk</method> that generates 
     1387<item>All the node classes now have a new method <meth>walk</meth> that generates 
    13851388all nodes in the tree using the new generator feature of Python 2.2.</item> 
    1386 <item>Also a new method <method>walkPath</method> has been added that works the 
    1387 same as <method>walk</method> but yields the complete path to each node 
     1389<item>Also a new method <meth>walkPath</meth> has been added that works the 
     1390same as <meth>walk</meth> but yields the complete path to each node 
    13881391as a list.</item> 
    1389 <item>Added a class <class>block</class> to <module>xist.ns.jsp</module>. 
     1392<item>Added a class <class>block</class> to <mod>xist.ns.jsp</mod>. 
    13901393The content of the <class>block</class> instance will simply be enclosed 
    1391 in a <lit>{}</lit> block. <module>xist.ns.php</module> got such 
     1394in a <lit>{}</lit> block. <mod>xist.ns.php</mod> got such 
    13921395a class too.</item> 
    1393 <item>Added a new module <module>xist.ns.ihtml</module> for 
     1396<item>Added a new module <mod>xist.ns.ihtml</mod> for 
    13941397i-mode &html;.</item> 
    1395 <item>Added new modules <module>xist.ns.css</module> and 
    1396 <module>xist.ns.cssspecials</module> for generating &css;.</item> 
     1398<item>Added new modules <mod>xist.ns.css</mod> and 
     1399<mod>xist.ns.cssspecials</mod> for generating &css;.</item> 
    13971400<item>Now the various attributes of the <class>Converter</class> object 
    13981401are collected in a <class>ConverterState</class> object and it's possible 
    13991402to push and pop those states, i.e. it's now easy to temporarily modify a 
    1400 converter object during a <method>convert</method> call and revert back 
     1403converter object during a <meth>convert</meth> call and revert back 
    14011404to a previous state afterwards.</item> 
    1402 <item><function>parseURL</function> and <function>parseTidyURL</function> 
     1405<item><func>parseURL</func> and <func>parseTidyURL</func> 
    14031406now have an additional parameter <lit>headers</lit> which is a list of 
    14041407string pairs specifying additional headers to be passed in with the 
    14051408request.</item> 
    1406 <item><function>parseString</function> has an additional parameter 
     1409<item><func>parseString</func> has an additional parameter 
    14071410<lit>systemId</lit> which will be the system id of the 
    14081411<class>InputSource</class>.</item> 
     
    14101413source files so now the distribution can rebuild ifself.</item> 
    14111414<item>Various other small bugfixes and enhancements.</item> 
    1412 </ulist> 
    1413 </section> 
    1414  
    1415  
    1416 <section><title>Changes in 1.2.5 (released 12/03/2001)</title> 
    1417 <ulist> 
     1415</ul> 
     1416</section> 
     1417 
     1418 
     1419<section><h>Changes in 1.2.5 (released 12/03/2001)</h> 
     1420<ul> 
    14181421<item>Added a new element <class>contentscripttype</class> to 
    1419 <module>xist.ns.meta</module> that generates a 
     1422<mod>xist.ns.meta</mod> that generates a 
    14201423<lit>&lt;meta http-equiv="Content-Script-Type" ...&gt;</lit> 
    14211424element.</item> 
    1422 <item><function>xist.ns.doc.explain</function> now generates anchor elements 
     1425<item><func>xist.ns.doc.explain</func> now generates anchor elements 
    14231426for the class, function and method description, so now the 
    14241427links on the &xist; webpages work.</item> 
     
    14301433<item>Added the attributes <lit>type</lit> and <lit>key</lit> 
    14311434to <class>xist.ns.struts_config.data_source</class>.</item> 
    1432 </ulist> 
    1433 </section> 
    1434  
    1435  
    1436 <section><title>Changes in 1.2.4 (released 11/23/2001)</title> 
    1437 <ulist> 
     1435</ul> 
     1436</section> 
     1437 
     1438 
     1439<section><h>Changes in 1.2.4 (released 11/23/2001)</h> 
     1440<ul> 
    14381441<item>Added the deprecated attributes <lit>start</lit> to 
    14391442<class>xist.ns.html.ol</class> and <lit>value</lit> to 
    14401443<class>xist.ns.html.li</class>.</item> 
    1441 </ulist> 
    1442 </section> 
    1443  
    1444  
    1445 <section><title>Changes in 1.2.3 (released 11/22/2001)</title> 
    1446 <ulist> 
    1447 <item>Added missing <method>asPlainString</method> methods to 
     1444</ul> 
     1445</section> 
     1446 
     1447 
     1448<section><h>Changes in 1.2.3 (released 11/22/2001)</h> 
     1449<ul> 
     1450<item>Added missing <meth>asPlainString</meth> methods to 
    14481451<class>Comment</class> and <class>DocType</class>.</item> 
    1449 </ulist> 
    1450 </section> 
    1451  
    1452  
    1453 <section><title>Changes in 1.2.2 (released 11/16/2001)</title> 
    1454 <ulist> 
    1455 <item><method>xist.url.URL.fileSize</method> and <method>xist.url.URL.imageSize</method> 
     1452</ul> 
     1453</section> 
     1454 
     1455 
     1456<section><h>Changes in 1.2.2 (released 11/16/2001)</h> 
     1457<ul> 
     1458<item><meth>xist.url.URL.fileSize</meth> and <meth>xist.url.URL.imageSize</meth> 
    14561459now use the warning framework to report errors.</item> 
    14571460<item>There is a new presenter named <class>CodePresenter</class> that dumps the 
     
    14591462<item>The filenames of the pixel images used by <class>xist.ns.specials.pixel</class> 
    14601463have changed. These images are now included.</item> 
    1461 </ulist> 
    1462 </section> 
    1463  
    1464  
    1465 <section><title>Changes in 1.2.1 (released 10/08/2001)</title> 
    1466 <ulist> 
     1464</ul> 
     1465</section> 
     1466 
     1467 
     1468<section><h>Changes in 1.2.1 (released 10/08/2001)</h> 
     1469<ul> 
    14671470<item>URLs that are completely dynamic will now be left in peace when parsing 
    14681471or publishing.</item> 
    1469 </ulist> 
    1470 </section> 
    1471  
    1472  
    1473 <section><title>Changes in 1.2 (released 10/03/2001)</title> 
    1474 <ulist> 
    1475 <item><par><class>xist.ns.meta.keywords</class> 
     1472</ul> 
     1473</section> 
     1474 
     1475 
     1476<section><h>Changes in 1.2 (released 10/03/2001)</h> 
     1477<ul> 
     1478<item><p><class>xist.ns.meta.keywords</class> 
    14761479and <class>xist.ns.meta.description</class> 
    1477 no longer call <method>asPlainString</method> 
    1478 on their content. This makes it possible to e.g. generate the keywords via &jsp;:</par> 
     1480no longer call <meth>asPlainString</meth> 
     1481on their content. This makes it possible to e.g. generate the keywords via &jsp;:</p> 
    14791482<example> 
    14801483<prog> 
     
    14971500experimental eGenix mx Extension package, which includes a Python 
    14981501port of <app>tidy</app>.</item> 
    1499 <item><method>__repr__</method> now uses the new class <class>presenters.PlainPresenter</class> 
    1500 which gives a little more info than the default <method>__repr__</method>.</item> 
     1502<item><meth>__repr__</meth> now uses the new class <class>presenters.PlainPresenter</class> 
     1503which gives a little more info than the default <meth>__repr__</meth>.</item> 
    15011504<item>URL handling has been changed again. Upto now, <class>URLAttr</class> had 
    15021505an additional instance attribute <lit>base</lit>, which was the <z>base</z> file/URL 
     
    15041507into the URL. You can pass the base URL to all the parsing functions. Similar to 
    15051508that when publishing you can specify a base URL. All URLs in the tree will be 
    1506 output relative to this base URL. Joining URLs is now done via <method>__div__</method> 
    1507 and no longer via <method>__add__</method>. This makes it more consistent with 
    1508 <module>fileutils</module>. The plan is to make URLs string like immutable objects 
     1509output relative to this base URL. Joining URLs is now done via <meth>__div__</meth> 
     1510and no longer via <meth>__add__</meth>. This makes it more consistent with 
     1511<mod>fileutils</mod>. The plan is to make URLs string like immutable objects 
    15091512and to merge them with <class>fileutils.Filename</class>.</item> 
    15101513<item><class>xist.ns.specials.php</class> has been moved to its own 
    1511 module (<module>xist.ns.php</module>). This module provided additional 
    1512 convenience processing instructions (just like <module>xist.ns.jsp</module> 
     1514module (<mod>xist.ns.php</mod>). This module provided additional 
     1515convenience processing instructions (just like <mod>xist.ns.jsp</mod> 
    15131516does).</item> 
    1514 </ulist> 
    1515 </section> 
    1516  
    1517  
    1518 <section><title>Changes in 1.1.3 (released 09/17/2001)</title> 
    1519 <ulist> 
     1517</ul> 
     1518</section> 
     1519 
     1520 
     1521<section><h>Changes in 1.1.3 (released 09/17/2001)</h> 
     1522<ul> 
    15201523<item>The global namespace registry now keeps a sequential list of all registered 
    15211524namespaces, which will be used by the parser when searching for names. This 
    15221525gives a predictable search order even without using <class>Namespaces</class> 
    1523 and its <method>pushNamespace</method> method: modules imported last will be searched 
     1526and its <meth>pushNamespace</meth> method: modules imported last will be searched 
    15241527first.</item> 
    15251528<item>Processing instructions are now allowed inside attributes when 
    15261529publishing.</item> 
    1527 <item><module>xist.ns.docbooklite</module> has been renamed to <module>xist.ns.doc</module>. 
     1530<item><mod>xist.ns.docbooklite</mod> has been renamed to <mod>xist.ns.doc</mod>. 
    15281531It can now generate &html; and Docbook output and has improved a lot. The &xist; web pages 
    15291532now use this for automatic documentation generation. The doc example has been removed.</item> 
    1530 <item><class>xist.url.URL</class> now has a new method <method>info</method> that returns the headers 
     1533<item><class>xist.url.URL</class> now has a new method <meth>info</meth> that returns the headers 
    15311534for the file/URL.</item> 
    1532 <item><class>xist.url.URL</class> now has a methods <method>fileSize</method> and <method>imageSize</method> 
     1535<item><class>xist.url.URL</class> now has a methods <meth>fileSize</meth> and <meth>imageSize</meth> 
    15331536too.</item> 
    15341537<item><class>xist.ns.jsp.directive_page</class> now has new attribute <lit>session</lit>.</item> 
    1535 </ulist> 
    1536 </section> 
    1537  
    1538  
    1539 <section><title>Changes in 1.1.2 (released 08/21/2001)</title> 
    1540 <ulist> 
    1541 <item><method>__repr__</method> now uses the new class <class>presenters.PlainPresenter</class> 
    1542 which gives a little more info than the default <method>__repr__</method>.</item> 
    1543 </ulist> 
    1544 </section> 
    1545  
    1546  
    1547 <section><title>Changes in 1.1.1 (released 08/01/2001)</title> 
    1548 <ulist> 
    1549 <item>Small bugfix in <function>presenters.strProcInst</function></item> 
     1538</ul> 
     1539</section> 
     1540 
     1541 
     1542<section><h>Changes in 1.1.2 (released 08/21/2001)</h> 
     1543<ul> 
     1544<item><meth>__repr__</meth> now uses the new class <class>presenters.PlainPresenter</class> 
     1545which gives a little more info than the default <meth>__repr__</meth>.</item> 
     1546</ul> 
     1547</section> 
     1548 
     1549 
     1550<section><h>Changes in 1.1.1 (released 08/01/2001)</h> 
     1551<ul> 
     1552<item>Small bugfix in <func>presenters.strProcInst</func></item> 
    15501553<item>fixed <class>xist.ns.struts_html.option</class> to allow content</item> 
    1551 </ulist> 
    1552 </section> 
    1553  
    1554  
    1555 <section><title>Changes in 1.1 (released 07/19/2001)</title> 
    1556 <ulist> 
     1554</ul> 
     1555</section> 
     1556 
     1557 
     1558<section><h>Changes in 1.1 (released 07/19/2001)</h> 
     1559<ul> 
    15571560<item>Sequences in constructor arguments for <class>Frag</class> and 
    15581561<class>Element</class> are again expanded and it's again possible 
    15591562to pass dictionaries in an <class>Element</class> constructor to 
    15601563specify attributes. As sequences are always unpacked, the method 
    1561 <method>extend</method> is gone. This works for <method>append</method> 
    1562 and <method>insert</method> too.</item> 
    1563  
    1564 <item><par><class>Node</class> and <class>Frag</class> implement 
    1565 <method>__mul__</method> and <method>__rmul__</method>, so you can do stuff like:</par> 
     1564<meth>extend</meth> is gone. This works for <meth>append</meth> 
     1565and <meth>insert</meth> too.</item> 
     1566 
     1567<item><p><class>Node</class> and <class>Frag</class> implement 
     1568<meth>__mul__</meth> and <meth>__rmul__</meth>, so you can do stuff like:</p> 
    15661569<prog> 
    15671570html.br()*5 
    15681571</prog> 
    1569 <par>This returns a <class>Frag</class> with five times to same node.</par></item> 
    1570  
    1571 <item><par>Arguments for the converter constructor can be passed to 
    1572 <method>xist.xsc.Node.conv</method> now, so it's possible to do stuff like this:</par> 
     1572<p>This returns a <class>Frag</class> with five times to same node.</p></item> 
     1573 
     1574<item><p>Arguments for the converter constructor can be passed to 
     1575<meth>xist.xsc.Node.conv</meth> now, so it's possible to do stuff like this:</p> 
    15731576<prog> 
    15741577from xist.ns import code 
     
    15761579    .conv(lang="en").asBytes() 
    15771580</prog> 
    1578 <par>which will print <lit>en</lit>.</par></item> 
     1581<p>which will print <lit>en</lit>.</p></item> 
    15791582<item>The option <arg>XHTML</arg> for the publishers has been changed 
    15801583to lowercase.</item> 
     
    15821585<lit>lang</lit> and <lit>xml:lang</lit> attribute when the 
    15831586converter has a language set.</item> 
    1584 </ulist> 
    1585 </section> 
    1586  
    1587  
    1588 <section><title>Changes in 1.0 (released 06/18/2001)</title> 
    1589 <ulist> 
     1587</ul> 
     1588</section> 
     1589 
     1590 
     1591<section><h>Changes in 1.0 (released 06/18/2001)</h> 
     1592<ul> 
    15901593<item>New module for &wml; 1.3.</item> 
    15911594 
     
    16041607<lit>&amp;quot;</lit> inside attributes.</item> 
    16051608 
    1606 <item>All the <method>asHTML</method> methods now have an additional argument 
     1609<item>All the <meth>asHTML</meth> methods now have an additional argument 
    16071610<arg>converter</arg>. This makes it possible 
    16081611to implement different processing modes or stages 
    16091612for new elements. All currently implemented elements and 
    16101613entities ignore this argument, but pass it on 
    1611 in the call to their childrens' <method>asHTML</method> method. 
    1612 As the name <method>asHTML</method> no longer makes sense, <method>asHTML</method> 
    1613 has been renamed to <method>convert</method>.</item> 
     1614in the call to their childrens' <meth>asHTML</meth> method. 
     1615As the name <meth>asHTML</meth> no longer makes sense, <meth>asHTML</meth> 
     1616has been renamed to <meth>convert</meth>.</item> 
    16141617 
    16151618<item>There is now a tool <filename>dtd2xsc.py</filename> in the 
     
    16191622 
    16201623<item>New preliminary module for DocBook 4.12. 
    1621 (Incomplete: <method>convert</method> methods and Unicode character 
     1624(Incomplete: <meth>convert</meth> methods and Unicode character 
    16221625entities are missing; any volunteers for implementing 375 classes?)</item> 
    16231626 
    16241627<item>New module <filename>ruby.py</filename> that implements the 
    1625 <link href="http://www.w3.org/TR/ruby/xhtml11-ruby-1.mod">W3C Ruby draft</link>. 
     1628<a href="http://www.w3.org/TR/ruby/xhtml11-ruby-1.mod">W3C Ruby draft</a>. 
    16261629</item> 
    16271630 
    16281631<item><filename>sql.py</filename> has been removed from &xist;, but is available 
    1629 as a <link href="root:sql/index.html">separate module</link>.</item> 
     1632as a <a href="root:sql/index.html">separate module</a>.</item> 
    16301633 
    16311634<item>The parsing interface has been changed. Parsing is now done 
    1632 with the functions <function>parseFile</function>, <function>parseString</function>, 
    1633 <function>parseURL</function> and <function>parseTidyURL</function> in the module 
    1634 <module>parsers</module>. It's now possible to specify which parser should 
     1635with the functions <func>parseFile</func>, <func>parseString</func>, 
     1636<func>parseURL</func> and <func>parseTidyURL</func> in the module 
     1637<mod>parsers</mod>. It's now possible to specify which parser should 
    16351638be used for parsing by passing a SAX2 parser instance to any of 
    16361639these functions. &xist; now includes a rudimentary SAX2 driver 
     
    16461649 
    16471650<item>All the modules that provide new elements and entitites 
    1648 have been moved to a subpackage <module>ns</module>.</item> 
     1651have been moved to a subpackage <mod>ns</mod>.</item> 
    16491652 
    16501653<item><class>Frag</class> and <class>Element</class> 
    1651 now have new methods <method>sorted</method>, 
    1652 <method>reversed</method>, <method>filtered</method> and 
    1653 <method>shuffled</method> that return sorted, reversed, filtered 
     1654now have new methods <meth>sorted</meth>, 
     1655<meth>reversed</meth>, <meth>filtered</meth> and 
     1656<meth>shuffled</meth> that return sorted, reversed, filtered 
    16541657and shuffled versions of the <class>Frag</class>/<class>Element</class> 
    16551658object.</item> 
     
    16571660<item>New namespace modules <filename>ns/jsp.py</filename> and 
    16581661<filename>ns/struts_html.py</filename> have been added that allow you to 
    1659 use <link href="http://java.sun.com/products/jsp/">&jsp;</link> and 
    1660 <link href="http://jakarta.apache.org/struts/">Struts</link> tags with &xist;.</item> 
    1661  
    1662 <item>A new method <method>asText</method> was added, that returns 
     1662use <a href="http://java.sun.com/products/jsp/">&jsp;</a> and 
     1663<a href="http://jakarta.apache.org/struts/">Struts</a> tags with &xist;.</item> 
     1664 
     1665<item>A new method <meth>asText</meth> was added, that returns 
    16631666the node as a formatted plain &ascii; text (this requires that 
    16641667<app moreinfo="http://w3m.sf.net/">w3m</app> 
     
    16781681and <lit>expat</lit>.</item> 
    16791682 
    1680 <item><par><filename>xscmake.py</filename> has a new option <option>-n</option>/<option>--namespace</option> 
     1683<item><p><filename>xscmake.py</filename> has a new option <option>-n</option>/<option>--namespace</option> 
    16811684that can be used for appending <class>Namespace</class> 
    1682 objects to the <class>Namespaces</class> object used by <filename>xscmake.py</filename>.</par> 
     1685objects to the <class>Namespaces</class> object used by <filename>xscmake.py</filename>.</p> 
    16831686<example> 
    1684 <title>Using the --namespace option</title> 
     1687<h>Using the --namespace option</h> 
    16851688<prog> 
    16861689xscmake.py -n html -n spam eggs.xsc 
    16871690</prog> 
    16881691</example> 
    1689 <par>With this call the parser will find element classes from the 
     1692<p>With this call the parser will find element classes from the 
    16901693module with the prefix name <lit>spam</lit> before those 
    1691 from <lit>html</lit> and those before anything else.</par></item> 
     1694from <lit>html</lit> and those before anything else.</p></item> 
    16921695 
    16931696<item><class>xist.url.URL</class> no longer has an attribute 
     
    17011704 
    17021705<item><class>Frag</class> and <class>Element</class> 
    1703 now have a new method <method>mapped</method>, 
     1706now have a new method <meth>mapped</meth>, 
    17041707that recursively maps the nodes through a function. This is like 
    1705 <method>convert</method> but via an external function.</item> 
    1706  
    1707 <item><par>Attribute handling has been improved thanks to a suggestion 
    1708 by Hartmut Goebel: <method>Element.__getitem__</method> now 
     1708<meth>convert</meth> but via an external function.</item> 
     1709 
     1710<item><p>Attribute handling has been improved thanks to a suggestion 
     1711by Hartmut Goebel: <meth>Element.__getitem__</meth> now 
    17091712always works as long as the attribute name is legal. If the attribute 
    17101713is not set, an empty attribute will be returned. All empty attributes 
    1711 will be considered as being not set and so <method>hasAttr</method> 
    1712 returns <lit>0</lit> for them, and <method>publish</method> doesn't 
    1713 publish them. This simplifies several very common cases:</par> 
    1714 <ulist> 
     1714will be considered as being not set and so <meth>hasAttr</meth> 
     1715returns <lit>0</lit> for them, and <meth>publish</meth> doesn't 
     1716publish them. This simplifies several very common cases:</p> 
     1717<ul> 
    17151718<item>Copying an attribute from one element to another works regardless 
    17161719of whether the attribute is set or not;</item> 
     
    17191722<lit>if element.hasAttr("attrname")</lit> (which still 
    17201723works, and should be a little faster);</item> 
    1721 <item><par>When you construct a &dom; tree and the presence or absence 
     1724<item><p>When you construct a &dom; tree and the presence or absence 
    17221725of an attribute is tied to a condition, you can construct the attribute 
    1723 in advance and use it afterwards in the tree construction:</par> 
     1726in advance and use it afterwards in the tree construction:</p> 
    17241727<prog> 
    17251728if <rep>condition</rep>: 
     
    17291732node = html.div("spam", align=align) 
    17301733</prog> 
    1731 <par>So, when the <lit><rep>condition</rep></lit> is false, 
    1732 the node will not have the attribute <lit>align</lit> set.</par></item> 
    1733 </ulist> 
     1734<p>So, when the <lit><rep>condition</rep></lit> is false, 
     1735the node will not have the attribute <lit>align</lit> set.</p></item> 
     1736</ul> 
    17341737</item> 
    1735 <item><par><class>xist.ns.cond.If</class> (and <class>xist.ns.cond.ElIf</class>) 
     1738<item><p><class>xist.ns.cond.If</class> (and <class>xist.ns.cond.ElIf</class>) 
    17361739can now be used to test for attributes of the converter. I.e. it's possible to 
    1737 write the following &xml;:</par> 
     1740write the following &xml;:</p> 
    17381741<prog> 
    17391742&lt;if lang="en"&gt;Title 
     
    17451748There are no more path markers. To specify an URL that is relative to the 
    17461749current directory use the scheme <lit>root</lit> (e.g. <lit>root:main.css</lit>).</item> 
    1747 </ulist> 
    1748 </section> 
    1749  
    1750  
    1751 <section><title>Changes in 0.4.7 (released 11/24/2000)</title> 
    1752 <ulist> 
     1750</ul> 
     1751</section> 
     1752 
     1753 
     1754<section><h>Changes in 0.4.7 (released 11/24/2000)</h> 
     1755<ul> 
    17531756<item>Fixed a bug in the entity handling.</item> 
    17541757 
    17551758<item>Added a few deprecated elements and attributes to 
    1756 the <module>html</module> module.</item> 
     1759the <mod>html</mod> module.</item> 
    17571760 
    17581761<item>Improved the publishing of attributes. Now all attribute 
     
    17611764name will be used for <lit>XHTML==1</lit> or <lit>XHTML==2</lit>.</item> 
    17621765 
    1763 <item><method>Element.compact</method> now works (better) ;).</item> 
     1766<item><meth>Element.compact</meth> now works (better) ;).</item> 
    17641767 
    17651768<item>Incorparated many bug fixes from Hartmut Goebel.</item> 
    17661769 
    1767 <item>Implemented <method>xsc.Element.copyDefaultAttrs</method>, which copies 
     1770<item>Implemented <meth>xsc.Element.copyDefaultAttrs</meth>, which copies 
    17681771unset attributes over from a dictionary (simplifies 
    17691772implementing <class>specials.plaintable</class> and <class>specials.plainbody</class>)</item> 
    17701773 
    1771 <item><method>providers.Provider.pushNamespace</method> now handles multiple 
     1774<item><meth>providers.Provider.pushNamespace</meth> now handles multiple 
    17721775arguments which may be <class>Namespace</class> objects or modules 
    17731776(in which case, <lit><rep>module</rep>.namespace</lit> will be pushed)</item> 
    17741777 
    1775 <item><method>providers.Providers.popNamespace</method> can now pop multiple 
     1778<item><meth>providers.Providers.popNamespace</meth> can now pop multiple 
    17761779namespaces at once.</item> 
    17771780 
    1778 <item><class>providers.TidyURIProvider</class> now uses <function>os.popen3</function> for 
     1781<item><class>providers.TidyURIProvider</class> now uses <func>os.popen3</func> for 
    17791782piping the file through tidy, so now there will be 
    17801783no more temporary files. The call to tidy now includes 
     
    17881791<item><filename>make.py</filename> includes a new option <option>--path</option> for 
    17891792adding directories to <lit>sys.path</lit>.</item> 
    1790 </ulist> 
    1791 </section> 
    1792  
    1793  
    1794 <section><title>Changes in 0.4.6 (released 11/03/2000)</title> 
    1795 <ulist> 
     1793</ul> 
     1794</section> 
     1795 
     1796 
     1797<section><h>Changes in 0.4.6 (released 11/03/2000)</h> 
     1798<ul> 
    17961799<item>Now uses <class>sgmlop.XMLParser</class> instead of 
    17971800<class>sgmlop.SGMLParser</class>, so case is preserved.</item> 
     
    17991802<item>Fixed another regression from the URL to string conversion 
    18001803change.</item> 
    1801 </ulist> 
    1802 </section> 
    1803  
    1804  
    1805 <section><title>Changes in 0.4.5 (released 11/01/2000)</title> 
    1806 <ulist> 
    1807 <item>Converting URLs to nodes is now done in <function>ToNode</function>, 
     1804</ul> 
     1805</section> 
     1806 
     1807 
     1808<section><h>Changes in 0.4.5 (released 11/01/2000)</h> 
     1809<ul> 
     1810<item>Converting URLs to nodes is now done in <func>ToNode</func>, 
    18081811so <class>URL</class> objects can be used everywhere.</item> 
    18091812 
    1810 <item>Fixed a few bugs in <method>Text._strtext</method> and 
    1811 <method>URLAttr._str</method>.</item> 
    1812 </ulist> 
    1813 </section> 
    1814  
    1815  
    1816 <section><title>Changes in 0.4.4 (releases 10/27/2000)</title> 
    1817 <ulist> 
     1813<item>Fixed a few bugs in <meth>Text._strtext</meth> and 
     1814<meth>URLAttr._str</meth>.</item> 
     1815</ul> 
     1816</section> 
     1817 
     1818 
     1819<section><h>Changes in 0.4.4 (releases 10/27/2000)</h> 
     1820<ul> 
    18181821<item>Now testing if characters can be encoded with the 
    18191822specified encoding is done directy. This means, that 
    18201823escaping unencodable characters now works even with 
    18211824exotic encodings (tested with 
    1822 <link href="http://pseudo.grad.sccs.chukyo-u.ac.jp/~kajiyama/python/"><filename>JapaneseCodecs-1.0.1.tar.gz</filename></link>).</item> 
     1825<a href="http://pseudo.grad.sccs.chukyo-u.ac.jp/~kajiyama/python/"><filename>JapaneseCodecs-1.0.1.tar.gz</filename></a>).</item> 
    18231826 
    18241827<item>The <class>URLAttr</class> constructor now can handle a single parameter 
     
    18261829 
    18271830<item>The URL to string conversion function have changed: 
    1828 <method>URL.asString</method> returns the URL with path markers, 
    1829 <method>URL.asPlainString</method> returns the URL without path markers.</item> 
     1831<meth>URL.asString</meth> returns the URL with path markers, 
     1832<meth>URL.asPlainString</meth> returns the URL without path markers.</item> 
    18301833 
    18311834<item>Added the <lit>i18n</lit> attribute to the <class>font</class> element.</item> 
     
    18361839<item>Several small enhancements and bug fixes contributed by 
    18371840Hartmut Goebel.</item> 
    1838 </ulist> 
    1839 </section> 
    1840  
    1841  
    1842 <section><title>Changes in 0.4.3 (released 10/19/2000)</title> 
    1843 <ulist> 
     1841</ul> 
     1842</section> 
     1843 
     1844 
     1845<section><h>Changes in 0.4.3 (released 10/19/2000)</h> 
     1846<ul> 
    18441847<item>Now processing instruction classes are registered in the 
    18451848same way as elements and entities are.</item> 
     
    18471850<item>The leaf nodes (<class>Text</class>, <class>Comment</class>, 
    18481851<class>ProcInst</class>) are now considered immutable. 
    1849 This means that their <method>asHTML</method> method can 
     1852This means that their <meth>asHTML</meth> method can 
    18501853simply return <self/>, because now those nodes can be shared between 
    18511854trees. Functionality for manipulation the objects is provided by a mixin 
     
    18531856in a speedup of about 10% for the python-quotes example.</item> 
    18541857 
    1855 <item>Small optimizations in the <method>asHTML</method> methods of <class>Element</class> and 
    1856 <class>Frag</class> optimized away many calls to <method>append</method>, 
    1857 <method>extend</method> and <method>ToNode</method> and result in a speedup 
     1858<item>Small optimizations in the <meth>asHTML</meth> methods of <class>Element</class> and 
     1859<class>Frag</class> optimized away many calls to <meth>append</meth>, 
     1860<meth>extend</meth> and <meth>ToNode</meth> and result in a speedup 
    18581861of about 30% for the python-quotes example. One consequence of this is 
    18591862that <class>Null</class> objects will no longer be ignored.</item> 
    1860 </ulist> 
    1861 </section> 
    1862  
    1863  
    1864 <section><title>Changes in 0.4.2 (released 09/24/2000)</title> 
    1865 <ulist> 
     1863</ul> 
     1864</section> 
     1865 
     1866 
     1867<section><h>Changes in 0.4.2 (released 09/24/2000)</h> 
     1868<ul> 
    18661869<item>New elements <class>keywords</class> and <class>description</class> in 
    18671870<filename>meta.py</filename>.</item> 
    18681871 
    1869 <item>Fixed a bug in <method>Namespace.register</method>, now setting <lit>name=None</lit> 
     1872<item>Fixed a bug in <meth>Namespace.register</meth>, now setting <lit>name=None</lit> 
    18701873to prevent an element from being registered works again.</item> 
    1871 </ulist> 
    1872 </section> 
    1873  
    1874  
    1875 <section><title>Changes in 0.4.1 (released 09/21/2000)</title> 
    1876 <ulist> 
     1874</ul> 
     1875</section> 
     1876 
     1877 
     1878<section><h>Changes in 0.4.1 (released 09/21/2000)</h> 
     1879<ul> 
    18771880<item>A new module named <filename>meta.py</filename> has been created, that simplifies 
    18781881generating meta tags.</item> 
    18791882 
    18801883<item>Various small bugfixes.</item> 
    1881 </ulist> 
    1882 </section> 
    1883  
    1884  
    1885 <section><title>Changes in 0.4 (released 09/19/2000)</title> 
    1886 <ulist> 
     1884</ul> 
     1885</section> 
     1886 
     1887 
     1888<section><h>Changes in 0.4 (released 09/19/2000)</h> 
     1889<ul> 
    18871890<item>&xist; now requires at least Python 2.0b1.</item> 
    18881891 
    18891892<item>A new bugfixed version of the <app>sgmlop</app> source is available 
    1890 from the <link href="ftp://ftp.livinglogic.de/pub/livinglogic/xist/">&ftp; site</link>.</item> 
     1893from the <a href="ftp://ftp.livinglogic.de/pub/livinglogic/xist/">&ftp; site</a>.</item> 
    18911894 
    18921895<item>&xist; now completely supports Unicode. For output any 
     
    18981901and <arg>XHTML</arg> parameters are now attributes of the publisher).</item> 
    18991902 
    1900 <item><method>asString</method> will now always return a Unicode string. If you 
    1901 want a byte string use <method>asBytes</method> instead, where the encoding 
     1903<item><meth>asString</meth> will now always return a Unicode string. If you 
     1904want a byte string use <meth>asBytes</meth> instead, where the encoding 
    19021905can be specified as an argument.</item> 
    19031906 
    19041907<item>There an additional publisher class <class>FilePublisher</class>, which can 
    19051908be used for publishing to a file (or anything else that has 
    1906 a <method>write</method> and a <method>writelines</method> method, and is supported by the stream 
    1907 writer available through <function>codecs.lookup</function>).</item> 
     1909a <meth>write</meth> and a <meth>writelines</meth> method, and is supported by the stream 
     1910writer available through <func>codecs.lookup</func>).</item> 
    19081911 
    19091912<item>Element and attribute names are no longer converted to lowercase. 
     
    19151918<item>Elements and entities are no longer registered one by one. Now 
    19161919you can build <class>Namespace</class> objects which are used for searching 
    1917 and there are <method>pushNamespace</method> and <method>popNamespace</method> 
    1918 functions in <module>XSC.xsc</module>. For more info, see the source.</item> 
     1920and there are <meth>pushNamespace</meth> and <meth>popNamespace</meth> 
     1921functions in <mod>XSC.xsc</mod>. For more info, see the source.</item> 
    19191922 
    19201923<item>Image size calculation has been removed from <class>html.img</class> and 
     
    19221925<class>specials.autoinput</class> for that.</item> 
    19231926 
    1924 <item><method>__getitem__</method>, <method>__setitem__</method> and <method>__delitem</method> 
     1927<item><meth>__getitem__</meth>, <meth>__setitem__</meth> and <meth>__delitem</meth> 
    19251928of <class>Frag</class> and <class>Element</class> now accepts a list as an argument. 
    19261929The method will be applied recursively, i.e. <lit>e[[0, 1, "foo", 2]</lit> is the 
     
    19311934<filename>form.py</filename> respectively.</item> 
    19321935 
    1933 <item>When using <function>xsc.make</function> the encoding and XHTML parameters to use can now 
     1936<item>When using <func>xsc.make</func> the encoding and XHTML parameters to use can now 
    19341937be specified on the command line (e.g. <lit>--encoding utf-8 --xhtml 2</lit>)</item> 
    19351938 
    1936 <item><par>Handling of multiline <markup>&lt;?xsc-eval?&gt;</markup> and <markup>&lt;?xsc-exec?&gt;</markup> 
     1939<item><p>Handling of multiline <markup>&lt;?xsc-eval?&gt;</markup> and <markup>&lt;?xsc-exec?&gt;</markup> 
    19371940has been enhanced, although, &xist; will not be able to guess the correct indentation 
    1938 in all cases. As a workarround simply add a Python comment to the beginning:</par> 
     1941in all cases. As a workarround simply add a Python comment to the beginning:</p> 
    19391942<prog> 
    19401943&lt;?xsc-exec 
     
    19431946?&gt; 
    19441947</prog> 
    1945 <par>won't work</par> 
     1948<p>won't work</p> 
    19461949<prog> 
    19471950&lt;?xsc-exec 
     
    19511954?&gt; 
    19521955</prog> 
    1953 <par>will.</par> 
     1956<p>will.</p> 
    19541957</item> 
    19551958 
    1956 <item><par>Make functionality has been moved to <filename>make.py</filename>, as certain modules can't 
     1959<item><p>Make functionality has been moved to <filename>make.py</filename>, as certain modules can't 
    19571960be used as the main script, because reimporting them in processing 
    1958 instructions won't work. Now you can simply call</par> 
     1961instructions won't work. Now you can simply call</p> 
    19591962<example> 
    1960 <title>The new make script</title> 
     1963<h>The new make script</h> 
    19611964<prog>make.py --import xist.html --import spam eggs.xsc</prog> 
    19621965</example> 
    19631966</item> 
    19641967 
    1965 <item><par>There is a new module <filename>cond.py</filename>, that contains 
    1966 elements that can be used for conditionals:</par> 
     1968<item><p>There is a new module <filename>cond.py</filename>, that contains 
     1969elements that can be used for conditionals:</p> 
    19671970<prog> 
    19681971&lt;?xsc-exec a=42?&gt; 
     
    19761979</prog> 
    19771980</item> 
    1978 </ulist> 
    1979 </section> 
    1980  
    1981  
    1982 <section><title>Changes in 0.3.9 (released 08/10/2000)</title> 
    1983 <ulist> 
     1981</ul> 
     1982</section> 
     1983 
     1984 
     1985<section><h>Changes in 0.3.9 (released 08/10/2000)</h> 
     1986<ul> 
    19841987<item><app>sgmlop</app> will now be found either via <lit>import sgmlop</lit> 
    19851988or via <lit>from xml.parsers import sgmlop</lit>.</item> 
    1986 </ulist> 
    1987 </section> 
    1988  
    1989  
    1990 <section><title>Changes in 0.3.8 (released 07/14/2000)</title> 
    1991 <ulist> 
    1992 <item>Fixed a bug in <method>URLAttr.publish</method>, which prevented 
     1989</ul> 
     1990</section> 
     1991 
     1992 
     1993<section><h>Changes in 0.3.8 (released 07/14/2000)</h> 
     1994<ul> 
     1995<item>Fixed a bug in <meth>URLAttr.publish</meth>, which prevented 
    19931996<class>URLAttr</class> from working at all.</item> 
    1994 </ulist> 
    1995 </section> 
    1996  
    1997  
    1998 <section><title>Changes in 0.3.7 (released 07/06/2000)</title> 
    1999 <ulist> 
     1997</ul> 
     1998</section> 
     1999 
     2000 
     2001<section><h>Changes in 0.3.7 (released 07/06/2000)</h> 
     2002<ul> 
    20002003<item>Fixed a bug in <class>html.img</class> and <class>html.input</class>. 
    20012004Now image size calculation works again.</item> 
    2002 </ulist> 
    2003 </section> 
    2004  
    2005  
    2006 <section><title>Changes in 0.3.6 (released 07/04/2000)</title> 
    2007 <ulist> 
    2008 <item>Fixed a bug in <method>Node._matches</method>, which resulted in a non working 
    2009 <method>find</method>.</item> 
    2010 </ulist> 
    2011 </section> 
    2012  
    2013  
    2014 <section><title>Changes in 0.3.5 (released 07/02/2000)</title> 
    2015 <ulist> 
     2005</ul> 
     2006</section> 
     2007 
     2008 
     2009<section><h>Changes in 0.3.6 (released 07/04/2000)</h> 
     2010<ul> 
     2011<item>Fixed a bug in <meth>Node._matches</meth>, which resulted in a non working 
     2012<meth>find</meth>.</item> 
     2013</ul> 
     2014</section> 
     2015 
     2016 
     2017<section><h>Changes in 0.3.5 (released 07/02/2000)</h> 
     2018<ul> 
    20162019<item>The documentation example has been enhanced. Now documenting methods works.</item> 
    20172020 
    20182021<item>When the member <lit>elementname</lit> in the element class is set before calling 
    2019 <function>registerElement</function>, this element name will be used for the element. This 
    2020 allows custom names even when using <function>registerAllElements</function>.</item> 
     2022<func>registerElement</func>, this element name will be used for the element. This 
     2023allows custom names even when using <func>registerAllElements</func>.</item> 
    20212024 
    20222025<item>Comparison of scheme and server in URLs is done case insensitive 
    2023 (as <link href="http://www.ietf.org/rfc/rfc2068.txt">RFC 2068</link> 
     2026(as <a href="http://www.ietf.org/rfc/rfc2068.txt">RFC 2068</a> 
    20242027requires.)</item> 
    20252028 
    2026 <item><par>Image size calculation is now done in <method>asString</method> and 
    2027 not in <method>asHTML</method>. 
    2028 This allows to write faster code. Old method:</par> 
     2029<item><p>Image size calculation is now done in <meth>asString</meth> and 
     2030not in <meth>asHTML</meth>. 
     2031This allows to write faster code. Old method:</p> 
    20292032<prog>e = html.div(html.img(...),gurk.hurz()).asHTML().asString()</prog> 
    2030 <par>New method</par> 
     2033<p>New method</p> 
    20312034<prog>e = html.div(html.img(...),gurk.hurz().asHTML()).asString()</prog></item> 
    20322035 
     
    20342037The <lit>size</lit> attribute is set to the image width.</item> 
    20352038 
    2036 <item><par>Manipulating the path in an &url; is now done via the usual 
    2037 <method>__setitem__</method>/<method>__getitem__</method> stuff, 
    2038 which keeps the path in a consistent state.</par> 
     2039<item><p>Manipulating the path in an &url; is now done via the usual 
     2040<meth>__setitem__</meth>/<meth>__getitem__</meth> stuff, 
     2041which keeps the path in a consistent state.</p> 
    20392042<prog> 
    20402043&gt;&gt;&gt; from xist.URL import URL 
     
    20462049</item> 
    20472050 
    2048 <item><method>findNodes</method> (which has been shortened to <method>find</method>) 
     2051<item><meth>findNodes</meth> (which has been shortened to <meth>find</meth>) 
    20492052has an additional argument <arg>test</arg>, which can be a test function that will 
    20502053be called when the node passes all other tests.</item> 
    20512054 
    2052 <item><method>asString</method> no longer generates a string directly, but uses the new method 
    2053 <method>publish</method>, which has an additional argument <arg>publisher</arg>, 
     2055<item><meth>asString</meth> no longer generates a string directly, but uses the new method 
     2056<meth>publish</meth>, which has an additional argument <arg>publisher</arg>, 
    20542057to which the strings to be output are passed.</item> 
    2055 </ulist> 
    2056 </section> 
    2057  
    2058  
    2059 <section><title>Changes in 0.3.4 (released 05/31/2000)</title> 
    2060 <ulist> 
    2061 <item>Location information is now copied over in <method>clone</method>, <method>asHTML</method> 
    2062 and <method>compact</method> where appropriate, so you know even in the &html; tree 
     2058</ul> 
     2059</section> 
     2060 
     2061 
     2062<section><h>Changes in 0.3.4 (released 05/31/2000)</h> 
     2063<ul> 
     2064<item>Location information is now copied over in <meth>clone</meth>, <meth>asHTML</meth> 
     2065and <meth>compact</meth> where appropriate, so you know even in the &html; tree 
    20632066where something came from.</item> 
    20642067 
    2065 <item><par><lit>xsc.repransi</lit> can now have three values:</par> 
    2066 <ulist> 
     2068<item><p><lit>xsc.repransi</lit> can now have three values:</p> 
     2069<ul> 
    20672070<item><lit>0</lit>: coloring is off</item> 
    20682071<item><lit>1</lit>: coloring is on for a dark background</item> 
    20692072<item><lit>2</lit>: coloring is on for a light background</item> 
    2070 </ulist> 
    2071 <par>All <lit>repransi</lit> variables are now arrays with two strings, 
    2072 the first for dark, the second for light.</par></item> 
    2073 </ulist> 
    2074 </section> 
    2075  
    2076  
    2077 <section><title>Changes in 0.3.3 (released 05/30/2000)</title> 
    2078 <ulist> 
     2073</ul> 
     2074<p>All <lit>repransi</lit> variables are now arrays with two strings, 
     2075the first for dark, the second for light.</p></item> 
     2076</ul> 
     2077</section> 
     2078 
     2079 
     2080<section><h>Changes in 0.3.3 (released 05/30/2000)</h> 
     2081<ul> 
    20792082<item>The workaround for the trailing CDATA bug in <app>sgmlop</app> has been removed, so now 
    20802083you'll need a newer version of <app>sgmlop</app> (included in <app>PyXML 0.5.5.1</app>)</item> 
    2081 </ulist> 
    2082 </section> 
    2083  
    2084  
    2085 <section><title>Changes before 0.3.3</title> 
    2086 <ulist> 
     2084</ul> 
     2085</section> 
     2086 
     2087 
     2088<section><h>Changes before 0.3.3</h> 
     2089<ul> 
    20872090<item>These changes predate written history.</item> 
    2088 </ulist> 
    2089 </section> 
     2091</ul> 
     2092</section> 
  • demos/media/Media.html

    r2425 r3128  
    11<?xml version='1.0' encoding='us-ascii'?> 
    22<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
    3 <html><head><meta content="text/html; charset=us-ascii" http-equiv="Content-Type" /><title>Media</title><link href="Media.css" type="text/css" rel="stylesheet" /></head><body marginheight="0" marginwidth="0" topmargin="0" leftmargin="0"><h1>Media</h1><h2>4 LDs</h2><ol><li><span class="name">L&#233;on, der Profi</span> (127 min)<div class="purchase">MediaMarkt Bayreuth: 79.99 DEM (01.04.1998)</div></li><li><span class="name">Only Yesterday</span> (98 min)<div class="purchase">San Fransico Laserdiscs: 50.0 USD (18.07.1998)</div></li><li><span class="name">The Dream is Alive</span> (37 min)<div class="purchase">Cinemabilia: 102.9 DEM (29.11.1997)</div></li><li><span class="name">Zwei Welten</span> (105 min)<div class="purchase">MediaMarkt Regensburg: 19.95 DEM (20.09.1997)</div></li></ol><h2>14 DVDs</h2><ol><li><span class="name">12 Monkeys</span> (130 min; RC 1)<div class="purchase">Amazon.com: 23.99 USD (19.03.2000)</div></li><li><span class="name">Cowboy Bebop, Volume 1</span> (125 min; RC 1)<div class="purchase">Amazon.com: 17.99 USD (07.02.2000)</div></li><li><span class="name">Ein Lied von Liebe und Tod &#8212; Gloomy Sunday</span> (108 min; RC 2)<div class="purchase">Amazon.de: 44.99 DEM (27.11.2000)</div></li><li><span class="name">Grave of the Fireflies</span> (88 min; RC 1)<div class="purchase">Planet Anime, Houston: 26.96 USD (30.12.1998)</div></li><li><span class="name">Lola rennt</span> (77 min; RC 2)<div class="purchase">Mediamarkt Bayreuth: 54.99 DEM (09.03.1999)</div></li><li><span class="name">Nach F&#252;nf im Urwald</span> (93 min; RC 2)<div class="purchase">Amazon.de: 39.99 DEM (25.08.2000)</div></li><li><span class="name">Neon Genesis Evangelion - Collection 0:1</span> (120 min; RC 1)<div class="purchase">Amazon.com: 17.99 USD (07.02.2000)</div></li><li><span class="name">Patlabor 2 - The Movie</span> (100 min; RC 1)<div class="purchase">Amazon.com: 20.96 USD (21.08.2000)</div></li><li><span class="name">Perfect Blue</span> (81 min; RC 1, 2, 4)<div class="purchase">Amazon.com: 20.97 USD (07.02.2000)</div></li><li><span class="name">Princess Mononoke</span> (134 min; RC 1)<div class="purchase">Amazon.com: 23.09 USD (21.08.2000)</div></li><li><span class="name">The Bride with White Hair</span> (92 min; RC 0)<div class="purchase">www.dvdempire.com: 20.45 USD (01.05.1998)</div></li><li><span class="name">The Bride with White Hair 2</span> (80 min; RC 0)<div class="purchase">www.dvdempire.com: 20.95 USD (28.05.1999)</div></li><li><span class="name">The King of Masks</span> (101 min; RC 1)<div class="purchase">Amazon.com: 23.99 USD (29.08.2000)</div></li><li><span class="name">The Princess Bride</span> (98 min; RC 1)<div class="purchase">Amazon.com: 11.99 USD (06.06.2000)</div></li></ol></body></html> 
     3<html><head><meta content="text/html; charset=us-ascii" http-equiv="Content-Type" /><h>Media</h><a href="Media.css" type="text/css" rel="stylesheet" /></head><body marginheight="0" marginwidth="0" topmargin="0" leftmargin="0"><h1>Media</h1><h2>4 LDs</h2><ol><li><span class="name">L&#233;on, der Profi</span> (127 min)<div class="purchase">MediaMarkt Bayreuth: 79.99 DEM (01.04.1998)</div></li><li><span class="name">Only Yesterday</span> (98 min)<div class="purchase">San Fransico Laserdiscs: 50.0 USD (18.07.1998)</div></li><li><span class="name">The Dream is Alive</span> (37 min)<div class="purchase">Cinemabilia: 102.9 DEM (29.11.1997)</div></li><li><span class="name">Zwei Welten</span> (105 min)<div class="purchase">MediaMarkt Regensburg: 19.95 DEM (20.09.1997)</div></li></ol><h2>14 DVDs</h2><ol><li><span class="name">12 Monkeys</span> (130 min; RC 1)<div class="purchase">Amazon.com: 23.99 USD (19.03.2000)</div></li><li><span class="name">Cowboy Bebop, Volume 1</span> (125 min; RC 1)<div class="purchase">Amazon.com: 17.99 USD (07.02.2000)</div></li><li><span class="name">Ein Lied von Liebe und Tod &#8212; Gloomy Sunday</span> (108 min; RC 2)<div class="purchase">Amazon.de: 44.99 DEM (27.11.2000)</div></li><li><span class="name">Grave of the Fireflies</span> (88 min; RC 1)<div class="purchase">Planet Anime, Houston: 26.96 USD (30.12.1998)</div></li><li><span class="name">Lola rennt</span> (77 min; RC 2)<div class="purchase">Mediamarkt Bayreuth: 54.99 DEM (09.03.1999)</div></li><li><span class="name">Nach F&#252;nf im Urwald</span> (93 min; RC 2)<div class="purchase">Amazon.de: 39.99 DEM (25.08.2000)</div></li><li><span class="name">Neon Genesis Evangelion - Collection 0:1</span> (120 min; RC 1)<div class="purchase">Amazon.com: 17.99 USD (07.02.2000)</div></li><li><span class="name">Patlabor 2 - The Movie</span> (100 min; RC 1)<div class="purchase">Amazon.com: 20.96 USD (21.08.2000)</div></li><li><span class="name">Perfect Blue</span> (81 min; RC 1, 2, 4)<div class="purchase">Amazon.com: 20.97 USD (07.02.2000)</div></li><li><span class="name">Princess Mononoke</span> (134 min; RC 1)<div class="purchase">Amazon.com: 23.09 USD (21.08.2000)</div></li><li><span class="name">The Bride with White Hair</span> (92 min; RC 0)<div class="purchase">www.dvdempire.com: 20.45 USD (01.05.1998)</div></li><li><span class="name">The Bride with White Hair 2</span> (80 min; RC 0)<div class="purchase">www.dvdempire.com: 20.95 USD (28.05.1999)</div></li><li><span class="name">The King of Masks</span> (101 min; RC 1)<div class="purchase">Amazon.com: 23.99 USD (29.08.2000)</div></li><li><span class="name">The Princess Bride</span> (98 min; RC 1)<div class="purchase">Amazon.com: 11.99 USD (06.06.2000)</div></li></ol></body></html> 
  • demos/media/Media.xsl

    r2136 r3128  
    66    <html> 
    77    <head> 
    8     <title>Media</title> 
    9     <link rel="stylesheet" href="Media.css"/> 
     8    <h>Media</h> 
     9    <a rel="stylesheet" href="Media.css"/> 
    1010    </head> 
    1111    <body> 
  • docs/Advanced.xml

    r3105 r3128  
    1 <section><title>Converter contexts</title> 
    2  
    3 <par>Converter contexts can be used to pass around information in recursive 
    4 calls to the <method>convert</method> and <method>mapped</method> methods. 
     1<section><h>Converter contexts</h> 
     2 
     3<p>Converter contexts can be used to pass around information in recursive 
     4calls to the <meth>convert</meth> and <meth>mapped</meth> methods. 
    55A <pyref module="ll.xist.converters" class="Converter"><class>Converter</class></pyref> 
    66object will be passed in all calls, so this object is the place to store 
    77information. However if each element, procinst and entity class decided on its 
    88own which attributes names to use, name collisions would be inevitale. To avoid 
    9 this, the following system is used.</par> 
    10  
    11 <par>When a class wants to store information in a converter, it has to define 
     9this, the following system is used.</p> 
     10 
     11<p>When a class wants to store information in a converter, it has to define 
    1212a <class>Context</class> class (normally derived from the <class>Context</class> 
    1313class of its base class). The constructor must initialize the context object 
    1414to a initial state. You can get the context object for a certain class by treating 
    15 the converter as a dictionary with the class (or an instance) as the key like this:</par> 
    16  
    17 <example><title>Defining and using a converter context</title> 
     15the converter as a dictionary with the class (or an instance) as the key like this:</p> 
     16 
     17<example><h>Defining and using a converter context</h> 
    1818<prog> 
    1919from ll.xist import xsc 
     
    3636 
    3737 
    38 <section><title>Chaining pool and extending namespaces</title> 
    39  
    40 <par>When using <pyref module="ll.xist.xsc" class="Pool">pools</pyref> it's 
    41 possible to do some sort of <z>namespace subclassing</z>.</par> 
    42  
    43 <par>Registering a module in a pool not only registers the element, procinst and 
     38<section><h>Chaining pool and extending namespaces</h> 
     39 
     40<p>When using <pyref module="ll.xist.xsc" class="Pool">pools</pyref> it's 
     41possible to do some sort of <z>namespace subclassing</z>.</p> 
     42 
     43<p>Registering a module in a pool not only registers the element, procinst and 
    4444entity classes in the pool for parsing, but each attribute of the module (as 
    4545long as it's weak referencable) is available as an attribute of the pool 
    46 itself:</par> 
    47  
    48 <example><title>Pool attributes</title> 
     46itself:</p> 
     47 
     48<example><h>Pool attributes</h> 
    4949<prog> 
    5050from ll.xist import xsc 
     
    5656</example> 
    5757 
    58 <par>This outputs <lit><![CDATA[<element class ll.xist.ns.html:img at 0x3eed00>]]></lit>.</par> 
    59  
    60 <par>It's possible to chain pools together. When an attribute isn't found in 
     58<p>This outputs <lit><![CDATA[<element class ll.xist.ns.html:img at 0x3eed00>]]></lit>.</p> 
     59 
     60<p>It's possible to chain pools together. When an attribute isn't found in 
    6161the first pool, it will be looked up in a second pool (the so called base 
    62 pool):</par> 
    63  
    64 <example><title>Pool chaining</title> 
     62pool):</p> 
     63 
     64<example><h>Pool chaining</h> 
    6565<prog> 
    6666from ll.xist import xsc 
     
    7373</example> 
    7474 
    75 <par>Here the <lit>hpool</lit> (containing the <module>html</module> namespace) 
     75<p>Here the <lit>hpool</lit> (containing the <mod>html</mod> namespace) 
    7676will be used, when the attribute can't be found in <lit>spool</lit>. So this 
    7777will again give the output 
    78 <lit><![CDATA[<element class ll.xist.ns.html:img at 0x3eed00>]]></lit>.</par> 
    79  
    80 <par>It's possible to get automatic pool chaining. If a module has an attribute 
     78<lit><![CDATA[<element class ll.xist.ns.html:img at 0x3eed00>]]></lit>.</p> 
     79 
     80<p>It's possible to get automatic pool chaining. If a module has an attribute 
    8181<lit>__bases__</lit> (which must be a sequence of modules), they will 
    8282automatically be wrapped in a pool and used as the base pools for the pool 
    8383created for the first module. This makes it possible to <z>overwrite</z> element 
    8484classes in existing namespaces. For example to replace the <class>a</class> 
    85 class in <module>ll.xist.ns.html</module>, put the following into a module 
    86 <module>html2</module>:</par> 
    87  
    88 <example><title>Automatic pool chaining (<filename>html2.py</filename>)</title> 
     85class in <mod>ll.xist.ns.html</mod>, put the following into a module 
     86<mod>html2</mod>:</p> 
     87 
     88<example><h>Automatic pool chaining (<filename>html2.py</filename>)</h> 
    8989<prog> 
    9090from ll.xist.ns import html 
     
    101101</example> 
    102102 
    103 <par>Now you can use the module in a pool:</par> 
    104  
    105 <example><title>Using a pool chain</title> 
     103<p>Now you can use the module in a pool:</p> 
     104 
     105<example><h>Using a pool chain</h> 
    106106<prog> 
    107107from ll.xist import xsc 
     
    113113</example> 
    114114 
    115 <par>This outputs:</par> 
     115<p>This outputs:</p> 
    116116<tty><![CDATA[ 
    117117<element class html2:a at 0x113ec40> <element class ll.xist.ns.html:b at 0x1101fe0> 
    118118]]></tty> 
    119119 
    120 <par>Note that such a chained pool can of course used when parsing &xml;. The 
     120<p>Note that such a chained pool can of course used when parsing &xml;. The 
    121121parser will recursively search for the first class that has the appropriate 
    122 name when instantiating the tree nodes.</par> 
    123  
    124 </section> 
    125  
    126  
    127 <section><title>Conversion targets</title> 
    128  
    129 <par>The <arg>converter</arg> argument passed to the <method>convert</method> 
     122name when instantiating the tree nodes.</p> 
     123 
     124</section> 
     125 
     126 
     127<section><h>Conversion targets</h> 
     128 
     129<p>The <arg>converter</arg> argument passed to the <meth>convert</meth> 
    130130method has an attribute <lit>target</lit> which is a module or pool and 
    131 specifies the target namespace to which <self/> should be converted.</par> 
    132  
    133 <par>You can check which conversion is wanted by checking e.g. the 
     131specifies the target namespace to which <self/> should be converted.</p> 
     132 
     133<p>You can check which conversion is wanted by checking e.g. the 
    134134<lit>xmlns</lit> atribute. Once this is determined you can use element classes 
    135135from the target to create the required &xml; object tree. This makes it possible 
    136136to customize the conversion by passing a chained pool to the 
    137 <method>convert</method> method that extends an existing namespace.</par> 
    138  
    139 <par>The following example shows how an element be converted to two 
    140 different targets:</par> 
    141  
    142 <example><title>Using conversion targets</title> 
     137<meth>convert</meth> method that extends an existing namespace.</p> 
     138 
     139<p>The following example shows how an element be converted to two 
     140different targets:</p> 
     141 
     142<example><h>Using conversion targets</h> 
    143143<prog> 
    144144from ll.xist import xsc 
     
    157157</example> 
    158158 
    159 <par>The default target for conversion is <module>ll.xist.ns.html</module>. 
     159<p>The default target for conversion is <mod>ll.xist.ns.html</mod>. 
    160160Other targets can be specified via the <arg>target</arg> argument in the 
    161 <class>Converter</class> constructor or the <method>conv</method> method:</par> 
     161<class>Converter</class> constructor or the <meth>conv</meth> method:</p> 
    162162 
    163163<tty> 
     
    174174 
    175175 
    176 <section><title>Validation and content models</title> 
    177  
    178 <par>When generating &html; you might want to make sure that your generated 
     176<section><h>Validation and content models</h> 
     177 
     178<p>When generating &html; you might want to make sure that your generated 
    179179code doesn't contain any illegal tag nesting (i.e. something bad like 
    180180<markup>&lt;p&gt;&lt;p&gt;foo&lt;/p&gt;&lt;/p&gt;</markup>). The module 
    181 <module>ll.xist.ns.html</module> does this automatically:</par> 
     181<mod>ll.xist.ns.html</mod> does this automatically:</p> 
    182182 
    183183<example> 
     
    192192</example> 
    193193 
    194 <par>For your own elements you can specify the content model too. This is done 
     194<p>For your own elements you can specify the content model too. This is done 
    195195by setting the class attribute <lit>model</lit> inside the element class. 
    196 <lit>model</lit> must be an object that provides a <method>checkvalid</method> 
     196<lit>model</lit> must be an object that provides a <meth>checkvalid</meth> 
    197197method. This method will be called during parsing or publishing with the element 
    198198as an argument. When invalid content is detected, the Python warning framework 
    199 should be used to issue a warning.</par> 
    200  
    201 <par>The module <module>ll.xist.sims</module> contains several classes that 
     199should be used to issue a warning.</p> 
     200 
     201<p>The module <mod>ll.xist.sims</mod> contains several classes that 
    202202provide simple validation methods: 
    203203<pyref module="ll.xist.sims" class="Empty"><class>Empty</class></pyref> 
     
    214214will only allow the elements specified in the constructor. 
    215215<pyref module="ll.xist.sims" class="ElementsOrText"><class>ElementsOrText</class></pyref> 
    216 will only allow the elements specified in the constructor and text.</par> 
    217  
    218 <par>None of these classes will check the number of child elements or their 
    219 order.</par> 
    220  
    221 <par>For more info see the <pyref module="ll.xist.sims"><module>sims</module></pyref> 
    222 module.</par> 
    223 </section> 
     216will only allow the elements specified in the constructor and text.</p> 
     217 
     218<p>None of these classes will check the number of child elements or their 
     219order.</p> 
     220 
     221<p>For more info see the <pyref module="ll.xist.sims"><mod>sims</mod></pyref> 
     222module.</p> 
     223</section> 
  • docs/Examples.xml

    r3086 r3128  
    11<?xml version='1.0' encoding='iso-8859-1'?> 
    22 
    3 <section><title>Creating &html;</title> 
    4  
    5 <par>You can create and output &html; like this:</par> 
     3<section><h>Creating &html;</h> 
     4 
     5<p>You can create and output &html; like this:</p> 
    66 
    77<prog> 
     
    3131</prog> 
    3232 
    33 <par> You can also use <lit>with</lit> blocks (and the unary <lit>+</lit> operator) 
    34 to generate the same &html;:</par> 
     33<p> You can also use <lit>with</lit> blocks (and the unary <lit>+</lit> operator) 
     34to generate the same &html;:</p> 
    3535 
    3636<prog> 
     
    6060 
    6161 
    62 <section><title>Defining new elements</title> 
    63  
    64 <par>You can define new elements and how they should be converted to &html; 
    65 (or other &xml; vocabularies) like this:</par> 
     62<section><h>Defining new elements</h> 
     63 
     64<p>You can define new elements and how they should be converted to &html; 
     65(or other &xml; vocabularies) like this:</p> 
    6666 
    6767<prog> 
     
    103103 
    104104 
    105 <section><title>Parsing &html;</title> 
    106  
    107 <par>Parsing &html; is done like this:</par> 
     105<section><h>Parsing &html;</h> 
     106 
     107<p>Parsing &html; is done like this:</p> 
    108108 
    109109<prog> 
     
    116116 
    117117 
    118 <section><title>Finding and counting nodes</title> 
    119  
    120 <par>The following example shows you how to output the &url;s of all images 
    121 inside links on Python's homepage:</par> 
     118<section><h>Finding and counting nodes</h> 
     119 
     120<p>The following example shows you how to output the &url;s of all images 
     121inside links on Python's homepage:</p> 
    122122 
    123123<tty> 
     
    134134</tty> 
    135135 
    136 <par>If you want to output both the links and the image &url;s, do the 
    137 following:</par> 
     136<p>If you want to output both the links and the image &url;s, do the 
     137following:</p> 
    138138 
    139139<tty> 
     
    149149</tty> 
    150150 
    151 <par>If you want to count the number of links on the page you can do the 
    152 following:</par> 
     151<p>If you want to count the number of links on the page you can do the 
     152following:</p> 
    153153 
    154154<tty> 
     
    164164 
    165165 
    166 <section><title>Replacing text</title> 
    167  
    168 <par>This example demonstrates how to make a copy of an &xml; tree with some 
    169 text replacements:</par> 
     166<section><h>Replacing text</h> 
     167 
     168<p>This example demonstrates how to make a copy of an &xml; tree with some 
     169text replacements:</p> 
    170170 
    171171<prog> 
     
    187187 
    188188 
    189 <section><title>Converting &html; to &xist; code</title> 
    190  
    191 <par>The class <pyref module="ll.xist.presenters" class="CodePresenter"><class>ll.xist.presenters.CodePresenter</class></pyref> 
    192 makes it possible to output an &xist; tree as usable Python source code:</par> 
     189<section><h>Converting &html; to &xist; code</h> 
     190 
     191<p>The class <pyref module="ll.xist.presenters" class="CodePresenter"><class>ll.xist.presenters.CodePresenter</class></pyref> 
     192makes it possible to output an &xist; tree as usable Python source code:</p> 
    193193 
    194194<tty> 
     
    239239 
    240240 
    241 <section><title>Using converter contexts to pass information between elements</title> 
    242  
    243 <par>Converter contexts can be used to pass information between elements. 
     241<section><h>Using converter contexts to pass information between elements</h> 
     242 
     243<p>Converter contexts can be used to pass information between elements. 
    244244The following example will generate &html; <lit>&lt;h1&gt;</lit>, ..., <lit>&lt;h6&gt;</lit> 
    245 elements according to the nesting depth of a <lit>&lt;section&gt;</lit> element.</par> 
     245elements according to the nesting depth of a <lit>&lt;section&gt;</lit> element.</p> 
    246246 
    247247<prog> 
     
    284284</prog> 
    285285 
    286 <par>The output of this script will be:</par> 
     286<p>The output of this script will be:</p> 
    287287 
    288288<tty> 
  • docs/Howto.xml

    r3086 r3128  
    11<?xml version='1.0' encoding='iso-8859-1'?> 
    2 <par>&xist; is an extensible &html;/&xml; generator written in Python. 
     2<p>&xist; is an extensible &html;/&xml; generator written in Python. 
    33It was developed as a replacement for an &html; preprocessor named 
    44<app moreinfo="http://www.linguistik.uni-erlangen.de/~msbethke/hsc/">HSC</app> 
     
    66(&xml;/&html; elements as Python objects) from 
    77<app moreinfo="http://starship.python.net/crew/friedrich/HTMLgen/html/main.html">HTMLgen</app> 
    8 or <app moreinfo="http://dustman.net/andy/python/HyperText/">HyperText</app>.</par> 
    9  
    10 <par>(If you're impatient, there's also a 
    11 <link href="Examples.html">list of examples</link> that shows what can 
    12 be done with &xist;.)</par> 
    13  
    14 <section><title>Overview</title> 
    15 <par>&xist; can be used as a compiler that reads an input &xml; file and 
     8or <app moreinfo="http://dustman.net/andy/python/HyperText/">HyperText</app>.</p> 
     9 
     10<p>(If you're impatient, there's also a 
     11<a href="Examples.html">list of examples</a> that shows what can 
     12be done with &xist;.)</p> 
     13 
     14<section><h>Overview</h> 
     15<p>&xist; can be used as a compiler that reads an input &xml; file and 
    1616generates a transformed output file, or it could be used for generating &xml; 
    1717dynamically inside a web server (but note that handling object trees <em>is</em> 
    1818slower than simply sending string fragments). In either case generating the 
    19 final &html; or &xml; output requires the following three steps:</par> 
    20 <ulist> 
     19final &html; or &xml; output requires the following three steps:</p> 
     20<ul> 
    2121<item>Generating a source &xml; tree: This can be done either by 
    2222parsing an &xml; file, or by directly constructing the 
     
    2727tree can be a &html; tree or a &svg; tree or XSL-FO tree or any other 
    2828&xml; tree you like. Every node class provides a 
    29 <method>convert</method> method for performing this conversion. For 
     29<meth>convert</meth> method for performing this conversion. For 
    3030your own &xml; element types you have to define your 
    3131own element classes and implement an appropriate 
    32 <method>convert</method> method. This is possible for 
     32<meth>convert</meth> method. This is possible for 
    3333processing instructions and entity references too.</item> 
    3434<item>Publishing the target tree: For generating the final 
     
    3636the encoded byte string fragments that can be written to an output stream 
    3737(or yielded from a WSGI application, etc.).</item> 
    38 </ulist> 
    39 </section> 
    40  
    41  
    42 <section><title>Constructing &xml; trees</title> 
    43 <par>Like any other &xml; tree &api;, &xist; provides the usual classes:</par> 
    44 <ulist> 
     38</ul> 
     39</section> 
     40 
     41 
     42<section><h>Constructing &xml; trees</h> 
     43<p>Like any other &xml; tree &api;, &xist; provides the usual classes:</p> 
     44<ul> 
    4545<item><pyref module="ll.xist.xsc" class="Element"><class>Element</class></pyref> for &xml; elements;</item> 
    4646<item><pyref module="ll.xist.xsc" class="Attr"><class>Attr</class></pyref> for attributes;</item> 
     
    5757<item><pyref module="ll.xist.xsc" class="DocType"><class>DocType</class></pyref> for document type 
    5858declarations (e.g. <markup>&lt;!DOCTYPE html PUBLIC <rep>...</rep>&gt;</markup>).</item> 
    59 </ulist> 
    60  
    61 <section><title>&xml; trees as Python objects</title> 
    62 <par>&xist; works somewhat different from a normal &dom; &api;. 
     59</ul> 
     60 
     61<section><h>&xml; trees as Python objects</h> 
     62<p>&xist; works somewhat different from a normal &dom; &api;. 
    6363Instead of only one element class, &xist; has one class for every element 
    6464type. All the elements from different &xml; vocabularies known to &xist; are 
    65 defined in modules in the <pyref module="ll.xist.ns"><module>ll.xist.ns</module></pyref> 
     65defined in modules in the <pyref module="ll.xist.ns"><mod>ll.xist.ns</mod></pyref> 
    6666subpackage. (Of course it's possible to define additional element classes for your 
    6767own &xml; vocabulary). The definition of &html; can be found in 
    68 <pyref module="ll.xist.ns.html"><module>ll.xist.ns.html</module></pyref> 
    69 for example.</par> 
    70  
    71 <par>Every element class has a constructor of the form:</par> 
     68<pyref module="ll.xist.ns.html"><mod>ll.xist.ns.html</mod></pyref> 
     69for example.</p> 
     70 
     71<p>Every element class has a constructor of the form:</p> 
    7272<prog> 
    7373__init__(self, *content, **attrs) 
    7474</prog> 
    75 <par>Positional arguments (i.e. items in <arg>content</arg>) 
     75<p>Positional arguments (i.e. items in <arg>content</arg>) 
    7676will be the child nodes of the element node. Keyword arguments will be attributes. 
    7777You can pass most of Python's builtin types to such a constructor. 
     
    7979will be automatically converted to 
    8080<pyref module="ll.xist.xsc" class="Text"><class>Text</class></pyref> objects. 
    81 Constructing an &html; element works like this:</par> 
    82 <example><title>The first example</title> 
     81Constructing an &html; element works like this:</p> 
     82<example><h>The first example</h> 
    8383<prog> 
    8484from ll.xist.ns import html 
     
    9292</example> 
    9393 
    94 <par>For attribute names that collide with Python keywords 
     94<p>For attribute names that collide with Python keywords 
    9595or are not legal identifiers (most notably <lit>class</lit> in &html;) 
    9696the attribute name must be slightly modified, so that it's a legal 
    97 Python identifier (for <lit>class</lit> an underscore is appended):</par> 
    98 <example><title>Illegal attribute names</title> 
     97Python identifier (for <lit>class</lit> an underscore is appended):</p> 
     98<example><h>Illegal attribute names</h> 
    9999<prog> 
    100100node = html.div( 
     
    104104</prog> 
    105105</example> 
    106 <par>(Don't worry: This modified attribute name will be mapped to the real official attribute 
    107 name once the output is generated.)</par> 
    108  
    109 <par>You can pass attributes as a dictionary too:</par> 
    110 <example><title>Passing attributes as dictionaries</title> 
     106<p>(Don't worry: This modified attribute name will be mapped to the real official attribute 
     107name once the output is generated.)</p> 
     108 
     109<p>You can pass attributes as a dictionary too:</p> 
     110<example><h>Passing attributes as dictionaries</h> 
    111111<prog> 
    112112node = html.div( 
     
    117117</example> 
    118118 
    119 <par>Furthermore it's possible to use <lit>with</lit> blocks to construct 
     119<p>Furthermore it's possible to use <lit>with</lit> blocks to construct 
    120120&xist; trees. Inside a <lit>with</lit> block the unary <lit>+</lit> operator 
    121 or the <function>add</function> function can be used to add nodes or attributes 
    122 to the current level of the tree:</par> 
    123 <example><title>Using <lit>with</lit> blocks</title> 
     121or the <func>add</func> function can be used to add nodes or attributes 
     122to the current level of the tree:</p> 
     123<example><h>Using <lit>with</lit> blocks</h> 
    124124<prog> 
    125125with html.div(class_="quote") as node: 
     
    135135</section> 
    136136 
    137 <section><title>Generating &xml; trees from &xml; files</title> 
    138 <par>&xml; trees can also be generated by parsing &xml; files. 
    139 For this the module <pyref module="ll.xist.parsers"><module>ll.xist.parsers</module></pyref> 
    140 provides several functions:</par> 
    141 <dlist> 
     137<section><h>Generating &xml; trees from &xml; files</h> 
     138<p>&xml; trees can also be generated by parsing &xml; files. 
     139For this the module <pyref module="ll.xist.parsers"><mod>ll.xist.parsers</mod></pyref> 
     140provides several functions:</p> 
     141<dl> 
    142142<term><lit>parsestring(data, base=None, encoding=None, **builderargs)</lit></term> 
    143143<item>Parse the string <arg>data</arg> into an &xist; tree.</item> 
     
    153153<term><lit>parseetree(tree, base=None, **builderargs)</lit></term> 
    154154<item>Parse &xml; input from the object <arg>tree</arg> which must support the 
    155 <link href="http://effbot.org/zone/element-index.htm">ElementTree</link> &api;.</item> 
    156 </dlist> 
    157 <par>For example, parsing a string can be done like this:</par> 
    158 <example><title>Parsing a string</title> 
     155<a href="http://effbot.org/zone/element-index.htm">ElementTree</a> &api;.</item> 
     156</dl> 
     157<p>For example, parsing a string can be done like this:</p> 
     158<example><h>Parsing a string</h> 
    159159<prog> 
    160160from ll.xist import parsers 
     
    167167</example> 
    168168 
    169 <par>For further info about the arguments to the parsing functions, see the 
     169<p>For further info about the arguments to the parsing functions, see the 
    170170documentation for 
    171 <pyref module="ll.xist.parsers" class="Builder"><class>ll.xist.parsers.Builder</class></pyref>.</par> 
    172 </section> 
    173 </section> 
    174  
    175  
    176 <section><title>Defining new elements and converting &xml; trees</title> 
    177  
    178 <par>To be able to parse an &xml; file, you have to provide an element class 
     171<pyref module="ll.xist.parsers" class="Builder"><class>ll.xist.parsers.Builder</class></pyref>.</p> 
     172</section> 
     173</section> 
     174 
     175 
     176<section><h>Defining new elements and converting &xml; trees</h> 
     177 
     178<p>To be able to parse an &xml; file, you have to provide an element class 
    179179for every element type that appears in the file. These classes either come from 
    180180modules provided by &xist; or you can define your own. Defining your own 
    181 element class for an element named <lit>cool</lit> works like this:</par> 
    182  
    183 <example><title>Defining a new element</title> 
     181element class for an element named <lit>cool</lit> works like this:</p> 
     182 
     183<example><h>Defining a new element</h> 
    184184<prog> 
    185185class cool(xsc.Element): 
     
    190190</example> 
    191191 
    192 <par>You have to derive your new class from 
     192<p>You have to derive your new class from 
    193193<pyref module="ll.xist.xsc" class="Element"><class>xsc.Element</class></pyref>. 
    194194The name of the class will be the element name. For element type names that 
    195195are invalid Python identifiers, you can use the class attribute <lit>xmlname</lit> 
    196 in the element class to overwrite the element name.</par> 
    197 <par>To be able to convert an element of this type to a new &xml; tree 
     196in the element class to overwrite the element name.</p> 
     197<p>To be able to convert an element of this type to a new &xml; tree 
    198198(probably &html; in most cases), you have to implement the 
    199 <pyref module="ll.xist.xsc" class="Node" method="convert"><method>convert</method></pyref> 
     199<pyref module="ll.xist.xsc" class="Node" method="convert"><meth>convert</meth></pyref> 
    200200method. In this method you can build a new &xml; tree from the content and attributes 
    201 of the object.</par> 
    202  
    203 <par>Using this new element is simple</par> 
    204  
    205 <example><title>Using the new element</title> 
     201of the object.</p> 
     202 
     203<p>Using this new element is simple</p> 
     204 
     205<example><h>Using the new element</h> 
    206206<tty> 
    207207<prompt>&gt;&gt;&gt; </prompt><input>node = cool("Python")</input> 
     
    211211</example> 
    212212 
    213 <par><pyref module="ll.xist.xsc" class="Node" method="conv"><method>conv</method></pyref> simply 
     213<p><pyref module="ll.xist.xsc" class="Node" method="conv"><meth>conv</meth></pyref> simply 
    214214calls 
    215 <pyref module="ll.xist.xsc" class="Node" method="convert"><method>convert</method></pyref> 
     215<pyref module="ll.xist.xsc" class="Node" method="convert"><meth>convert</meth></pyref> 
    216216with a default <pyref module="ll.xist.converters" class="Converter"><arg>converter</arg></pyref> 
    217217argument. We'll come to converters in a minute. 
    218 <pyref module="ll.xist.xsc" class="Node" method="bytes"><method>bytes</method></pyref> 
     218<pyref module="ll.xist.xsc" class="Node" method="bytes"><meth>bytes</meth></pyref> 
    219219is a method that converts the node to a byte string. This method will be explained 
    220 when we discuss the publishing interface.</par> 
    221  
    222 <par>Note that it is vital for your own <method>convert</method> 
    223 methods that you recursively call <method>convert</method> 
     220when we discuss the publishing interface.</p> 
     221 
     222<p>Note that it is vital for your own <meth>convert</meth> 
     223methods that you recursively call <meth>convert</meth> 
    224224on your own content, because otherwise some unconverted nodes 
    225 might remain in the tree. Let's define a new element:</par> 
     225might remain in the tree. Let's define a new element:</p> 
    226226<prog> 
    227227class python(xsc.Element): 
     
    229229        return html.a(u"Python", href=u"http://www.python.org/") 
    230230</prog> 
    231 <par>Now we can do the following:</par> 
     231<p>Now we can do the following:</p> 
    232232<tty> 
    233233<prompt>&gt;&gt;&gt; </prompt><input>node = cool(python())</input> 
     
    235235&lt;b&gt;&lt;a href="http://www.python.org/"&gt;Python&lt;/a&gt; is cool!&lt;/b&gt; 
    236236</tty> 
    237 <par>But if we forget to call 
    238 <pyref module="ll.xist.xsc" class="Node" method="convert"><method>convert</method></pyref> 
     237<p>But if we forget to call 
     238<pyref module="ll.xist.xsc" class="Node" method="convert"><meth>convert</meth></pyref> 
    239239for our own content, i.e. if the element <pyref class="cool"><class>cool</class></pyref> 
    240 was written like this:</par> 
     240was written like this:</p> 
    241241<prog> 
    242242class cool(xsc.Element): 
     
    244244        return html.b(self.content, " is cool!") 
    245245</prog> 
    246 <par>we would get:</par> 
     246<p>we would get:</p> 
    247247<prog> 
    248248&gt;&gt;&gt; node = cool(python()) 
     
    251251</prog> 
    252252 
    253 <par>Furthermore <method>convert</method> should never modify <self/>, because 
    254 <method>convert</method> might be called multiple times for the same node.</par> 
    255  
    256 <section><title>Converters</title> 
    257 <par><pyref module="ll.xist.xsc" class="Node" method="conv"><method>conv</method></pyref> 
     253<p>Furthermore <meth>convert</meth> should never modify <self/>, because 
     254<meth>convert</meth> might be called multiple times for the same node.</p> 
     255 
     256<section><h>Converters</h> 
     257<p><pyref module="ll.xist.xsc" class="Node" method="conv"><meth>conv</meth></pyref> 
    258258is a convenience method that creates a default converter for you and calls 
    259 <pyref module="ll.xist.xsc" class="Node" method="convert"><method>convert</method></pyref>. 
    260 This converter is created once and is passed to all <method>convert</method> 
     259<pyref module="ll.xist.xsc" class="Node" method="convert"><meth>convert</meth></pyref>. 
     260This converter is created once and is passed to all <meth>convert</meth> 
    261261calls. It is used to store parameters for the conversion process and it allows 
    262 <method>convert</method> methods to store additional information, so that it is 
     262<meth>convert</meth> methods to store additional information, so that it is 
    263263available elsewhere during the conversion process. You can also call 
    264 <pyref module="ll.xist.xsc" class="Node" method="convert"><method>convert</method></pyref> 
    265 yourself, which would look like this:</par> 
     264<pyref module="ll.xist.xsc" class="Node" method="convert"><meth>convert</meth></pyref> 
     265yourself, which would look like this:</p> 
    266266 
    267267<prog> 
     
    273273</prog> 
    274274 
    275 <par>You can pass the following arguments to the 
    276 <pyref module="ll.xist.converters" class="Converter"><class>Converter</class></pyref> constructor:</par> 
    277 <dlist> 
     275<p>You can pass the following arguments to the 
     276<pyref module="ll.xist.converters" class="Converter"><class>Converter</class></pyref> constructor:</p> 
     277<dl> 
    278278<term><arg>root</arg></term><item><arg>root</arg> (which defaults to <lit>None</lit>) is the root &url; 
    279 for the conversion process. When you want to resolve a link in some of your own <method>convert</method> methods, 
     279for the conversion process. When you want to resolve a link in some of your own <meth>convert</meth> methods, 
    280280the &url; must be interpreted relative to this root &url; (You can use 
    281 <pyref module="ll.xist.xsc" class="URLAttr" method="forInput"><method>URLAttr.forInput</method></pyref> 
     281<pyref module="ll.xist.xsc" class="URLAttr" method="forInput"><meth>URLAttr.forInput</meth></pyref> 
    282282for that).</item> 
    283283<term><arg>mode</arg></term><item><arg>mode</arg> (which defaults to <lit>None</lit>) works the same way 
     
    295295and would be converted to &html; on every request.</item> 
    296296<term><arg>target</arg></term><item><arg>target</arg> (which defaults to 
    297 <pyref module="ll.xist.ns.html"><module>ll.xist.ns.html</module></pyref>) specifies what the output should be. 
     297<pyref module="ll.xist.ns.html"><mod>ll.xist.ns.html</mod></pyref>) specifies what the output should be. 
    298298Values must be <pyref module="ll.xist.xsc" class="Namespace">namespace subclasses</pyref> 
    299299(see below for an explanation of namespaces).</item> 
    300 <term><arg>lang</arg></term><item><par><arg>lang</arg> (which defaults to <lit>None</lit>) is the language 
    301 in which the result tree should be. This can be used in the <method>convert</method> method 
    302 to implement different conversions for different languages, e.g.:</par> 
     300<term><arg>lang</arg></term><item><p><arg>lang</arg> (which defaults to <lit>None</lit>) is the language 
     301in which the result tree should be. This can be used in the <meth>convert</meth> method 
     302to implement different conversions for different languages, e.g.:</p> 
    303303<prog> 
    304304class note(xsc.Element): 
     
    317317</prog> 
    318318</item> 
    319 </dlist> 
    320  
    321 <par>Additional arguments are passed when a converter is created in the context of 
    322 a <pyref module="ll.make"><module>make</module></pyref> script.</par> 
    323  
    324 </section> 
    325  
    326 <section><title>Attributes</title> 
    327 <par>Setting and accessing the attributes of an element works either via 
     319</dl> 
     320 
     321<p>Additional arguments are passed when a converter is created in the context of 
     322a <pyref module="ll.make"><mod>make</mod></pyref> script.</p> 
     323 
     324</section> 
     325 
     326<section><h>Attributes</h> 
     327<p>Setting and accessing the attributes of an element works either via 
    328328a dictionary interface or by accessing the &xml; attributes as Python attributes 
    329 of the elements <lit>attrs</lit> attribute:</par> 
     329of the elements <lit>attrs</lit> attribute:</p> 
    330330<example> 
    331331<tty> 
     
    342342</example> 
    343343 
    344 <par>All attribute values are instances of subclasses of the class 
     344<p>All attribute values are instances of subclasses of the class 
    345345<pyref module="ll.xist.xsc" class="Attr"><class>Attr</class></pyref>. 
    346 Available subclasses are:</par> 
    347  
    348 <ulist> 
     346Available subclasses are:</p> 
     347 
     348<ul> 
    349349<item><pyref module="ll.xist.xsc" class="TextAttr"><class>TextAttr</class></pyref>, for normal text attributes;</item> 
    350350<item><pyref module="ll.xist.xsc" class="URLAttr"><class>URLAttr</class></pyref>, for attributes that are &url;s;</item> 
     
    353353<item><pyref module="ll.xist.xsc" class="IntAttr"><class>IntAttr</class></pyref>, for integer attributes;</item> 
    354354<item><pyref module="ll.xist.xsc" class="ColorAttr"><class>ColorAttr</class></pyref>, for color attributes (e.g. <lit>#ffffff</lit>).</item> 
    355 </ulist> 
    356  
    357 <par><class>IntAttr</class> and <class>ColorAttr</class> mostly serve as documentation 
    358 of the attributes purpose. Both classes have no added functionality.</par> 
    359  
    360 <par><pyref module="ll.xist.xsc" class="Attr"><class>Attr</class></pyref> itself is derived from 
     355</ul> 
     356 
     357<p><class>IntAttr</class> and <class>ColorAttr</class> mostly serve as documentation 
     358of the attributes purpose. Both classes have no added functionality.</p> 
     359 
     360<p><pyref module="ll.xist.xsc" class="Attr"><class>Attr</class></pyref> itself is derived from 
    361361<pyref module="ll.xist.xsc" class="Frag"><class>Frag</class></pyref> so it is possible 
    362 to use all the sequence methods on an attribute.</par> 
    363  
    364 <par>Unset attributes will be treated like empty ones so the following is possible:</par> 
     362to use all the sequence methods on an attribute.</p> 
     363 
     364<p>Unset attributes will be treated like empty ones so the following is possible:</p> 
    365365 
    366366<example> 
     
    371371</example> 
    372372 
    373 <par>This also means that after <lit>del node["spam"][:]</lit> the attribute 
     373<p>This also means that after <lit>del node["spam"][:]</lit> the attribute 
    374374will be empty again and will be considered to be unset. 
    375 Such attributes will be skipped when publishing.</par> 
    376  
    377 <par>The main purpose of this is to allow you to construct values conditionally 
    378 and then use those values as attribute values:</par> 
     375Such attributes will be skipped when publishing.</p> 
     376 
     377<p>The main purpose of this is to allow you to construct values conditionally 
     378and then use those values as attribute values:</p> 
    379379 
    380380<prog> 
     
    389389</prog> 
    390390 
    391 <par>In 50% of the cases the generated <class>div</class> element will not 
    392 have a <lit>class</lit> attribute.</par> 
    393  
    394 <section><title>Defining attributes</title> 
    395  
    396 <par>When you define a new element you have to specify the attributes allowed 
     391<p>In 50% of the cases the generated <class>div</class> element will not 
     392have a <lit>class</lit> attribute.</p> 
     393 
     394<section><h>Defining attributes</h> 
     395 
     396<p>When you define a new element you have to specify the attributes allowed 
    397397for this element. For this use the class attribute <lit>Attrs</lit> 
    398398(which must be a class derived from 
    399399<pyref module="ll.xist.xsc" class="Element.Attrs"><class>xsc.Element.Attrs</class></pyref>) 
    400400and define the attributes by deriving them from one of the existing attribute classes. 
    401 We could extend our example element in the following way:</par> 
    402  
    403 <example><title>Using attributes</title> 
     401We could extend our example element in the following way:</p> 
     402 
     403<example><h>Using attributes</h> 
    404404<prog> 
    405405class cool(xsc.Element): 
     
    416416</example> 
    417417 
    418 <par>and use it like this:</par> 
     418<p>and use it like this:</p> 
    419419 
    420420<tty> 
     
    427427 
    428428 
    429 <section><title>Default attributes</title> 
    430 <par>It is possible to define default values for attributes via 
    431 the class attribute <lit>default</lit>:</par> 
    432  
    433 <example><title>Defining default attributes</title> 
     429<section><h>Default attributes</h> 
     430<p>It is possible to define default values for attributes via 
     431the class attribute <lit>default</lit>:</p> 
     432 
     433<example><h>Defining default attributes</h> 
    434434<prog> 
    435435class cool(xsc.Element): 
     
    447447</example> 
    448448 
    449 <par>Now if we instantiate the class without specifying 
    450 <lit>adj</lit> we'll get the default:</par> 
    451  
    452 <example><title>Using default attributes</title> 
     449<p>Now if we instantiate the class without specifying 
     450<lit>adj</lit> we'll get the default:</p> 
     451 
     452<example><h>Using default attributes</h> 
    453453<tty> 
    454454<prompt>&gt;&gt;&gt; </prompt><input>node = cool(python())</input> 
     
    458458</example> 
    459459 
    460 <par>If we want a <class>cool</class> instance without 
     460<p>If we want a <class>cool</class> instance without 
    461461an <lit>adj</lit> attribute, we can pass <lit>None</lit> 
    462 as the attribute value:</par> 
    463  
    464 <example><title>Removing default attributes</title> 
     462as the attribute value:</p> 
     463 
     464<example><h>Removing default attributes</h> 
    465465<tty> 
    466466<prompt>&gt;&gt;&gt; </prompt><input>node = cool(python(), adj=None)</input> 
     
    472472</section> 
    473473 
    474 <section><title>Allowed attribute values</title> 
    475 <par>It's possible to specify that an attribute has a fixed set of allowed 
     474<section><h>Allowed attribute values</h> 
     475<p>It's possible to specify that an attribute has a fixed set of allowed 
    476476values. This can be done with the class attribute <lit>values</lit>. We could 
    477 extend our example to look like this:</par> 
    478  
    479 <example><title>Defining allowed attribute values</title> 
     477extend our example to look like this:</p> 
     478 
     479<example><h>Defining allowed attribute values</h> 
    480480<prog> 
    481481class cool(xsc.Element): 
     
    494494</example> 
    495495 
    496 <par>These values won't be checked when we create our <class>cool</class> 
     496<p>These values won't be checked when we create our <class>cool</class> 
    497497instance. Only when this node is parsed from a file will the warning 
    498 be issued:</par> 
     498be issued:</p> 
    499499 
    500500<tty> 
     
    505505</tty> 
    506506 
    507 <par>The warning will also be issued if we publish such a node, 
     507<p>The warning will also be issued if we publish such a node, 
    508508but note that for warnings Python's warning framework is used, 
    509509so the warning will be printed only once (but of course 
    510 you can change that with <function>warnings.filterwarnings</function>):</par> 
     510you can change that with <func>warnings.filterwarnings</func>):</p> 
    511511 
    512512<tty> 
     
    520520</section> 
    521521 
    522 <section><title>Required attributes</title> 
    523 <par>Finally it's possible to specify that an attribute is required. 
     522<section><h>Required attributes</h> 
     523<p>Finally it's possible to specify that an attribute is required. 
    524524This again will only be checked when parsing or publishing. To specify that an 
    525525attribute is required simply add the class attribute <lit>required</lit> 
    526526with the value <lit>True</lit>. The attribute <lit>alt</lit> of the 
    527527class <pyref module="ll.xist.ns.html" class="img"><class>ll.xist.ns.html.img</class></pyref> 
    528 is such an attribute, so we'll get:</par> 
    529  
    530 <example><title>Missing required attributes</title> 
     528is such an attribute, so we'll get:</p> 
     529 
     530<example><h>Missing required attributes</h> 
    531531<tty> 
    532532<prompt>&gt;&gt;&gt; </prompt><input>from ll.xist.ns import html</input> 
     
    543543</section> 
    544544 
    545 <section><title>Namespaces and pools</title> 
    546  
    547 <par>Now that you've defined your own elements, you have to tell the parser 
     545<section><h>Namespaces and pools</h> 
     546 
     547<p>Now that you've defined your own elements, you have to tell the parser 
    548548about them, so they can be instantiated when a file is parsed. First you have to 
    549549assign an &xml; namespace to these classes. This is done by setting the class 
    550 attribute <lit>xmlns</lit> to the namespace name:</par> 
    551  
    552 <example><title>Assigning a namespace to elements</title> 
     550attribute <lit>xmlns</lit> to the namespace name:</p> 
     551 
     552<example><h>Assigning a namespace to elements</h> 
    553553<prog> 
    554554from ll.xist import xsc, parsers 
     
    572572</example> 
    573573 
    574 <par>When parsing the parser fetches the classes it uses from a <class>Pool</class> 
    575 object. We can put our two classes into a pool like this:</par> 
    576  
    577 <example><title>Putting elements in a pool</title> 
     574<p>When parsing the parser fetches the classes it uses from a <class>Pool</class> 
     575object. We can put our two classes into a pool like this:</p> 
     576 
     577<example><h>Putting elements in a pool</h> 
    578578<prog> 
    579579pool = xsc.Pool(python, cool) 
     
    581581</example> 
    582582 
    583 <par>It's also possible to register the element classes in a pool directly at 
    584 class construction time via a <lit>with</lit> block like this:</par> 
    585  
    586 <example><title>Populating a pool with a <lit>with</lit> block</title> 
     583<p>It's also possible to register the element classes in a pool directly at 
     584class construction time via a <lit>with</lit> block like this:</p> 
     585 
     586<example><h>Populating a pool with a <lit>with</lit> block</h> 
    587587<prog> 
    588588from __future__ import with_statement 
     
    609609</example> 
    610610 
    611 <par>Now you can use this pool for parsing:</par> 
    612  
    613 <example><title>Parsing &xml;</title> 
     611<p>Now you can use this pool for parsing:</p> 
     612 
     613<example><h>Parsing &xml;</h> 
    614614<prog><![CDATA[ 
    615615s = '<cool xmlns="http://xmlns.example.org/foo"><python/></cool>' 
     
    619619</example> 
    620620 
    621 <par>It's also possible to call the parsing function with a predefined mapping 
    622 between namespace names and namespace prefixes:</par> 
    623  
    624 <example><title>Parsing &xml; with predefined prefix mapping</title> 
     621<p>It's also possible to call the parsing function with a predefined mapping 
     622between namespace names and namespace prefixes:</p> 
     623 
     624<example><h>Parsing &xml; with predefined prefix mapping</h> 
    625625<prog><![CDATA[ 
    626626s = '<cool><python/></cool>' 
     
    630630</example> 
    631631 
    632 <par>If you have many elements, registering them in a pool becomes cumbersome. 
     632<p>If you have many elements, registering them in a pool becomes cumbersome. 
    633633In this case you can put your element classes into a module and then 
    634 register the module in the pool:</par> 
    635  
    636 <example><title>Registering modules in a pool</title> 
     634register the module in the pool:</p> 
     635 
     636<example><h>Registering modules in a pool</h> 
    637637<prog> 
    638638import foo_xmlns # This is the module containing the element classes 
     
    644644</section> 
    645645 
    646 <section><title>Global attributes</title> 
    647 <par>You can define global attributes belonging to a certain namespace by defining 
     646<section><h>Global attributes</h> 
     647<p>You can define global attributes belonging to a certain namespace by defining 
    648648a global <class>Attrs</class> class and giving each attribute a namespace name 
    649 via <lit>xmlns</lit>:</par> 
     649via <lit>xmlns</lit>:</p> 
    650650 
    651651<prog> 
     
    655655</prog> 
    656656 
    657 <par>To make this global attribute know to the parsing, you simply can put 
    658 the <class>Attrs</class> in the pool used for parsing.</par> 
    659  
    660 <par>Setting and accessing such an attribute can be done by using the 
    661 attribute class instead of the attribute name like this:</par> 
     657<p>To make this global attribute know to the parsing, you simply can put 
     658the <class>Attrs</class> in the pool used for parsing.</p> 
     659 
     660<p>Setting and accessing such an attribute can be done by using the 
     661attribute class instead of the attribute name like this:</p> 
    662662 
    663663<tty> 
     
    668668</tty> 
    669669 
    670 <par>An alternate way of specifying a global attribute in a constructor looks 
    671 like this:</par> 
     670<p>An alternate way of specifying a global attribute in a constructor looks 
     671like this:</p> 
    672672 
    673673<tty> 
     
    680680</section> 
    681681 
    682 <section><title>Entities</title> 
    683  
    684 <par>In the same way as defining new element types, you can define new entities. 
     682<section><h>Entities</h> 
     683 
     684<p>In the same way as defining new element types, you can define new entities. 
    685685The following example is from the module 
    686 <pyref module="ll.xist.ns.abbr"><module>ll.xist.ns.abbr</module></pyref>:</par> 
    687  
    688 <example><title>Defining new entities</title> 
     686<pyref module="ll.xist.ns.abbr"><mod>ll.xist.ns.abbr</mod></pyref>:</p> 
     687 
     688<example><h>Defining new entities</h> 
    689689<prog> 
    690690from ll.xist import xsc 
     
    701701</example> 
    702702 
    703 <par>You can use this entity in your &xml; files like this:</par> 
    704  
    705 <example><title>Using the newly defined entity</title> 
     703<p>You can use this entity in your &xml; files like this:</p> 
     704 
     705<example><h>Using the newly defined entity</h> 
    706706<prog> 
    707707&lt;cool adj="very"&gt;&amp;html;&lt;/cool&gt; 
     
    711711</section> 
    712712 
    713 <section><title>Processing instructions</title> 
    714 <par>Defining processing instructions works just like elements and entities. 
     713<section><h>Processing instructions</h> 
     714<p>Defining processing instructions works just like elements and entities. 
    715715Derive a new class from 
    716716<pyref module="ll.xist.xsc" class="ProcInst"><class>ll.xist.xsc.ProcInst</class></pyref> 
    717 and implement <pyref module="ll.xist.xsc" class="Node" method="convert"><method>convert</method></pyref>. 
     717and implement <pyref module="ll.xist.xsc" class="Node" method="convert"><meth>convert</meth></pyref>. 
    718718The following example implements a processing instruction that returns an 
    719 uppercase version of its content as a text node.</par> 
    720  
    721 <example><title>Defining new processing instructions</title> 
     719uppercase version of its content as a text node.</p> 
     720 
     721<example><h>Defining new processing instructions</h> 
    722722<prog> 
    723723class upper(xsc.ProcInst): 
     
    727727</example> 
    728728 
    729 <par>It can be used in an &xml; file like this:</par> 
    730  
    731 <example><title>Using the newly defined processing instruction</title> 
     729<p>It can be used in an &xml; file like this:</p> 
     730 
     731<example><h>Using the newly defined processing instruction</h> 
    732732<prog> 
    733733&lt;cool&gt;&lt;?upper foo?&gt;&lt;/cool&gt; 
     
    735735</example> 
    736736 
    737 <par>There are namespaces containing processing instruction classes that don't 
    738 provide a <method>convert</method> method. These processing instruction objects 
     737<p>There are namespaces containing processing instruction classes that don't 
     738provide a <meth>convert</meth> method. These processing instruction objects 
    739739will then be published as &xml; processing instructions. One example is the 
    740 namespace <pyref module="ll.xist.ns.php"><module>ll.xist.ns.php</module></pyref>.</par> 
    741  
    742 <par>Other namespaces (like <pyref module="ll.xist.ns.jsp"><module>ll.xist.ns.jsp</module></pyref>) 
     740namespace <pyref module="ll.xist.ns.php"><mod>ll.xist.ns.php</mod></pyref>.</p> 
     741 
     742<p>Other namespaces (like <pyref module="ll.xist.ns.jsp"><mod>ll.xist.ns.jsp</mod></pyref>) 
    743743contain processing instruction classes, but they will be published in a different 
    744744(not &xml; compatible) format. For example <lit>ll.xist.ns.jsp.expression("foo")</lit> 
    745 will be published as <lit>&lt;%= foo&gt;</lit>.</par> 
    746  
    747 </section> 
    748  
    749 </section> 
    750  
    751  
    752 <section><title>Publishing &xml; trees</title> 
    753  
    754 <par>After creating the &xml; tree and converting the tree 
     745will be published as <lit>&lt;%= foo&gt;</lit>.</p> 
     746 
     747</section> 
     748 
     749</section> 
     750 
     751 
     752<section><h>Publishing &xml; trees</h> 
     753 
     754<p>After creating the &xml; tree and converting the tree 
    755755into its final output form, you have to write the resulting tree 
    756756to a file. This can be done with the publishing &api;. Three methods 
    757757that use the publishing &api; are 
    758 <pyref module="ll.xist.xsc" class="Node" method="iterbytes"><method>iterbytes</method></pyref>, 
    759 <pyref module="ll.xist.xsc" class="Node" method="bytes"><method>bytes</method></pyref> 
     758<pyref module="ll.xist.xsc" class="Node" method="iterbytes"><meth>iterbytes</meth></pyref>, 
     759<pyref module="ll.xist.xsc" class="Node" method="bytes"><meth>bytes</meth></pyref> 
    760760and 
    761 <pyref module="ll.xist.xsc" class="Node" method="write"><method>write</method></pyref>. 
    762 <pyref module="ll.xist.xsc" class="Node" method="bytes"><method>iterbytes</method></pyref> 
     761<pyref module="ll.xist.xsc" class="Node" method="write"><meth>write</meth></pyref>. 
     762<pyref module="ll.xist.xsc" class="Node" method="bytes"><meth>iterbytes</meth></pyref> 
    763763is a generator that will yield the complete 8-bit &xml; string in fragments. 
    764 <pyref module="ll.xist.xsc" class="Node" method="bytes"><method>bytes</method></pyref> 
    765 returns the complete 8-bit &xml; string.</par> 
    766  
    767 <par>Writing a node to a file can be done with the method 
    768 <pyref module="ll.xist.xsc" class="Node" method="write"><method>write</method></pyref>:</par> 
     764<pyref module="ll.xist.xsc" class="Node" method="bytes"><meth>bytes</meth></pyref> 
     765returns the complete 8-bit &xml; string.</p> 
     766 
     767<p>Writing a node to a file can be done with the method 
     768<pyref module="ll.xist.xsc" class="Node" method="write"><meth>write</meth></pyref>:</p> 
    769769 
    770770<tty> 
     
    774774</tty> 
    775775 
    776 <par>All these methods use the method 
    777 <pyref module="ll.xist.xsc" class="Node" method="publish"><method>publish</method></pyref> internally. 
    778 <pyref module="ll.xist.xsc" class="Node" method="publish"><method>publish</method></pyref> gets passed 
    779 an instance of <pyref module="ll.xist.publishers" class="Publisher"><class>ll.xist.publisher.Publisher</class></pyref>.</par> 
    780  
    781 <section><title>Specifying an encoding</title> 
    782 <par>You can specify the encoding with the parameter <arg>encoding</arg> 
     776<p>All these methods use the method 
     777<pyref module="ll.xist.xsc" class="Node" method="publish"><meth>publish</meth></pyref> internally. 
     778<pyref module="ll.xist.xsc" class="Node" method="publish"><meth>publish</meth></pyref> gets passed 
     779an instance of <pyref module="ll.xist.publishers" class="Publisher"><class>ll.xist.publisher.Publisher</class></pyref>.</p> 
     780 
     781<section><h>Specifying an encoding</h> 
     782<p>You can specify the encoding with the parameter <arg>encoding</arg> 
    783783(with the encoding specified in an &xml; declaration being the default, if there 
    784784is no such declaration <lit>"utf-8"</lit> is used). Unencodable characters will 
    785785be escaped with character references when possible (i.e. inside text nodes, for 
    786 comments or processing instructions you'll get an exception):</par> 
     786comments or processing instructions you'll get an exception):</p> 
    787787 
    788788<tty> 
     
    813813</tty> 
    814814 
    815 <par>When you include an <pyref module="ll.xist.ns.xml" class="XML">&xml; header</pyref> 
     815<p>When you include an <pyref module="ll.xist.ns.xml" class="XML">&xml; header</pyref> 
    816816or an <pyref module="ll.xist.ns.meta" class="contenttype">&html; meta header</pyref>, 
    817 &xist; will automatically insert the correct encoding when publishing:</par> 
     817&xist; will automatically insert the correct encoding when publishing:</p> 
    818818 
    819819<tty> 
     
    827827</section> 
    828828 
    829 <section><title>&html; compatibility</title> 
    830 <par>Another useful parameter is <arg>xhtml</arg>, 
    831 it specifies whether you want pure &html; or &xhtml; as output:</par> 
    832  
    833 <dlist> 
     829<section><h>&html; compatibility</h> 
     830<p>Another useful parameter is <arg>xhtml</arg>, 
     831it specifies whether you want pure &html; or &xhtml; as output:</p> 
     832 
     833<dl> 
    834834<term><lit>xhtml==0</lit></term><item>This will give you pure &html;, i.e. no 
    835835final <lit>/</lit> for elements with an empty content model, so you'll get e.g. 
     
    843843element will be published with an empty tag (without an additional space): 
    844844<markup>&lt;br/&gt;</markup> or <markup>&lt;div/&gt;</markup>.</item> 
    845 </dlist> 
    846 </section> 
    847  
    848 <section><title>Namespaces</title> 
    849  
    850 <par>By default &xist; doesn't output any namespace declarations. The simplest 
     845</dl> 
     846</section> 
     847 
     848<section><h>Namespaces</h> 
     849 
     850<p>By default &xist; doesn't output any namespace declarations. The simplest 
    851851way to change that, is to pass <lit>True</lit> for the <arg>prefixdefault</arg>