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 119985 - I18N : Japanese input does not work on Output window
Summary: I18N : Japanese input does not work on Output window
Status: VERIFIED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Output Window (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P2 blocker (vote)
Assignee: Milos Kleint
URL:
Keywords: I18N
Depends on:
Blocks:
 
Reported: 2007-10-25 07:00 UTC by Masaki Katakai
Modified: 2008-12-22 10:09 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
demo (167.92 KB, application/octet-stream)
2007-10-25 07:03 UTC, Masaki Katakai
Details
patched output2 module (301.39 KB, application/octet-stream)
2007-11-02 13:32 UTC, Milos Kleint
Details
screencast: with patch and console output (157.85 KB, application/octet-stream)
2007-11-02 16:19 UTC, Masaki Katakai
Details
patched output module - second shot (300.55 KB, application/octet-stream)
2007-11-03 13:26 UTC, Milos Kleint
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Masaki Katakai 2007-10-25 07:00:38 UTC
Now bug 119307 has been fixed so we can type Japanese on Output window.
But it does not work properly. It seems that the caret position is not changing
during the composition.

1. Run the small program of bug 84375
2. Turn conversion on Output window
3. Type something

I'll put screencast later. The scenario is to type something after "katakai".
But after the composition of Japanese, "katakai" is broken and "kai" disappears
and replaced with japanese.

I don't see this issue on Solaris but it happens on Windows.
Comment 1 Masaki Katakai 2007-10-25 07:03:34 UTC
Created attachment 51643 [details]
demo
Comment 2 Milos Kleint 2007-10-25 13:37:43 UTC
confirmed. I'm trying the same with chinese pinyin input method on my mac. (i'm not familiar with japanese input methods)

I'm getting somewhat different results but probably caused by the same bug.
1. when entering chinese characters at the end of the line, everything seems fine.
2. I can delete any arbitrary character
3. if I go back to the beginning of the line and type something, the complete line gets broken, deleting existing
characters and leaving the english alphabet chars around.
Comment 3 Milos Kleint 2007-10-25 14:53:46 UTC
possibly related to #114290
Comment 4 yokolet 2007-10-25 20:01:11 UTC
I have exactly the same problem as I reported at http://statistics.netbeans.org/exceptions/detail.do?id=9089
When I tried to input a single Japanese character on Output field by using SCIM running on Ubuntu Linux, I got
ClassCastException. I have a java.util.Scanner type object in my program to get some characters from standard input.
This problem happened only when I typed a Japanese character, so I could input alphabetical characters and get my
program run successfully.
Comment 5 Milos Kleint 2007-11-02 13:32:55 UTC
Created attachment 52362 [details]
patched output2 module
Comment 6 Milos Kleint 2007-11-02 13:37:59 UTC
attached is a patched output2 module that should fix the issue.
to test it:
1. download the jar file
2. place it into your netbeans installation in the netbeans/platform8/modules folder (on mac it's
Netbeans.app/Resources/Netbeans/platform8/modules folder)
3. start the ide and try typing english and japanese/chinese characters into output window.
Comment 7 martin_adamek 2007-11-02 14:55:24 UTC
I tried patch on my Mac and it works fine for me.
Comment 8 Milos Kleint 2007-11-02 15:00:33 UTC
for the record: I asked martin_adamek to try out the chinese pinyin input method on mac. That one replaces characters
typed in latin pinyin into chinese chars.
Comment 9 Petr Jiricka 2007-11-02 15:04:11 UTC
I confirm that the attached module fixes the problem. I tried on Mac OS X witch Chinese keyboard following Milos's
instructions: without the patch (build 4256), and was able to reproduce the problem, with the patch, everything works
correctly. 
Comment 10 Masaki Katakai 2007-11-02 15:15:08 UTC
It's still not working properly for Japanese IME on Windows.
Comment 11 yokolet 2007-11-02 15:33:31 UTC
This patch works on Ubuntu and Leopard. I could input Japanese characters in Output field and get my program run
successfully. I put the jar file under "platform7" directory instead of "platform8" since my NetBeans 6.0beta2 doesn't
has a direcotry, platform8. I guess NetBeans 6.0 final might have this directory.
Comment 12 Milos Kleint 2007-11-02 15:49:02 UTC
yokolet: my mistake, platform7 is correct, platform8 was a typo.
Comment 13 Masaki Katakai 2007-11-02 16:19:37 UTC
Created attachment 52389 [details]
screencast: with patch and console output
Comment 14 Milos Kleint 2007-11-03 12:29:56 UTC
commiting the partial fix.

Checking in ui/AbstractOutputPane.java;
/cvs/core/output2/src/org/netbeans/core/output2/ui/AbstractOutputPane.java,v  <--  AbstractOutputPane.java
new revision: 1.49; previous revision: 1.48
done
Checking in OutputDocument.java;
/cvs/core/output2/src/org/netbeans/core/output2/OutputDocument.java,v  <--  OutputDocument.java
new revision: 1.23; previous revision: 1.22
done
Comment 15 Milos Kleint 2007-11-03 13:26:11 UTC
Created attachment 52444 [details]
patched output module - second shot
Comment 16 Milos Kleint 2007-11-03 14:39:34 UTC
the second patch doesn't seem to work either, I'd like to waive the issue. It has been partially fixed for some input
methods. The once that don't work can be workarounded by copy&pasting the text into the OW.
Comment 17 Milos Kleint 2007-11-05 09:51:14 UTC
I suppose the waiver is approved, no objections were raised.
Comment 18 Ken Frank 2007-11-29 23:15:07 UTC
can team see if this is one that might be fixed in upcoming patch
or nb6.0.1 release (or at least for 6.1) ?

