codepope / augurx

Automatically exported from code.google.com/p/augurx
0 stars 0 forks source link

Euro symbol displays a &euro, not € #1

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. perform a sync to CiX when a message contains a € symbol (or other
character not in ISO Latin 1 but in CP1252)
2. display the message

What is the expected output? What do you see instead?
Expected output is €, observed output is &euro or & followed by other
symbol name

What version of the product are you using? On what operating system?
Unlabeled pre upload version on Ubuntu w/ Java 1.5.0_08 and with
-Dfile.encoding=Cp1252

Please provide any additional information below.

Original issue reported on code.google.com by adam.a.b...@gmail.com on 4 Jan 2007 at 8:25

GoogleCodeExporter commented 9 years ago
Diagnosis

The reason this is happening is because AugurX uses the Swing HTML EditorKit to 
display messages, so the € 
symbol is first translated to € , this in turn appears in the display as 
&euro as the HTML editorkit has no 
idea how to display it. 

If you look in a message with the € in the subject line, you can see the € 
correctly displayed in the message 
trees.

Resolution?

I don't rightly know; it's really down to can we replace the Swing HTML pane 
with something that at least 
knows it's the 21st century. 

Otherwise it's go back and replace all the formatting and display with some 
other mechanism.

Original comment by codep...@gmail.com on 5 Jan 2007 at 9:12

GoogleCodeExporter commented 9 years ago
I've been investigating this one tonight. It looks like The sing HTML EditorKit 
is
basically broken. The GetBodyHTML method in CixDoor correctly calls
StringEscapeUtils.escapeHtml but the HTML EditorKit fails to understand the 
escape
sequences it generates.

The View Source option renders these characters correctly.

The nasty hack solution would therefore appear to be to unescape these 
characters,
the cleanest place to do that is probably in the setHTML method of HTMLPane.

Original comment by adam.a.b...@gmail.com on 16 Feb 2007 at 10:49

GoogleCodeExporter commented 9 years ago
The nasty hack suggested above has now been implemented.

Original comment by adam.a.b...@gmail.com on 27 Feb 2007 at 10:32