Home | History | Annotate | Download | only in Lib

Lines Matching refs:encoding

464     def formatyearpage(self, theyear, width=3, css='calendar.css', encoding=None):

468 if encoding is None:
469 encoding = sys.getdefaultencoding()
472 a('<?xml version="1.0" encoding="%s"?>\n' % encoding)
476 a('<meta http-equiv="Content-Type" content="text/html; charset=%s" />\n' % encoding)
485 encoding, "xmlcharrefreplace")
505 an encoding all strings containing month and weekday names will be returned
516 with TimeEncoding(self.locale) as encoding:
522 if encoding is not None:
523 name = name.decode(encoding)
527 with TimeEncoding(self.locale) as encoding:
529 if encoding is not None:
530 s = s.decode(encoding)
540 an encoding all strings containing month and weekday names will be returned
550 with TimeEncoding(self.locale) as encoding:
552 if encoding is not None:
553 s = s.decode(encoding)
557 with TimeEncoding(self.locale) as encoding:
559 if encoding is not None:
560 s = s.decode(encoding)
654 "-e", "--encoding",
655 dest="encoding", default=None,
656 help="Encoding to use for output"
667 if options.locale and not options.encoding:
668 parser.error("if --locale is specified --encoding is required")
671 locale = options.locale, options.encoding
678 encoding = options.encoding
679 if encoding is None:
680 encoding = sys.getdefaultencoding()
681 optdict = dict(encoding=encoding, css=options.css)
707 if options.encoding:
708 result = result.encode(options.encoding)