Re: resource encoding troubles

2014-09-20 Thread Garret Wilson
I'm finally able to trace the code, and this is getting very odd. I use a hex editor, and the bytes in the properties file are ... 3D A9 ... (=©), just as I expect. But when I trace through the Wicket code, the IsoPropertiesFilePropertiesLoader is using a UrlResourceStream which uses a

Re: resource encoding troubles

2014-09-20 Thread Garret Wilson
Hahahaha! I found the problem! When I looked at the HomePage.properties file in a hex editor, I was looking at the HomePage.properties file in my source tree. But remember that this file isn't the one that Wicket loads! After a Maven build, Wicket will load the HomePage.properties file that

Re: resource encoding troubles

2014-09-20 Thread Sven Meier
Hi Garret, I'm glad you found the culprit. Thanks for keeping us updated, we all learn something new each day. Have fun Sven On 09/20/2014 10:28 PM, Garret Wilson wrote: Hahahaha! I found the problem! When I looked at the HomePage.properties file in a hex editor, I was looking at the

Re: resource encoding troubles

2014-08-29 Thread Sven Meier
Thanks Andrew! Sven On 08/29/2014 05:22 AM, Andrew Geery wrote: I created a Wicket quickstart (from http://wicket.apache.org/start/quickstart.html) [this is Wicket 6.16.0] and made two simple changes: 1) I created a HomePage.properties file, encoded as ISO-8859-1, with a single line as per

Re: resource encoding troubles

2014-08-29 Thread Garret Wilson
Hi, all. Thanks Andrew for that attempt to reproduce this. I have verified this on Wicket 6.16.0 and 7.0.0-M2. I have checked out the latest code from https://git-wip-us.apache.org/repos/asf/wicket.git . I was going to trace this down in the code, but then I was stopped in my tracks with an

Re: resource encoding troubles

2014-08-29 Thread Garret Wilson
On 8/29/2014 9:15 AM, Garret Wilson wrote: ... So here is the problem: something is taking the string generated by the message (which was parsed correctly from the properties file) and writing it to the output stream, not in UTF-8 as it should, but in some other encoding. Hmmm... the

resource encoding troubles

2014-08-28 Thread Garret Wilson
I have Wicket 7.0.0-M2 running on embedded Jetty, which is correctly returning a content type of UTF-8 for my Wicket page: Date: Thu, 28 Aug 2014 15:37:52 GMT Expires: Thu, 01 Jan 1970 00:00:00 GMT Pragma: no-cache Cache-Control: no-cache, no-store Content-Type: text/html;

Re: resource encoding troubles

2014-08-28 Thread Francois Meillet
Look at http://apache-wicket.1842946.n4.nabble.com/How-to-localize-options-in-drop-down-tt4661751.html#a4661768 François Meillet Formation Wicket - Développement Wicket Le 28 août 2014 à 17:47, Garret Wilson gar...@globalmentor.com a écrit : I have Wicket 7.0.0-M2 running on embedded

Re: resource encoding troubles

2014-08-28 Thread Garret Wilson
Please explain explicitly what you are trying to say. I don't see how that link is relevant. * I am using FooterPanel.properties. * Java properties files, as per the specification http://docs.oracle.com/javase/8/docs/api/java/util/Properties.html, are (and always have been) encoded in

Re: resource encoding troubles

2014-08-28 Thread Francois Meillet
use *.utf8.properties François Meillet Formation Wicket - Développement Wicket Le 28 août 2014 à 17:47, Garret Wilson gar...@globalmentor.com a écrit : I have Wicket 7.0.0-M2 running on embedded Jetty, which is correctly returning a content type of UTF-8 for my Wicket page: Date:

Re: resource encoding troubles

2014-08-28 Thread Garret Wilson
So are you saying that Wicket does not support ISO-8859-1 properties files that adhere do the Java standard? Or are you saying, I don't know what the problem is, I'm just giving you a workaround? If so, I appreciate the workaround tip, but that still doesn't explain what the problem is. I'm

Re: resource encoding troubles

2014-08-28 Thread Francois Meillet
http://wicket.apache.org/guide/guide/ François Meillet Formation Wicket - Développement Wicket Le 28 août 2014 à 19:24, Garret Wilson gar...@globalmentor.com a écrit : So are you saying that Wicket does not support ISO-8859-1 properties files that adhere do the Java standard? Or are you

Re: resource encoding troubles

2014-08-28 Thread Garret Wilson
Exactly! Quoting from the page you provided: Java uses the standard character set ISO 8859-11 to encode text files like properties files. ... (Note that this is a typo above---the author meant to say ISO 8859-1, not ISO 8859-11. The link to http://en.wikipedia.org/wiki/ISO/IEC_8859-1 in the

Re: resource encoding troubles

2014-08-28 Thread Andrea Del Bene
Have you tried using directly unicode character? i.e.: copyright=\u00A9 2014 Example, Inc. If you don't want to use unicode characters you should use an xml file as bundle file. Exactly! Quoting from the page you provided: Java uses the standard character set ISO 8859-11 to encode text files

Re: resource encoding troubles

2014-08-28 Thread Stefan Renz
Hi Garret, Garret Wilson wrote: Exactly! Quoting from the page you provided: Java uses the standard character set ISO 8859-11 to encode text files like properties files. ... (Note that this is a typo above---the author meant to say ISO 8859-1, not ISO 8859-11. The link to

Re: resource encoding troubles

2014-08-28 Thread Garret Wilson
I appreciate all the workarounds suggested. But no one has addressed the core issue: Is this a Wicket bug, or am I using standard property files incorrectly? Garret On 8/28/2014 10:42 AM, Andrea Del Bene wrote: Have you tried using directly unicode character? i.e.: copyright=\u00A9 2014

Re: resource encoding troubles

2014-08-28 Thread Garret Wilson
On 8/28/2014 10:53 AM, Stefan Renz wrote: ... if I read your original post correctly, you have not used ISO-8859-1 encoding in your property file, as I clearly see a (C) symbol. Since when is © (U+00A9) not part of ISO-8859-1? http://en.wikipedia.org/wiki/ISO/IEC_8859-1 Garret

Re: resource encoding troubles

2014-08-28 Thread Andrea Del Bene
It's just an encoding conflict: your properties uses ISO-8859-1, your page UTF-8. The result is a bad rendering, as you can see. When Java designers decided to adopt ISO-8859-1 they didn't consider most of the Asian languages... PS: just as a personal advice, try to be less rude in your

Re: resource encoding troubles

2014-08-28 Thread Sven Meier
Hi Garret, I like to find the source of the problem. Me too :). My configuration, as far as I can tell, is correct. From what you've written, I'd agree. You should create a quickstart. This will easily allow us to find a possible bug. Regards Sven On 08/28/2014 07:56 PM, Garret Wilson

Re: resource encoding troubles

2014-08-28 Thread Garret Wilson
On 8/28/2014 11:14 AM, Andrea Del Bene wrote: It's just an encoding conflict: your properties uses ISO-8859-1, your page UTF-8. The result is a bad rendering, as you can see. When Java designers decided to adopt ISO-8859-1 they didn't consider most of the Asian languages... PS: just as a

Re: resource encoding troubles

2014-08-28 Thread Garret Wilson
On 8/28/2014 12:08 PM, Sven Meier wrote: ... My configuration, as far as I can tell, is correct. From what you've written, I'd agree. You should create a quickstart. This will easily allow us to find a possible bug. Better than that, I'd like to trace down the bug, fix it, and file a

Re: resource encoding troubles

2014-08-28 Thread Andrew Geery
I created a Wicket quickstart (from http://wicket.apache.org/start/quickstart.html) [this is Wicket 6.16.0] and made two simple changes: 1) I created a HomePage.properties file, encoded as ISO-8859-1, with a single line as per the example above: copyright=© 2014 Example, Inc. 2) I added a line