| Summary: | properties file for template is located in wrong path in org.eclipse.wst.jsdt.ui.nl_ja | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Technology] Babel | Reporter: | Satoru Yoshida <ramat> | ||||
| Component: | Server | Assignee: | Satoru Yoshida <ramat> | ||||
| Status: | CLOSED FIXED | QA Contact: | |||||
| Severity: | enhancement | ||||||
| Priority: | P3 | CC: | kitlo | ||||
| Version: | unspecified | Keywords: | helpwanted | ||||
| Target Milestone: | --- | Flags: | kitlo:
iplog+
|
||||
| Hardware: | PC | ||||||
| OS: | Windows XP | ||||||
| Whiteboard: | |||||||
| Bug Depends on: | |||||||
| Bug Blocks: | 265194 | ||||||
| Attachments: |
|
||||||
|
Description
Satoru Yoshida
Sorry, I have 1 mistake. Expected -------- nl/ja/templates/default-templates.properties Additional Info. org.eclipse.wst.html.ui.nl_ja_3.6.0.v20101211043401.jar has also same problem. Expected -------- nl/ja/templates/htmldefault-templates.properties Thanks. I find following fragment has also same problem. org.eclipse.wst.xml.ui.nl_ja_3.6.0.v20101211043401 Actually -------- xmldefault-templates_ja.properties is in root of the jar file. Expected -------- nl/ja/templates/xmldefault-templates.properties Babel is currently only designed to translate Java Property Resource Bundle files. A new enhancement is needed in order to support the translation of the templates.properties files.
- first of all, we need to be able to identify these editor template files
- Eclipse does not have any rules to stop developers from using the
name "templates.properties" for a regular Java Property Resource Bundle file
- therefore, potentially, "templates.properties" could be a regular Java
Property Resource Bundle file
- we need a mechanism for projects to tell Babel the list of editor template
files
- during language pack and update site generation, we have to construct the
translated editor template files in the plugin fragment in a different
directory structure
Babel currently does not have the resource to implement this enhancement. I'm adding the "helpwanted" keyword to this bug. Hope the community can help implement this.
I find new type for this issue. charset.properties, defaultIANA.properties and override.properties under org.eclipse.wst.sse.core/config/ . this path does not contain /templates/ , but contains /config/ . These property files would be located under org.eclipse.wst.sse.core.nl_ja/nl/ja/config/ . (it is example for Japanese) Thanks. Yoshida-san, first of all, do you think the 3 files (charset.properties, defaultIANA.properties and override.properties) should be translated? Moreover, the same arguments in comment 4 still apply: - potentially, "config" could be a directory for a regular Java Property Resource Bundle file - we need a mechanism for projects to tell Babel the list of these special directories - during language pack and update site generation, we have to construct the translated config files in the plugin fragment in a different directory structure Hello, Kit Lo-san, I think the 5th comment is trivial, and "nice to have". Because users would not be troubled in most of case, I feel. Issue of /templates/ directory is more important than one of /config/ directory. However, I reported the 5th comment for record because nobody might notice problem peculiar to org.eclipse.wst.sse.core . Thanks. I try some research... In eclipse 3.6 or above, following query gives us files to use ROOT/nl/AA/path/to/file.properties (AA is language code. And not uses file.properties_AA in this case) select project_id, version, name from files where is_active = 1 and name not regexp '^org\.eclipse\.[0-9a-z._]+\/[0-9a-z._\-]+properties$' and name not regexp '^org\.eclipse\.[0-9a-z._]+\/org' and name not regexp '^org\.eclipse\.[0-9a-z._]+\/src' and name not regexp '^org\.eclipse\.[0-9a-z._]+\/OSGI\-INF' AND project_id = 'eclipse' AND version >= '3.6'; Note: if eclipse 3.5 or before, I have not idea yet. I will be happy if its comment could help You, Thanks Created attachment 216036 [details]
implement for adding nl path feature
Hi, Kit Lo-san.
I try to implement for this issue.
I hope it could help all of us.
Thanks.
Yoshida-san, the patch looks reasonable. I will test it out and release that soon. Thanks for the contribution to Babel! hi, Kit Lo-san, I have just checked the Nightly Builds I20120616-0400 for juno. it seemes to be fine for me, thanks. Yoshida-san, I was waiting for the integration build to finish, test out the language packs before I provide my status update. You are faster than me :-) I tested your patch, but received some messages saying the $dir_name variable on line 265 is undefined. I think you had a typo. The variable should be $dirname. I changed line 265 to the following and everything is working now: $fullpath = $tmp_dir . $dirname . $filename; I also tested out the new language packs. I can see the template translations loaded properly. The problem is resolved! Thanks for your patch contribution! Keep them coming :-) Hi, Kit Lo-san, Thank you for correcting my mistyping. I look forward eagerly to the next Babel release ;-) |