When I use Java
to copy Japanese
text to the clipboard, it can be retrieved again from Java
code while the process is running but it does not successfully copy it to the system's global clipboard. It will just be empty so that nothing can be pasted. It does work with "regular" English
text. How can this be fixed?
Here is the Japanese
example text:
不要?
ガノンの形態によってステップを分けた方がいいかも
Here is the standard Java
way of copying to the clipboard (I didn't really find another approach). For pasting you can use this code.
Usually Java
-based copy/paste operations work better on Windows
systems compared to *nix but this time even on Windows
it's not copying it.
Using a command line command solution platform-dependently for Windows
breaks horribly, the characters all get changed to question marks when copying to CMD
.
Reading it in as a file (clip.exe < Japanese.txt
) and copying it to the clipboard breaks too:
õ©ìÞªü´╝ƒ
Òé¼ÒâÄÒâ│Òü«Õ¢óµàïÒü½ÒéêÒüúÒüªÒé╣ÒâåÒââÒâùÒéÆÕêåÒüæÒüƒµû╣ÒüîÒüäÒüäÒüïÒéé
Is there really no solution to this?