;ò
EëÚDc           @   s»   d  Z  d k Z d „  Z d e d d „ Z h  d d <d d	 <d
 d <d d <d d <d d <d d <d d <d d <d d <d d <d d <d d <d  d! <Z d" „  Z d S(#   sA   
   Copyright (C) 2005 PimenTech SARL (http://www.pimentech.net)

   This library is free software; you can redistribute it and/or
   modify it under the terms of the GNU Library General Public License as
   published by the Free Software Foundation; either version 2 of the
   License, or (at your option) any later version.

   This library is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   Library General Public License for more details.

   You should have received a copy of the GNU Library General Public
   License along with this library; see the file COPYING.LIB.  If not,
   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
   Boston, MA 02111-1307, USA.  
Nc         C   sh   |  o d Sn |  i d ƒ } | d j o |  Sn |  i d | ƒ } |  i d ƒ } |  | d | !Sd S(   s    HTML text without headers s    s   <bodyiÿÿÿÿs   >s   </body>i   N(   s	   html_texts   finds   starts   end(   s	   html_texts   starts   end(    (    s	   common.pys   strip_html_bodies   s     s   %d %b %Y %Hh%Ms   -c         C   s?   | o | Sn | i | ƒ } | o | i | ƒ Sn | Sd S(   s    auto string.strftime N(   s   dates   ifnones   strftimes   formats   date_fs   encodings   encode(   s
   zopeobjects   dates   formats   encodings   ifnones   date_f(    (    s	   common.pys   autostrftime#   s     s   #s   \#s   $s   \$s   %s   \%s   &s   \&s   ~s   \textasciitilde{}s   _s   \textunderscore{}s   ^s   \textasciicircum{}s   \s   \textbackslash{}s   {s   \textbraceleft{}s   }s   \textbraceright{}s   |s   $|$s   <s   $<$s   >s   $>$s   
s   \crlf
c         C   s-   | o d Sn d i t d „  | ƒ ƒ Sd S(   s/    Escape special characters in a ConTeXt string s    c         C   s   t  i |  |  ƒ S(   N(   s   context_special_charss   gets   x(   s   x(    (    s	   common.pys   <lambda>?   s    N(   s   texts   joins   map(   s
   zopeobjects   text(    (    s	   common.pys   escape_context;   s     (   s   __doc__s   DateTimes   strip_html_bodiess   Nones   autostrftimes   context_special_charss   escape_context(   s   strip_html_bodiess   escape_contexts   autostrftimes   DateTimes   context_special_chars(    (    s	   common.pys   ?   s
   			„