ken.frank@sun.com
Comment 19 Ken Frank 2007-12-03 16:21:05 UTC
since many parts of this are now fixed, could they be part of 6.0 patch 2 - being
organized now by sustaining ?  

I've added the required status whiteboard entry here in case it can be.

I also have information on the internal process and alias notifications
needed to sustaining.
Comment 20 Ken Frank 2008-01-10 19:49:09 UTC
I've put in status whiteboard request for this to be fixed
for patch 3 - which will happen in next few weeks - can
team look and see if that can happen ?

ken.frank@sun.com
Comment 21 Karthikeyan Rajeswaran 2008-01-14 21:26:49 UTC
Status whiteboard should be release601_fixes_candidate1 (since 6.0.1 patch1 is the next planned patch).
Comment 22 Lukas Hasik 2008-01-30 09:17:41 UTC
fixing the status whiteboard. The issues planned for 6.0.1 patch1 should be fixed till 1/31. 
Milosi, is it fixable in this timeframe(tommorow)?
Comment 23 Milos Kleint 2008-01-30 09:26:58 UTC
no. i still don't know how to fix.
Comment 24 Lukas Hasik 2008-03-31 09:01:57 UTC
no objections against the waiver for 6.1 -> waiving it
Comment 25 Ken Frank 2008-04-14 22:29:34 UTC
could team summarize what parts are fixed and what not and then

1. could fixed parts be put into trunk, so can go into upcoming 6.1 patch (it needs to
be in trunk first before can be nominated)

2. could details of unfixed yet parts be provided and I'll open a separate issue ?

ken.frank@sun.com
Comment 26 Milos Kleint 2008-04-16 14:32:00 UTC
1. fixed part is in trunk and was part of 6.0 and 6.1
2. the unfixed part is entering japanese text. I've fixed entering chinese text (at least for the input method I was
using on  mac, there might be other platforms or input methods that fail still)


what I would like to know is the exact setup that doens't work
1. OS platform 
2. locale used
3. input method used
4. jdk version used (I think that's irrelevant but who knows)
Comment 27 Ken Frank 2008-04-21 16:10:31 UTC
thanks for the clarification on it.

I'll try to find out details of what is not yet working.

yokolet, does fix from after Nov 3, which is after your last comment,
does it work for you using windows, since that is what originally reported on ?

ken.frank@sun.com
Comment 28 yokolet 2008-04-21 23:56:22 UTC
Ken. Excuse me. I don't have Windows on which I can test this. At least, I've been able to input Japanese characters on
Mac OSX and Ubuntu since Nov. 2.
Comment 29 Ken Frank 2008-04-22 00:19:35 UTC
Yokolet,

thanks for confirming about mac and ubuntu
that its ok now.

ken.frank@sun.com
Comment 30 Milos Kleint 2008-05-30 15:08:19 UTC
->t_h
Comment 31 t_h 2008-08-19 12:10:04 UTC
Check please if the issue still exists in trunk. I tried Chinese(Pinyin)/ Japanese input on Win Vista and it seems it
works for me. If the issue is still valid please specify steps how to reproduce (input method, letters).
Comment 32 Masaki Katakai 2008-09-11 14:53:23 UTC
Very sorry for late.

It's still reproduce for me on Windpws XP and Vista on trunk.
See the flash demos in attachment. 

1. Start the program in Japanese locale, using the default IME of Windows
2. Input "katakai" in ASCII into output window
3. Turn conversion ON
4. Type k,a,t,a,k,a,i
   These strings will be converted into Hiragana, simple Japanese characters

  katakai[hiragana characters of katakai]

5. Hit space key multiple times
   it will convert Hiragana to Japanese Kanji characters,
   it will display several string for displaying a candidate.

At this point, the candidate string should be
displayed *after* 'katakai' like below,

  katakai[candidate of Kanji]

However, the current result is breaking the
existing katakai of ASCII like

  kata[candidate of Kanji]kai

It seems that the current caret position is not staying at the
end of 'katakai'.
Comment 33 Milos Kleint 2008-09-30 07:18:16 UTC
masaki, thanks a lot for the detailed steps. I was able to reproduce and fix.
http://hg.netbeans.org/main/rev/8e80a26e097c

Comment 34 Quality Engineering 2008-09-30 17:21:24 UTC
Integrated into 'main-golden', will be available in build *200809301401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/8e80a26e097c
User: Milos Kleint <mkleint@netbeans.org>
Log: #119985 fix japanese hiragana input method.
Comment 35 Masaki Katakai 2008-10-01 03:31:59 UTC
Super! Thanks Milos!

I verified your fix in 200809301401 on Windows, Solaris and Mac OS X.
Comment 36 Antonin Nebuzelsky 2008-10-01 09:20:01 UTC
Nice. Thanks, Masaki and Milos!