A DESCRIPTION OF THE PROBLEM :
There are 2 phenomenons:
1) Exe can not start under path whose name includes non-ascii
2) File whose name includes both ascii and non-ascii can not be opened by exe.
I have not workaround for the first issue and have to tell user install my application under pure English path.
The second issue arises because I want to have user double click a file to open it by my application when user assoicates the default-open program of this file type to my application. So the command arguments need be accepted by my application.
On my platform, I get following results:
1) When file name and its path include only ascii, no problem.
2) When file name or its path include only non-ascii like pure Chinese, no problem.
3) When file name or its path include both non-ascii and ascii, the argument passed in is messed.
I have neither workaround for the second issue.
Jar has not the 2 problems. It can start from non-ascii path and accept file name in mixed characters.
The following convertion does not help and makes more problems like confusing Jar:
new String(arg.getBytes(), "utf-8")
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1) Make an application which accepts argument.
2) Build its self-contain package with jpakage
3) Copy the package under a path whose name includes non-ascii characters. Then start the EXE, to recreate the first issue.
4) Copy the package under a path whose name includes only ascii characters.
5) Associate the default-open program of a file type like ".png" to the EXE.
6) Rename a file of this type in mixed characters that includes both ascii and non-ascii.
7) Double click this file and check whether EXE accepts right file name.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
1) EXE can start from a path whose name includes non-ascii character.
2) EXE can accepts arguments which include both ascii and non-ascii.
ACTUAL -
1) EXE can not start from a path whose name includes non-ascii character.
2) Arguments which include both ascii and non-ascii are passed to EXE incorrectly.