[Freewnn-users 326] Re: romkan ファンクションの仕方 (Using romkan functions)

Back to archive index
Alex Taylor alex****@altsa*****
2019年 3月 26日 (火) 05:42:47 JST

On Mon, 25 Mar 2019 02:59:34 +0000 石川 千秋 wrote:
> Dear Alex,
> The last time you wrote early in 2018, you seem to read English, so I 
> am writing in English here.

Yes, thank you.  (I can sort of read Japanese, but it takes a long time 
and I usually need help from Google or rikaichan.)

> it seems that roman input to hiragana or katakana string conversion is
> handled OUTSIDE
> Wnn: That is, the conversion is done BEFORE the string is sent to Wnn.

Yes, I noticed that kinput2 seems not to use the romkan APIs even when 
it uses Wnn.

I did find that 'uum' seems to use romkan, but I don't know any other 
program which does.  

> Let me explain the input behavior of two frontends. Well, actually one 
> is the behavior in a dedicated editor.
> The other is a general-purpose input frontend under X.

-- edit --

Thank you for this explanation.  Actually, it's quite useful for me 
because I have been thinking about how to present the interface for
clause (bunsetsu) conversion in my program.  You have given me some
good ideas for how to approach it.

> It may be that the romanization feature of Wnn server may not be tested
> extensively since many input frontends find it easier or more flexible 
> than to talk to Wnn server.

I think that is likely.  I suspect it was written for uum, and not 
really designed for graphical IMEs.  I found I had trouble using it to
parse through strings with its default functions.  (That is how my test 
program does, but in my real GUI program it causes problems.)  In the 
end, my GUI will handle string (buffer) iteration itself, and just call
the romkan function to convert the kana.

I think I mentioned it before.  I'm actually trying to write a graphical
IME (a bit similar to kinput2) for OS/2.  Since the OS/2 desktop is very 
different from XWindows I an writing the front-end processor all myself.

Actually, right now it already works well for typing hiragana in any 
graphical window!  It is using the romkan functions in FreeWnn.

For katakana, I thought of a new approach this morning.  The OS/2 API 
has a function to convert hiragana to katakana, so I can take the hiragana
string from romkan and convert it to katakana using this function.  That
does not handle special katakana combinations like 「ヴ」 or 「ティ」  but I 
found a way to convert those special combinations myself before calling 
romkan for the hiragana.

Supporting halfwidth (半角) katakana will be more difficult, because of the 
need to handle decomposed characters, but I might be able to do 
something similar.  I'll see.

BTW my project is:  https://github.com/altsan/os2-wnnim
There is no release built yet, although it works quite well as I described.
However, if you don't run OS/2 it's not very useful. :) 

I still need to add bunsetsu conversion, which will use the full FreeWnn
server and API.

> Well, again, I hope someone in the know will chime in, but this romanization
> feature may not be used by many due to the reason I mentioned above.

Understood.  Your information was helpful though, thank you.

> PS: Of course, the majority of linux users use other Japanese input methods
> according to some statistical data
> gathered by mozilla foundation. But I think kinput2(-wnn) users are still
> there until they perish due to old age :-)

Sometimes I think OS/2 users are the same. :)

Alex Taylor <alex****@altsa*****>

freewnn-users メーリングリストの案内
Back to archive index