[Gambas-user] Accent letters blocked
Rolf-Werner Eilert
eilert-sprachen at ...221...
Mon Apr 26 18:04:09 CEST 2010
Am 26.04.2010 11:31, schrieb Benoît Minisini:
>> Hi all,
>>
>> One of my Gambas2 projects is a simple app that lets our students learn
>> typing. It blocks all Backspace etc. and counts keys/minute and so on.
>>
>> In TextArea1_KeyPress() there is this part:
>>
>> IF key.Control THEN 'skip Ctrl+Key
>> STOP EVENT
>>
>> ELSE 'skip all those simple keys:
>> SELECT CASE key.Code
>> CASE key.BackSpace, key.BackTab, key.Delete
>> STOP EVENT
>> CASE key.Down, key.Up, key.Left, key.Right
>> STOP EVENT
>> CASE key.Home, key.End, key.PageDown, key.PageUp
>> STOP EVENT
>> CASE key.Control
>> STOP EVENT
>> END SELECT
>>
>> END IF
>>
>> (Everything else there is just for counting and so on)
>>
>> Today we found that it blocks accented keys (like in French) as well, so
>> there is no way to type é or è and such... The app has been running
>> under Gambas1 on this machine for several years, and I only upgraded it
>> to Gambas2 couple of weeks ago. So this might be a feature of Gambas2...
>>
>> I cannot find anything wrong in the code above, do you see where the
>> code blocks accents?
>>
>> Thanks for all your ideas!
>>
>> Rolf
>>
>
> Please provide the full code, and note that Key.Control has changed its
> meaning in Gambas 2 (it is not a key code).
>
> Regards,
>
>
Your answer pointed me to the right thing: the second
CASE key.Control
STOP EVENT
END SELECT
was somehow confusing it. No idea what let me including it here, did it
have any special effect in Gambas1? Anyway, when I quote it out, the
accents are there again.
Thank you!
Rolf
More information about the User
mailing list