This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Product Version: NetBeans IDE Dev (Build 0710) Java: 1.6.0_06; Java HotSpot(TM) Client VM 10.0-b22 System: Windows XP version 5.1 running on x86; MS932; ja_JP (nb) I'm running in the Japan locale, using a pseudo localized Netbeans with font size 16 option. 1. Create Web App 2. Create Restful WS Client Stubs In the project there is Readme.txt file. It has content in English without without encoding tag. Is it possible to store the content in html format with encoding data and place it in localized jar? The reason is that text files have no encoding tag but there are multiple sub locales for ja and zh so using just one encoding in a text file will not work, whereas there is one common encoding tag that will work in html file for each of ja and zh.
Created attachment 64728 [details] image
Ken, is there an example of a file with such encoding tag so we have an idea how this work? Thanks.
Peter, look at most olh docs or just a new html file created by nb -it has the meta charset tag in it; translation people would change that tag themself. the more complex part might be - when user is in locale for which has been translated; ie there are localized jars, will this modules code get the readme.html from the localized jar, and show it, and not the en one ? usually there are few readmes that come with a project or they are from some other provided s/w, like for rails project thus we don't have examples that I know of of how to code this part. ken.frank@sun.com
All html files (Test*.html, Readme.html) are now localized. The mechanism we use here is, - html file templates has tokens that get replaced with contents from Bundle.properties. So a user generating the stubs will see the html files in their locale. - There is no provision to create Readme files in multiple locales as you will see in Readme files of major software distributions. Changes, see http://hg.netbeans.org/main/rev/5542b06a54fc
The fix has side effects: Product Version: NetBeans IDE Dev (Build 200808101401) Java: 1.6.0_06; Java HotSpot(TM) Client VM 10.0-b22 Readme file is now in the html format and mbyte chars were shown ok there. TestStubs.html contains bad mbyte in its source (see image). View action from the pop-up menu opens browser with incorrect url (I tried it also with IE - the same result). The behavior is the same for UTF-8 and Windows-31j project encoding.
Created attachment 67053 [details] test stub
Charset value in Readme.html and TestStub.html doesn't depend on the project encoding. It is always UTF-8. Does it expected behavior?
Fixed 1. Charset value in Readme.html and TestStub.html now depend on the project encoding. 2. TestStubs.html contains bad mbyte in its source (see image). <-- I couldn't find a cause (did a od -c TestStubs.html in unix), but I tried to add processing instruction <?xml, and changed the <!DOCTYPE to look like Readme.html's. Following I think is not related to this issue. - View action from the pop-up menu opens browser with incorrect url (I tried it also with IE - the same result). So closing this bug as fixed. Please reopen if you think there are still I18n issues. Also please attach the TestStubs.html as well as the Bundle.properties file that has the translation text for TestStubs.html. I believe it could be a user error.
Integrated into 'main-golden', available in build *200808280201* on http://bits.netbeans.org/dev/nightly/ Changeset: http://hg.netbeans.org/main/rev/59b715b2372e User: Ayub Khan <ayubskhan@netbeans.org> Log: Fix issue#140368 - I18N - Restful WS Client Stubs wizard creates Readme.txt in English without encoding tag
Product Version: NetBeans IDE Dev (Build 200809040201) Java: 1.6.0_06; Java HotSpot(TM) Client VM 10.0-b22 System: Windows XP version 5.1 running on x86; MS932; ja_JP (nb) Steps: 1. Create WebApp 2. Open Restful WS Client Stubs wizard 3. Specify WADL file to Generates stubs (the file is attached) 4. Press Finish All files are using project encoding, but I see the following: 1. TestStubs.html contains bad mbyte in its source. The image looks the same. 2. There is RestProxyServlet.txt file. It looks like a java file but it has txt extension (not sure its ok).
Created attachment 69164 [details] wsdl file
>All files are using project encoding, but I see the following: >1. TestStubs.html contains bad mbyte in its source. The image looks the same. I don't know why Readme.html is OK, but TestStubs.html is not. Both use the same text from the Bundle.properties Can you please attach the TestStubs.html with the those bad mybyte. >2. There is RestProxyServlet.txt file. It looks like a java file but it has txt extension (not sure its ok). This is fine, it is documented in the Readme, on how to use this file.
In attachment there is my web application. Files stored in と粮い/web/rest folder.
Created attachment 69425 [details] web app
I have checked in a fix (http://hg.netbeans.org/main/rev/f6f031d22067). Please try the latest build to test this.
Closing as fixed, please reopen if there are issues.
Integrated into 'main-golden', will be available in build *200809100201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/f6f031d22067 User: Ayub Khan <ayubskhan@netbeans.org> Log: Fix issue#140368 - bad mbyte in TestStubs.html
verified: build 0910 (WinXP, Ja and OpenSolaris, zh)