Hi, On Fri, 12 Sep 2008 09:21:15 +0200 Frank Meies <[EMAIL PROTECTED]> wrote:
> Hi, > > On 11.09.08 13:51, Takashi Nakamoto wrote: > > > > To make reconversion feature complete in Writer, the child class of > > Window coressponding to Writer application have to be added these two > > methods and handle of COMmAND_SELECTIONCHANGE. So I'd like to know what > > widget (a child class of Window) is the Writer application window. I > > couldn't find it due to the mass of sw project source. > > without actually knowing what string reconversion is (the Japanese > documentation didn't help me much ;-): The class you are looking for is > SwEditWin (sw/source/ui/inc/edtwin.hxx). This class already handles some > other IME related commands like COMMAND_STARTEXTTEXTINPUT or > COMMAND_INPUTLANGUAGECHANGE. Huge thanks. I will try to investigate SwEditWin and implement this feature. It may take long time because this is not my main job. When I finish creating patch, I will file an issue. BTW, Who will take care of this matter? May I assign the issue to "fme"? FYI: The good and clear English document about string reconversion can't be found. I wrote the description about Japanese string reconversion, following. I hope it helps you understand. We, Japanese, write text in our own language with some types of characters. The most parts of Japanese text consists of Hiragana characters and Kanji characters. Hiragana characters can be entered by a keyboard directly, but Kanji characters cannot be entered by a keyboard directly because the number of Kanji characters is over 50,000, while English has only 26 characters. Therefore, to input Kanji characters in desktop computer, we first enter coressponding a string of Hiragana characters (because Hiragana is also a syllabary), then convert the entered Hiragana string into Kanji charac ters. However, at this stage, we have a problem that one Hiragana string may corresponds to some Kanji strings. This is one reason why we use IME. At this time, IME shows us some candidates of the appropriate Kanji strings. For example, "A I" (it is actually written in two Hiragana characters "Ux3042 Ux3043") is a Japanese word. Against this Hiragana string, we have some Kanji string candidates like "Ux611B" (this character means "love"), "Ux963F Ux4E95" and so on. When we pick one Kanji string from the candidates, IME finish conversion process and pass the picked Kanji string to an application like Writer. An application usually displays and holds the passed string. At this stage, there are an important fact that the information about the original Hiragana string disappers when IME passes the Kanji string to the application. The application doesn't know which Hiragana string can be converted into the passed Kanji string. However, a standard person sometimes makes a mistake. Let's think the situation that we picked undesirable Kanji string from the candidates. If we don't have string reconversion system, we have to delete the entered Kanji string and follow the same steps described above again. With string reconversion system, we don't have to do such pain works. With only pushing HENKAN key, which can be found in a JP106 keyboard, then IME shows the candidates again and we can choose another Kanji string easily. The reconversion process can be done mainly by IME. When HENKAN key is pushed, IME emits WM_IME_REQUEST message to the focused application. After receiving this message, the application should give the text of the sentence around the cursor, which will be reconverted, to IME. Reconversion process is very difficult because the original Hiragana string is lost. The reconversion system must guess the original Hiragana string based on the specified Kanji string. To understand this process, the knowledge about Japanese and natural language processing system, but, fortunately application developer don't need to understand them. We can delegate this process to IME. Many application developer uses well developed GUI library like MFC, so they don't have to write code that delegates the reconversion process to IME. However, VCL library is not designed to handle reconversion. That is why I'm working on this matter today. I've heard that some Japanese users say "we can reconvert entered Kanji string with MS-Word, but we can't do that with OOo Writer. OOo is difficult to use." In fact, a certain FAQ Web site place this problem as a frequently asked question like "Q. We can't reconvert entered string with OOo? A. No". That's true, but this Q&A makes OOo's image bad in Japan. I'd like to break through this bad situation. So please help me when I face a technical difficulty, sw members. Regards, -- Takashi Nakamoto <[EMAIL PROTECTED]> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
