diff options
author | gbrandl <devnull@localhost> | 2007-01-25 20:00:35 +0100 |
---|---|---|
committer | gbrandl <devnull@localhost> | 2007-01-25 20:00:35 +0100 |
commit | 1699701fd132c19974be66c5664a88a90a32a3d2 (patch) | |
tree | 7163ddc984cb36c862979a5f5f86bc4a4e85eaff /pygments/formatter.py | |
parent | 8661de37c9a04da977fd8da8542e36115ee83fb2 (diff) | |
download | pygments-1699701fd132c19974be66c5664a88a90a32a3d2.tar.gz |
[svn] - add missing example files
- add "outencoding" option to formatters
- improve cmdline error reporting
Diffstat (limited to 'pygments/formatter.py')
-rw-r--r-- | pygments/formatter.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pygments/formatter.py b/pygments/formatter.py index 41959565..4e07f0f4 100644 --- a/pygments/formatter.py +++ b/pygments/formatter.py @@ -44,6 +44,8 @@ class Formatter(object): output. If it is "" or None, Unicode strings will be written to the output file, which most file-like objects do not support (default: None). + ``outencoding`` + Overrides ``encoding`` if given. """ #: If True, this formatter outputs Unicode strings when no encoding @@ -55,6 +57,7 @@ class Formatter(object): self.full = get_bool_opt(options, 'full', False) self.title = options.get('title', '') self.encoding = options.get('encoding', None) or None + self.encoding = options.get('outencoding', None) or self.encoding self.options = options def get_style_defs(self, arg=''): |