comparison MoinMoin/items/__init__.py @ 298:07143bd03aed

fix pygments converter call for new converter api
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Sun, 31 Jul 2011 17:24:22 +0200
parents ebdfe9448e01
children fed6024028b4 0fd6527bd6aa
comparison
equal deleted inserted replaced
297:0adc626b1036 298:07143bd03aed
1131 from MoinMoin.converter import default_registry as reg 1131 from MoinMoin.converter import default_registry as reg
1132 data_text = self.data_storage_to_internal(self.data) 1132 data_text = self.data_storage_to_internal(self.data)
1133 # TODO: use registry as soon as it is in there 1133 # TODO: use registry as soon as it is in there
1134 from MoinMoin.converter.pygments_in import Converter as PygmentsConverter 1134 from MoinMoin.converter.pygments_in import Converter as PygmentsConverter
1135 pygments_conv = PygmentsConverter(contenttype=self.contenttype) 1135 pygments_conv = PygmentsConverter(contenttype=self.contenttype)
1136 doc = pygments_conv(data_text.split(u'\n')) 1136 doc = pygments_conv(data_text)
1137 # TODO: Real output format 1137 # TODO: Real output format
1138 html_conv = reg.get(type_moin_document, Type('application/x-xhtml-moin-page')) 1138 html_conv = reg.get(type_moin_document, Type('application/x-xhtml-moin-page'))
1139 doc = html_conv(doc) 1139 doc = html_conv(doc)
1140 return conv_serialize(doc, {html.namespace: ''}) 1140 return conv_serialize(doc, {html.namespace: ''})
1141 1141