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.

Bug 124865 - I18N : register_ja.html is broken
Summary: I18N : register_ja.html is broken
Status: VERIFIED FIXED
Alias: None
Product: obsolete
Classification: Unclassified
Component: Registration (show other bugs)
Version: 6.x
Hardware: All All
: P1 blocker (vote)
Assignee: mslama
URL:
Keywords: I18N
Depends on:
Blocks:
 
Reported: 2008-01-08 07:26 UTC by Masaki Katakai
Modified: 2008-01-15 08:46 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Masaki Katakai 2008-01-08 07:26:34 UTC
I tried "2008-01-08_01-16-45" ml installer on Japanese Windows Vista.

I understand that necessary Japanese translations (including register_ja.html) 
have been integrated already into the build.

I'm seeing two problems on offline mode.

1. Help->Register will go to English page ~/.netbeans-registration/6.0.1/register.html
  register_ja.html has been copied into the directory, but it goes to English one.

2. When I opened the register_ja.html file on browser manually, Japanese characters
  in register_ja.html are broken.

  I provided the html in UTF-8 encoding and I verified that the file in
  org-netbeans-modules-reglib_ja.jar is correct. So it seems that it was broken
  when it's copied to ~/.netbeans-registration/6.0.1/ (at replacement of @@PRODUCT@@??)

I'll try it on Solaris later.
Comment 1 mslama 2008-01-08 14:40:05 UTC
It was bug. Now IDE regenerates always register.html with localized content using nbresloc protocol according to default
system locale. I tested fix with main trunk build with added ja reglib module and user.language=ja and now register.html
contains ja content. URL used for browser always points to register.html. This way we need not synchronize available
localized modules suffixes with current system locale. nbresloc protocol handles it and if localized content is not
available default content is provided.

Main trunk:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.10; previous revision: 1.9

release60:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.2.9; previous revision: 1.2.2.8

release60_registration:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.2.7.2.2; previous revision: 1.2.2.7.2.1

release55:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.4.9; previous revision: 1.2.4.8

release551:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.6.9; previous revision: 1.2.6.8
Comment 2 Masaki Katakai 2008-01-09 03:14:38 UTC
Thanks Marek.

So, after the fix, only register.html will be created  under
.netbeans-registration folder and register_<lang>.html will
*not* be created right?

How about the broken characters issue? It seems that the fix is
not included yet. We can't use the default system encoding here.
We need to get a correct encoding value from html file but I think
we can assume "UTF-8" encoding when it's opened and saved like

+        BufferedReader reader = new BufferedReader(new InputStreamReader(in, "UTF-8"));
+        PrintWriter pw = new PrintWriter(f, "UTF-8");

I'm asking to translate the file using UTF-8 encoding to community
folks and our translators.
Comment 3 mslama 2008-01-09 09:09:04 UTC
Character encoding UTF-8 is used for register.html when reading/writing.

Main trunk:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.11; previous revision: 1.10

release60:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.2.10; previous revision: 1.2.2.9

release60_registration:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.2.7.2.3; previous revision: 1.2.2.7.2.2

release55:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.4.10; previous revision: 1.2.4.9

release551:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.6.10; previous revision: 1.2.6.9
Comment 4 mslama 2008-01-10 13:36:42 UTC
Another fix to avoid dependency on nbresloc protocol (installer would have to use another IDE modules in addition to
ide/reglib). There is now simple code to look for correct register_X.html according to current locale.

Main trunk:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.13; previous revision: 1.12

release60:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.2.12; previous revision: 1.2.2.11

release60_registration:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.2.7.2.5; previous revision: 1.2.2.7.2.4

release55:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.4.12; previous revision: 1.2.4.11

release551:
/cvs/ide/reglib/src/org/netbeans/modules/reglib/NbServiceTagSupport.java
new revision: 1.2.6.12; previous revision: 1.2.6.11
Comment 5 Masaki Katakai 2008-01-15 08:46:52 UTC
Thanks Marek,

I verified the fix is working on 6.0.1 ml 2008-01-15_01-16-45 build,
tried to invoke the page from installer and IDE.