Modify ↓
Opened 15 years ago
Closed 14 years ago
#8710 closed defect (fixed)
Change default encoding for mimeview to UTF-8 from ISO-8859-15
Reported by: | Owned by: | Christian Boos | |
---|---|---|---|
Priority: | normal | Milestone: | 1.0 |
Component: | rendering | Version: | 0.11.5 |
Severity: | trivial | Keywords: | unicode |
Cc: | Branch: | ||
Release Notes: |
|
||
API Changes: | |||
Internal Changes: |
Description
This is patch from Debian package http://packages.debian.org/sid/trac
-
trac/mimeview/api.py
#! /bin/sh /usr/share/dpatch/dpatch-run ## 30_default_charset_utf8.dpatch by <wmb@beron.tangosoft.com> ## ## All lines beginning with `## DP:' are a description of the patch. ## DP: Use UTF-8 as default charset @DPATCH@ diff -uraN trac-0.11.5.orig/trac/mimeview/api.py trac-0.11.5/trac/mimeview/api.py
old new 579 579 annotators = ExtensionPoint(IHTMLPreviewAnnotator) 580 580 converters = ExtensionPoint(IContentConverter) 581 581 582 default_charset = Option('trac', 'default_charset', ' iso-8859-15',582 default_charset = Option('trac', 'default_charset', 'utf-8', 583 583 """Charset to be used when in doubt.""") 584 584 585 585 tab_width = IntOption('mimeviewer', 'tab_width', 8,
Attachments (0)
Change History (4)
comment:1 by , 15 years ago
Component: | general → rendering |
---|---|
Keywords: | unicode added |
Milestone: | → 0.12.1 |
comment:3 by , 14 years ago
Milestone: | next-minor-0.12.x → 0.13 |
---|---|
Owner: | set to |
Release Notes: | modified (diff) |
No changes to defaults on minor releases.
comment:4 by , 14 years ago
Resolution: | → fixed |
---|---|
Severity: | normal → trivial |
Status: | new → closed |
Done in r10426.
Note:
See TracTickets
for help on using tickets.
'utf-8' is not as safe as a default as 'iso-8859-15' is (any byte sequence can be converted to unicode when using 'iso-8859-15', which is not the case for 'utf-8').
But I agree that 'utf-8' is probably a more useful default than 'iso-8859-15' is.
So first we would have to try if changing this setting wouldn't result in UnicodeEncode exceptions in places this
default_charset
setting is used.