[Date Prev][Date Next][Thread Prev][Thread Next][Author Index][Date Index][Thread Index]

Re: [zzdev] Re: [zzdev] 0.6 branch created



On 20010403T221810+0200, B. Fallenstein wrote:
> I haven't been able to test the branch, because I'm currently unable to
> compile the whole of GZigZag. However, it appears that in all recent
> versions (including 0.5) there is a bug causing Finnish umlauts (ä and
> ö) to be entered into a cell twice even when the key was pressed only
> once.

Not a bug but a feature.  See this code:

        // FIXME: This is a REALLY REALLY BAD QUICK HACK to make the
        // Finnish special letters work.  The problem?  We don't get a
        // KEY_PRESSED for them.  Damn Java!

        int id = e.getID();
        if(id == e.KEY_TYPED) {
            int c = e.getKeyChar();
            if (c == 'å' || c == 'Å' || c == 'ä' || c == 'Ä'
                || c == 'ö' || c == 'Ö') {
                id = e.KEY_PRESSED;
            }
        }

(in ZZViewComponent)

I think it's better to get one too much than none (you can always
backspace off the extra one).

However, should this be made a run-time choice (a command-line switch
-umlautahck or something)?

-- 
%%% Antti-Juhani Kaijanaho % gaia@xxxxxx % http://www.iki.fi/gaia/ %%%