TextileField
[fnpdjango.git] / fnpdjango / utils / text / textilepl.py
1 from textile import Textile
2
3
4 class TextilePL(Textile):
5     """Polish version of Textile.
6
7     Changes opening quote to Polish lower-double.
8     """
9     glyph_definitions = dict(Textile.glyph_definitions,
10         quote_double_open = '„'
11     )
12
13
14 def textile_pl(text):
15     return TextilePL().parse(text)
16
17
18 def textile_restricted_pl(text):
19     return TextilePL(restricted=True, lite=True,
20                    noimage=True, auto_link=False).parse(
21                         text, rel='nofollow')